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 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
174398035475e0d3ac6693c1d072ae40708b6f7e | c7509225992d6bcb93cab41bd4f2b8ccb26ff2d7 | /sources/genTree.cpp | 7a518088365286d1929c9da0ee4e43fe5009e63c | [] | no_license | Perzi-Lgs/GTree | bdcb3ef951ae293082c736bff34b852be92bea08 | 993135fe8bc0591d36fec43b74034744790aeee4 | refs/heads/master | 2021-04-02T12:55:59.116456 | 2020-07-01T16:59:46 | 2020-07-01T16:59:46 | 248,277,528 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 4,492 | cpp | genTree.cpp | #include "genTree.hpp"
#include "Evenement.hpp"
#include <fstream>
#include <iostream>
#include <unistd.h>
void genTree::generatePoint(n_data data)
{
Evenement new_point;
// * Set The Position with the given longitude and latitude
// * longitude + Latitude
new_point.m_shape_Evenement.setPosition({1000 * data.longitude / 180, 530 * data.latitude / -90});
new_point.m_shape_Evenement.setRadius(3);
new_point.m_data = data;
// * Change the color according to the type of event
if (data.type == m_Evenement_type::BIRTH)
new_point.m_shape_Evenement.setFillColor(sf::Color::Red);
else if (data.type == m_Evenement_type::DEATH)
new_point.m_shape_Evenement.setFillColor(sf::Color::Black);
else if (data.type == m_Evenement_type::WEDDING)
new_point.m_shape_Evenement.setFillColor(sf::Color::Magenta);
m_point.push_back(new_point);
}
/*
* Scale the size of the point according to the current zoom
* of the view
*/
void genTree::scalePoint(sf::Vector2f actualSize)
{
auto radius = m_point[0].m_shape_Evenement.getRadius();
static float oldRatio = 2000;
// * Iteration on all the points
for (auto &i : m_point)
{
if (actualSize.x/oldRatio > 1)
i.m_shape_Evenement.setRadius(radius * 1.02);
else if (actualSize.x / oldRatio < 1)
i.m_shape_Evenement.setRadius(radius * 0.98);
}
oldRatio = actualSize.x;
}
/*
* Event Handling
* W/S Zoom in/out
* Key arrow to move the View
*/
void genTree::event()
{
sf::Event event;
while (m_window.pollEvent(event))
{
if (event.type == sf::Event::Resized)
{
sf::FloatRect visibleArea(0, 0, event.size.width, event.size.height);
m_window.setView(sf::View(visibleArea));
}
else if (event.type == sf::Event::Closed)
m_window.close();
if (sf::Keyboard::isKeyPressed(sf::Keyboard::W))
{
sf::View view = m_window.getView();
view.zoom(0.99);
m_window.setView(view);
}
else if (sf::Keyboard::isKeyPressed(sf::Keyboard::S))
{
sf::View view = m_window.getView();
view.zoom(1.01);
m_window.setView(view);
}
else if (sf::Keyboard::isKeyPressed(sf::Keyboard::Left))
{
sf::View view = m_window.getView();
view.move(-20, 0);
m_window.setView(view);
}
else if (sf::Keyboard::isKeyPressed(sf::Keyboard::Right))
{
sf::View view = m_window.getView();
view.move(20, 0);
m_window.setView(view);
}
else if (sf::Keyboard::isKeyPressed(sf::Keyboard::Up))
{
sf::View view = m_window.getView();
view.move(0, -20);
m_window.setView(view);
}
else if (sf::Keyboard::isKeyPressed(sf::Keyboard::Down))
{
sf::View view = m_window.getView();
view.move(0, 20);
m_window.setView(view);
}
}
}
void genTree::changeLifeSpawn()
{
for (auto &i : m_point)
{
if (m_year == i.m_data.intDate[0] && m_month == i.m_data.intDate[1])
i.initLifeSpawn();
else if (m_year > i.m_data.intDate[0] || m_year == i.m_data.intDate[0] && m_month < i.m_data.intDate[1])
{
i.decreaseLifeSpawn();
}
}
}
void genTree::run()
{
sf::Clock clock;
while (m_window.isOpen()) {
// * Init the View
if (m_year == 1000) {
sf::View view = m_window.getView();
view.setCenter(0, 0);
m_window.setView(view);
}
event();
sf::Time elapsed1 = clock.getElapsedTime();
if (elapsed1.asMilliseconds() >= 50) {
std::cout << "Year " << m_year << " Month " << m_month << std::endl;
m_year = (m_month == 12) ? m_year + 1 : m_year;
m_month = (m_month != 12) ? m_month + 1 : 1;
clock.restart();
}
m_window.draw(m_background);
changeLifeSpawn();
for (auto &i : m_point)
{
if (i.isAlive() == true)
m_window.draw(i.getShape());
}
m_window.display();
m_window.clear();
scalePoint(m_window.getView().getSize());
}
}
void genTree::init()
{
for (int i = 0; i < m_data.size(); i++)
generatePoint(m_data[i]);
} |
956b3c6163dac6a7515ad7375d92b8ac5c0c23eb | e73d8410fc3f00ecf061a434f344a2c4abdb4adb | /Rototo/Sources/GUIManager.cpp | 6e56ce0615f1d74eb41b858b28ec10ff4f80dd5c | [] | no_license | DomDumont/trp | 1aad6c817f7e53edddf61d9ce1fa09860d1753b9 | d7b4159663c3f0fd062a1c00efad049041788565 | refs/heads/master | 2016-09-15T07:11:46.186282 | 2016-04-12T09:11:17 | 2016-04-12T09:11:17 | 19,699,668 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 13,195 | cpp | GUIManager.cpp | /*
==============================================================================
This file is part of the T.R.P. Engine
Copyright (c) 2015 - Dominique Dumont
Permission is granted to use this software under the terms of either:
a) the GPL v3 (or any later version)
b) the Affero GPL v3
Details of these licenses can be found at: www.gnu.org/licenses
T.R.P. is distributed in the hope that it will be useful, but WITHOUT ANY
WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR
A PARTICULAR PURPOSE. See the GNU General Public License for more details.
-----------------------------------------------------------------------------
To release a closed-source product which uses T.R.P., commercial licenses are
available: visit veed.fr for more information.
==============================================================================
*/
#include "Global.h"
#include "GUIManager.h"
#include "Application.h"
#include "Utils.h"
#include "pugixml.hpp"
#include "Font.h"
#include "Sprite.h"
#include "Atlas.h"
#include "Event_p.h"
#include "Event.h"
#include "binding/aswrappedcall.h"
#include "ScriptManager.h"
#include "ResourceManager.h"
#include "SDL.h"
/*----------------------------------------------------------------------------*/
GUIManager& GUIManager::Get()
{
static GUIManager foo;
return foo;
}
/*----------------------------------------------------------------------------*/
void GUI_LoadTheme(const std::string& _file)
{
GUIManager::Get().LoadTheme(_file);
}
/*----------------------------------------------------------------------------*/
void GUI_UnLoadTheme()
{
GUIManager::Get().UnLoadTheme();
}
/*----------------------------------------------------------------------------*/
void GUI_AddWidget(Widget *_widget)
{
GUIManager::Get().AddWidget(_widget);
}
/*----------------------------------------------------------------------------*/
void GUI_RemoveWidget(Widget *_widget)
{
GUIManager::Get().RemoveWidget(_widget);
}
/*----------------------------------------------------------------------------*/
GUIManager::GUIManager(): font(NULL), atlas(NULL), button_up(NULL),button_down(NULL), button_disable(NULL),
list_normal_item(NULL),list_selected_item(NULL),checkbox_up(NULL),checkbox_down(NULL),checkbox_disable(NULL),
radiobox_up(NULL),radiobox_down(NULL),radiobox_disable(NULL)
{
SDL_LogVerbose(SDL_LOG_CATEGORY_APPLICATION,"CGUIManager Constructor\n");
this->primary_text_color.r = 0;
this->primary_text_color.g = 0;
this->primary_text_color.b = 0;
this->primary_text_color.a = 255;
this->disable_text_color.r = 0;
this->disable_text_color.g = 0;
this->disable_text_color.b = 0;
this->disable_text_color.a = 255;
this->background_color.r = 0;
this->background_color.g = 0;
this->background_color.b = 0;
this->background_color.a = 255;
}
/*----------------------------------------------------------------------------*/
GUIManager::~GUIManager()
{
UnLoadTheme(); //TODO Check this. Just in case ????
}
/*----------------------------------------------------------------------------*/
void GUIManager::Init()
{
SDL_LogVerbose(SDL_LOG_CATEGORY_APPLICATION,"CGUIManager::Init\n");
}
/*----------------------------------------------------------------------------*/
void GUIManager::Shutdown()
{
SDL_LogVerbose(SDL_LOG_CATEGORY_APPLICATION,"CGUIManager::Shutdown\n");
widgets.clear(); //TODO perhaps release also the widgets, to check.
}
/*----------------------------------------------------------------------------*/
void GUIManager::HandleEvent( Event * event)
{
switch (event->event_p->evt.type)
{
case SDL_MOUSEBUTTONDOWN:
SDL_LogVerbose(SDL_LOG_CATEGORY_APPLICATION,"Nb Widgets = %d\n",widgets.size());
for (widgetsIT = widgets.begin(); widgetsIT != widgets.end(); ++widgetsIT )
{
SDL_LogVerbose(SDL_LOG_CATEGORY_APPLICATION,"Pouet Pouet %d\n",widgets.size());
Widget *pTemp;
pTemp = *widgetsIT;
if (pTemp->Touched(event->event_p->evt.button.x, event->event_p->evt.button.y))
{
if (pTemp->OnMouseButtonDown(event) != 0)
break;
}
}
break;
case SDL_MOUSEBUTTONUP:
for (widgetsIT = widgets.begin(); widgetsIT != widgets.end(); ++widgetsIT )
{
Widget *pTemp;
pTemp = *widgetsIT;
if (pTemp->OnMouseButtonUp(event) != 0)
break;
/*
if (pTemp->Touched(event->button.x,event->button.y))
{
}
*/
}
break;
case SDL_MOUSEMOTION:
for (widgetsIT = widgets.begin(); widgetsIT != widgets.end(); ++widgetsIT )
{
Widget *pTemp;
pTemp = *widgetsIT;
pTemp->OnMouseMotion(event);
/*
if (pTemp->Touched(event->button.x,event->button.y))
{
}
*/
}
break;
case SDL_KEYUP:
for (widgetsIT = widgets.begin(); widgetsIT != widgets.end(); ++widgetsIT )
{
Widget *pTemp;
pTemp = *widgetsIT;
pTemp->OnKeyUp(event);
}
break;
}
}
/*----------------------------------------------------------------------------*/
void GUIManager::AddWidget(Widget *_widget)
{
if( _widget )
{
widgets.push_back(_widget);
_widget->AddRef();
}
}
/*----------------------------------------------------------------------------*/
void GUIManager::RemoveWidget(Widget *_widget)
{
if( _widget )
{
int total_widgets = (int) widgets.size();
widgetsIT = widgets.begin();
for (int i=0; i < total_widgets; i++,widgetsIT++)
{
if (_widget == (*widgetsIT))
{
//param->Release();
_widget->Release();
widgets.erase(widgetsIT);
break;
}
}
//_widget->Release();
}
}
/*----------------------------------------------------------------------------*/
Sprite * GUIManager::LoadSprite(void* _elem)
{
pugi::xml_node * el = (pugi::xml_node *) _elem;
Sprite * temp_sprite;
temp_sprite= new Sprite();
temp_sprite->Load(this->atlas,el->attribute("name").as_string());
if (strcmp(el->attribute("nine").as_string(),"yes")== 0)
{
temp_sprite->SetNinePatch(true);
temp_sprite->SetNinePatchRect(atoi(el->attribute("x").as_string()), atoi(el->attribute("y").as_string()), atoi(el->attribute("w").as_string()), atoi(el->attribute("h").as_string()));
}
else
{
temp_sprite->SetNinePatch(false);
}
this->atlas->AddRef(); // Load is not done through script so add the reference manually
return temp_sprite;
}
/*----------------------------------------------------------------------------*/
/* */
/*----------------------------------------------------------------------------*/
void GUIManager::LoadTheme(const std::string& _file)
{
std::string fullPath;
std::string loadedString;
//First load Atlas
MY_SAFE_RELEASE(this->atlas);
fullPath = "themes//"+_file+"//images//"+_file;
this->atlas = new Atlas();
this->atlas->Load(fullPath,FULLPATH|BOTH);
//Then load the theme xml
fullPath = "themes//"+_file+"//"+_file+".xml";
loadedString = LoadTextFile(fullPath,FULLPATH|BOTH);
if (loadedString.empty())
{
SDL_Log("cannot find xml definition for theme %s",_file.c_str());
return;
}
pugi::xml_document doc;
pugi::xml_parse_result result = doc.load_string(loadedString.c_str());
if (result.status != pugi::status_ok)
{
SDL_Log("cannot find parse xml for theme %s",fullPath.c_str());
}
pugi::xml_node root = doc.first_child();
for (pugi::xml_node elem = root.first_child(); elem != NULL; elem = elem.next_sibling())
{
SDL_Log(elem.name());
if (strcmp(elem.name(), "font") == 0)
{
std::string tempFontName;
tempFontName = "themes//"+_file+"//fonts//" + elem.attribute("name").as_string();
int tempSize = atoi(elem.attribute("size").as_string());
SDL_assert(this->font == NULL);
this->font = new Font();
this->font->Load(tempFontName,tempSize,FULLPATH|BOTH);
}
else
if (strcmp(elem.name(), "button_up") == 0)
{
MY_SAFE_RELEASE(this->button_up);
this->button_up = LoadSprite(&elem);
}
else
if (strcmp(elem.name(), "button_down") == 0)
{
MY_SAFE_RELEASE(this->button_down);
this->button_down = LoadSprite(&elem);
}
else
if (strcmp(elem.name(), "button_disabled") == 0)
{
MY_SAFE_RELEASE(this->button_disable);
this->button_disable = LoadSprite(&elem);
}
else
if (strcmp(elem.name(), "list_normal") == 0)
{
MY_SAFE_RELEASE(this->list_normal_item);
this->list_normal_item = LoadSprite(&elem);
}
else
if (strcmp(elem.name(), "list_selected") == 0)
{
MY_SAFE_RELEASE(this->list_selected_item);
this->list_selected_item = LoadSprite(&elem);
}
else
if (strcmp(elem.name(), "checkbox_up") == 0)
{
MY_SAFE_RELEASE(this->checkbox_up);
this->checkbox_up = LoadSprite(&elem);
}
else
if (strcmp(elem.name(), "checkbox_down") == 0)
{
MY_SAFE_RELEASE(this->checkbox_down);
this->checkbox_down = LoadSprite(&elem);
}
else
if (strcmp(elem.name(), "checkbox_disabled") == 0)
{
MY_SAFE_RELEASE(this->checkbox_disable);
this->checkbox_disable = LoadSprite(&elem);
}
else
if (strcmp(elem.name(), "radiobox_up") == 0)
{
MY_SAFE_RELEASE(this->radiobox_up);
this->radiobox_up = LoadSprite(&elem);
}
else
if (strcmp(elem.name(), "radiobox_down") == 0)
{
MY_SAFE_RELEASE(this->radiobox_down);
this->radiobox_down = LoadSprite(&elem);
}
else
if (strcmp(elem.name(), "radiobox_disabled") == 0)
{
MY_SAFE_RELEASE(this->radiobox_disable);
this->radiobox_disable = LoadSprite(&elem);
}
else
if (strcmp(elem.name(), "primary_text_color") == 0)
{
primary_text_color.r = atoi(elem.attribute("r").as_string());
primary_text_color.g = atoi(elem.attribute("g").as_string());
primary_text_color.b = atoi(elem.attribute("b").as_string());
primary_text_color.a = atoi(elem.attribute("a").as_string());
}
else
if (strcmp(elem.name(), "disable_text_color") == 0)
{
disable_text_color.r = atoi(elem.attribute("r").as_string());
disable_text_color.g = atoi(elem.attribute("g").as_string());
disable_text_color.b = atoi(elem.attribute("b").as_string());
disable_text_color.a = atoi(elem.attribute("a").as_string());
}
else
if (strcmp(elem.name(), "background_color") == 0)
{
background_color.r = atoi(elem.attribute("r").as_string());
background_color.g = atoi(elem.attribute("g").as_string());
background_color.b = atoi(elem.attribute("b").as_string());
background_color.a = atoi(elem.attribute("a").as_string());
}
}
}
/*----------------------------------------------------------------------------*/
/* */
/*----------------------------------------------------------------------------*/
void GUIManager::UnLoadTheme()
{
MY_SAFE_RELEASE(this->font);
MY_SAFE_RELEASE(this->atlas);
MY_SAFE_RELEASE(this->button_up);
MY_SAFE_RELEASE(this->button_down);
MY_SAFE_RELEASE(this->button_disable);
MY_SAFE_RELEASE(this->list_normal_item);
MY_SAFE_RELEASE(this->list_selected_item);
MY_SAFE_RELEASE(this->checkbox_up);
MY_SAFE_RELEASE(this->checkbox_down);
MY_SAFE_RELEASE(this->checkbox_disable);
MY_SAFE_RELEASE(this->radiobox_up);
MY_SAFE_RELEASE(this->radiobox_down);
MY_SAFE_RELEASE(this->radiobox_disable);
}
/*----------------------------------------------------------------------------*/
/* */
/*----------------------------------------------------------------------------*/
void RegisterGUI()
{
if (strstr(asGetLibraryOptions(), "AS_MAX_PORTABILITY") == 0)
{
///sect:GUI
///glob:void GUI_AddWidget(Widget @)
ScriptManager::Get().RegisterGlobalFunction("void GUI_AddWidget(Widget @)", asFUNCTION(GUI_AddWidget), asCALL_CDECL);
///glob:void GUI_RemoveWidget(Widget @)
ScriptManager::Get().RegisterGlobalFunction("void GUI_RemoveWidget(Widget @)", asFUNCTION(GUI_RemoveWidget), asCALL_CDECL);
///glob:void GUI_LoadTheme(string &in file)
ScriptManager::Get().RegisterGlobalFunction("void GUI_LoadTheme(string &in _file)", asFUNCTION(GUI_LoadTheme), asCALL_CDECL);
///glob:void GUI_UnLoadTheme()
ScriptManager::Get().RegisterGlobalFunction("void GUI_UnLoadTheme()", asFUNCTION(GUI_UnLoadTheme), asCALL_CDECL);
}
else
{
ScriptManager::Get().RegisterGlobalFunction("void GUI_AddWidget(Widget @)", WRAP_FN(GUI_AddWidget), asCALL_GENERIC);
ScriptManager::Get().RegisterGlobalFunction("void GUI_RemoveWidget(Widget @)", WRAP_FN(GUI_RemoveWidget), asCALL_GENERIC);
ScriptManager::Get().RegisterGlobalFunction("void GUI_LoadTheme(string &in _file)", WRAP_FN(GUI_LoadTheme), asCALL_GENERIC);
ScriptManager::Get().RegisterGlobalFunction("void GUI_UnLoadTheme()", WRAP_FN(GUI_UnLoadTheme), asCALL_GENERIC);
}
} |
d00621594ffe14bf8bbd4b73cf2c3c259274583c | 32af37233c8e23eef06337b2ff064aa198cc839d | /include/animation/animation.h | 9810290938f93dbf41ee05f07f78cbed046c49be | [] | no_license | nickenchev/boiler | f577e1cb4a1af49552c923647baf9d7458485aaa | ccd2858a13ce8029214f4112621c510e5dc1fdd5 | refs/heads/master | 2023-08-31T03:29:31.052375 | 2023-08-28T06:13:46 | 2023-08-28T06:13:46 | 58,762,135 | 2 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 532 | h | animation.h | #ifndef ANIMATION_H
#define ANIMATION_H
#include <string>
#include <vector>
#include "animationsampler.h"
#include "channel.h"
namespace Boiler
{
class Animation
{
std::string name;
std::vector<Channel> channels;
public:
Animation(const std::string &name)
{
this->name = name;
}
const std::string &getName() const { return name; }
void addChannel(const Channel &channel)
{
channels.push_back(channel);
}
const std::vector<Channel> &getChannels() const
{
return channels;
}
};
}
#endif /* ANIMATION_H */
|
5562766bbcd7af7c89582e6693f6e8f46bd26ad3 | 79ca1707e6b3e22262a9710d74e7de7368525792 | /Darkness of Planet/Darkness of Planet/Darkness of Planet/cObjectNode.cpp | 2c367747e13ef251e409ebd028b9f8a9003f57c4 | [] | no_license | ggondols/TeamOfEalryAccess | 0645b419b649c075ed03881921bf5cefe754680d | 4219a2a0ae9644069e0d6743961a9987bfb17957 | refs/heads/master | 2021-01-21T12:16:30.626470 | 2017-10-15T08:52:09 | 2017-10-15T08:52:09 | 102,056,526 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 3,516 | cpp | cObjectNode.cpp | #include "stdafx.h"
#include "cObjectNode.h"
cSpatial::cSpatial()
{
m_position = D3DXVECTOR3(0.0f, 0.0f, 0.0f);
D3DXQuaternionIdentity(&m_orientation);
m_scalling = D3DXVECTOR3(1.0f, 1.0f, 1.0f);
}
cSpatial::~cSpatial()
{
}
void cSpatial::RotateBy(float fX, float fY, float fZ)
{
fX = D3DXToRadian(fX);
fY = D3DXToRadian(fY);
fZ = D3DXToRadian(fZ);
D3DXQUATERNION rotQuat, rotResult;
D3DXQuaternionRotationYawPitchRoll(&rotQuat, fY, fX, fZ);
D3DXQuaternionMultiply(&rotResult, &m_orientation, &rotQuat);
m_orientation = rotResult;
}
//////////////////////////////////////////////////////////////////////////
// Rotates node by a quaternion
// In: Quaternion to rotate by
// Out: void
//////////////////////////////////////////////////////////////////////////
void cSpatial::RotateBy(const D3DXQUATERNION & rotBy)
{
D3DXQUATERNION quatResult;
D3DXQuaternionMultiply(&quatResult, &m_orientation, &rotBy);
m_orientation = quatResult;
}
// DEGREES
void cSpatial::SetOrientation(float pitch, float roll, float yaw)
{
pitch = D3DXToRadian(pitch);
roll = D3DXToRadian(roll);
yaw = D3DXToRadian(yaw);
D3DXQUATERNION newRot;
D3DXQuaternionRotationYawPitchRoll(&newRot, yaw, pitch, roll);
m_orientation = newRot;
}
D3DXMATRIX * cSpatial::GetWorldMatrix(D3DXMATRIX * pOut)
{
assert(pOut);
D3DXMatrixRotationQuaternion(pOut, &m_orientation);
pOut->_41 = m_position.x;
pOut->_42 = m_position.y;
pOut->_43 = m_position.z;
*pOut = m_matScale * *pOut;
return pOut;
}
void cSpatial::Update(float fTimeDelta)
{
}
void cSpatial::SetSclling(float x, float y, float z)
{
m_scalling.x = x;
m_scalling.y = y;
m_scalling.z = z;
D3DXMatrixScaling(&m_matScale, x, y, z);
}
cObjectNode::~cObjectNode()
{
}
void cObjectNode::Update(float fTimeDelta)
{
// Since bounding spheres don't necessarily originate at the origin of the node's object space (e.g. a mesh may be in a certain position
// to make pivoting more intuitive, so that it starts at 0,0,0 and ends at 128,0,0. The bounding sphere centre will be at ~64,0,0 )
// we must transform the bounding sphere's object space centre point by the node's world matrix to get the correct position.
D3DXMATRIX nodeWorld;
GetWorldMatrix(&nodeWorld);
/*D3DXVec3TransformCoord(&m_BoundingSphere.m_Position, &m_pModel->m_ObjectSpaceBS.m_Position, &nodeWorld);
m_BoundingSphere.m_radius = m_pModel->m_ObjectSpaceBS.m_radius;
*/
// sort out the bounding boxes
vector< D3DXVECTOR3 > WorldOBBVertices;
WorldOBBVertices.resize(8);
// Transform the node's object space bounding box vertices into world space
//for (UINT i = 0; i < 8; i++)
//{
// D3DXVECTOR3 worldCoord;
// D3DXVec3TransformCoord((D3DXVECTOR3*)&WorldOBBVertices[i], (D3DXVECTOR3*)&m_pModel->m_BoundingBoxVertices[i], &nodeWorld);
//}
D3DXVECTOR3 min, max;
// then create a new AABB that bounds the extremities
min.x = max.x = WorldOBBVertices[0].x;
min.y = max.y = WorldOBBVertices[0].y;
min.z = max.z = WorldOBBVertices[0].z;
for (UINT i = 1; i < 8; i++)
{
if (WorldOBBVertices[i].x < min.x)
min.x = WorldOBBVertices[i].x;
if (WorldOBBVertices[i].x > max.x)
max.x = WorldOBBVertices[i].x;
if (WorldOBBVertices[i].y < min.y)
min.y = WorldOBBVertices[i].y;
if (WorldOBBVertices[i].y > max.y)
max.y = WorldOBBVertices[i].y;
if (WorldOBBVertices[i].z < min.z)
min.z = WorldOBBVertices[i].z;
if (WorldOBBVertices[i].z > max.z)
max.z = WorldOBBVertices[i].z;
}
//m_BoundingBox.m_min = min;
//m_BoundingBox.m_max = max;
} |
9ae66915f2a12b323ce6d50a7569f124b154c022 | 3c0d18b8723d67b8495eb6cb81d95d36341b573b | /Practice contest/Sum of Digits.cpp | fc5c59d37c5ef5e53d777f1f8b35df83a7e22263 | [] | no_license | tahmid108/Tahmid-s-Codes | c3128b5b4843ad888e80b57a565739bc742a88ed | ff80ee6d9de4c961a55353b4ded447c6e9bd7431 | refs/heads/master | 2023-02-13T18:10:13.388262 | 2021-01-08T15:38:52 | 2021-01-08T15:38:52 | 327,944,373 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 257 | cpp | Sum of Digits.cpp | #include<bits/stdc++.h>
using namespace std;
int main()
{
int tc;
cin >> tc;
cin.ignore();
while(tc--)
{
string s;
getline(cin,s);
long long sum=0;
for(int i=0;i<s.size();i++)
{
sum+=(s[i]-48);
}
cout << sum << endl;
}
}
|
4cd7788770dc5d6c5798a99b4e1c61e085d14d4d | a84ae7b277b8460bd79ca0874ae4d868e7c7b89d | /Round612/C.cpp | 81ca30c6cdd1810a7fbb954bbf96815cf38cd7fb | [] | no_license | copydev/CodeForces | 238a3d7ce1d415e9e22d5f8f50421808c88986b7 | 2a91104b156be12eb6ed11845605c0419b43a503 | refs/heads/master | 2022-12-10T22:36:50.384398 | 2020-09-07T11:51:36 | 2020-09-07T11:51:36 | 293,514,367 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 1,496 | cpp | C.cpp | #include <bits/stdc++.h>
using namespace std;
#define ll long long
#define REP(i,n) for(ll i = 0;i<n;++i)
int main() {
int n;
cin>> n;
int arr[n];
ll odd = 0;
ll even = 0;
ll oddleft, evenleft;
REP(i,n){
cin>>arr[i];
if(arr[i]%2 == 0){
even++;
}
else{
odd++;
}
}
if(n%2 == 0){
oddleft = n/2 - odd;
evenleft = n/2 - even;
}
else{
oddleft = n/2 + 1 - odd;
evenleft = n/2 - even;
}
vector<ll> odd_odd , even_even;
ll beginseg = 0;
ll beginpar = -1;
ll endsef
ll odd_even = 0;
ll size = 0;
ll before = -1; // 0 is odd 1 is even
REP(i,n){
if(arr[i] == 0){
size++;
}
else{
//If consecutive
if(size == 0){
if(arr[i]%2 == 0){
before =1;
}
else{
before =0;
}
continue;
}
//if range
if(arr[i]%2 == 0){
if(before == -1 || before == 1){
even_even.push_back(size);
}
else{
odd_even += size;
}
before = 1;
}
else{
if(before == -1 || before == 0){
odd_odd.push_back(size);
}
else{
odd_even+= size;
}
before = 0;
}
size = 0;
}
}
//Check size and before to add the last
if(size != 0 && before != -1){
if(before == 0){
odd_odd.push_back(size);
}
else{
even_even.push_back(size);
}
}
ll ans = odd_even;
sort(odd_odd.begin(),odd_odd.end());
sort(even_even.begin(),even_even.end());
REP(i,odd_odd.size()){
if(oddleft < odd_odd[i]){
ans +=
}
else{
oddleft -= odd_odd[i];
}
}
return 0;
} |
5a5a11c013270143e9540ae472781a6ceaa3115b | 525e8581d7f35d63277563649708f69cd8a0c3b8 | /naudio/third_party/JUCE/extras/Projucer/Source/Application/jucer_Main.cpp | d858fed6c7d8079dd2a203c68d2ecf6cdca9f14f | [] | no_license | eliot-akira/audiom | 55f8d218b3922c76ef0216324f2245e3929d764c | 23397abaecb789fb8b6fd449f3a627383640bc47 | refs/heads/master | 2021-04-05T23:55:17.742839 | 2018-03-29T05:41:55 | 2018-03-29T05:41:55 | 125,117,718 | 2 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 2,609 | cpp | jucer_Main.cpp | /*
==============================================================================
This file is part of the JUCE library.
Copyright (c) 2017 - ROLI Ltd.
JUCE is an open source library subject to commercial or open-source
licensing.
By using JUCE, you agree to the terms of both the JUCE 5 End-User License
Agreement and JUCE 5 Privacy Policy (both updated and effective as of the
27th April 2017).
End User License Agreement: www.juce.com/juce-5-licence
Privacy Policy: www.juce.com/juce-5-privacy-policy
Or: You may also use this code under the terms of the GPL v3 (see
www.gnu.org/licenses).
JUCE IS PROVIDED "AS IS" WITHOUT ANY WARRANTY, AND ALL WARRANTIES, WHETHER
EXPRESSED OR IMPLIED, INCLUDING MERCHANTABILITY AND FITNESS FOR PURPOSE, ARE
DISCLAIMED.
==============================================================================
*/
#include "../jucer_Headers.h"
#include "jucer_Application.h"
#include "jucer_OpenDocumentManager.h"
#include "../Code Editor/jucer_SourceCodeEditor.h"
#include "../Utility/jucer_FilePathPropertyComponent.h"
#include "../Project/jucer_TreeItemTypes.h"
#include "../Utility/jucer_UTF8Component.h"
#include "../Utility/jucer_SVGPathDataComponent.h"
#include "../Utility/jucer_AboutWindowComponent.h"
#include "../Utility/jucer_ApplicationUsageDataWindowComponent.h"
#include "../Utility/jucer_EditorColourSchemeWindowComponent.h"
#include "../Utility/jucer_GlobalSearchPathsWindowComponent.h"
#include "../Utility/jucer_FloatingToolWindow.h"
#include "../LiveBuildEngine/projucer_MessageIDs.h"
#include "../LiveBuildEngine/projucer_CppHelpers.h"
#include "../LiveBuildEngine/projucer_SourceCodeRange.h"
#include "../LiveBuildEngine/projucer_ClassDatabase.h"
#include "../LiveBuildEngine/projucer_DiagnosticMessage.h"
#include "../LiveBuildEngine/projucer_CompileEngineDLL.h"
#include "../LiveBuildEngine/projucer_CompileEngineClient.h"
#include "../LiveBuildEngine/projucer_ActivityListComponent.h"
#include "../LiveBuildEngine/projucer_BuildTabStatusComp.h"
#include "../LiveBuildEngine/projucer_ComponentListComp.h"
#include "../LiveBuildEngine/projucer_CompileEngineServer.h"
juce_ImplementSingleton (CompileEngineDLL);
struct ProjucerAppClasses
{
#include "../Code Editor/jucer_LiveBuildCodeEditor.h"
#include "../LiveBuildEngine/projucer_ErrorListComponent.h"
};
#include "jucer_CommandLine.h"
#include "../Project/jucer_ProjectContentComponent.cpp"
#include "jucer_Application.cpp"
START_JUCE_APPLICATION (ProjucerApplication)
|
ad482d9693fefb29b021281aa4ef3abd7dc31130 | 26690127f0fd138a3f0109702d71adc372831dd5 | /Library/Maths/LinearAlgebra/gauss_xor.cpp | 4841554a5cc3cafa8bfbc228297ec6eadda74448 | [] | no_license | Mohammad-Yasser/CompetitiveProgramming | 4bc2c14c54e9bc7be90bb684689c9340614d9d17 | a48b744b1dedb2f4ad3d642f5e5899cf48d637d4 | refs/heads/master | 2023-04-09T02:48:27.066875 | 2021-04-24T11:41:18 | 2021-04-24T11:41:18 | 32,478,674 | 2 | 1 | null | 2020-06-05T04:13:21 | 2015-03-18T19:06:09 | C++ | UTF-8 | C++ | false | false | 1,512 | cpp | gauss_xor.cpp | bool isSet(int n, int b) { return (n >> b) & 1; }
int getRank(const vector<int>& mat) {
vector<int> res = mat;
int rank = 0;
for (int row = 0, col = 0; row < res.size() && col < 20; ++col) {
for (int i = row; i < res.size(); ++i) {
if (isSet(res[i], col)) {
swap(res[row], res[i]);
break;
}
}
if (!isSet(res[row], col)) continue;
++rank;
for (int i = 0; i < res.size(); ++i) {
if (i == row) continue;
if (isSet(res[i], col)) {
res[i] ^= res[row];
}
}
++row;
}
return rank;
}
// Another one, with Longs and iterating from MSB to LSB instead of vice versa.
bool isSet(Long n, int b) { return (n >> b) & 1LL; }
void printRow(int x) { cout << bitset<5>(x).to_string() << endl; }
void printMat(const vector<Long>& mat) {
for (auto& x : mat) {
printRow(x);
}
}
vector<Long> getRREF(const vector<Long>& mat) {
vector<Long> res = mat;
int rank = 0;
for (int row = 0, col = 63; row < res.size() && col >= 0; --col) {
for (int i = row; i < res.size(); ++i) {
if (isSet(res[i], col)) {
swap(res[row], res[i]);
break;
}
}
if (!isSet(res[row], col)) continue;
++rank;
for (int i = 0; i < res.size(); ++i) {
if (i == row) continue;
if (isSet(res[i], col)) {
res[i] ^= res[row];
}
}
++row;
}
return res;
}
int getRank(const vector<Long>& mat) {
int res = 0;
for (auto& x : mat) {
res += (x != 0);
}
return res;
}
|
658b2bd5288490f47b69eeb5a25c8be75c48ae65 | 61c24829480c6fb69620c50e3d07ce92f1240da7 | /contrib/CFramework/System/Resource/ResourceManager.cpp | dd2c507dbd6bf352caabe33a2cd86a7e362de5ce | [] | no_license | Luiz-Monad/Irrlicht-Vulcan | 652b12f8b1e03face8aa436ec3d6dfdc7177d7e1 | 4788d02864ff3e34765c43515f375d303896fa02 | refs/heads/master | 2022-01-20T07:58:18.909722 | 2019-06-27T05:23:01 | 2019-06-27T05:23:01 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 6,060 | cpp | ResourceManager.cpp | /*
* Copyright (C) 2017-2018 Tauri JayD <https://www.>
*
* This program is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License as published by the
* Free Software Foundation; either version 2 of the License, or (at your
* option) any later version.
*
* This program is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
* more details.
*
* You should have received a copy of the GNU General Public License along
* with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#include "ResourceManager.h"
#include <regex>
using namespace System::Resource;
System::Resource::ResourceManager* System::Resource::ResourceManager::Instance()
{
static System::Resource::ResourceManager _instance;
return &_instance;
}
void System::Resource::ResourceManager::Initialize()
{
//std::list<ResourceDatabase*> moduls;
//while (!InitResourceModule.empty())
//{
// moduls.push_back(InitResourceModule.front());
// InitResourceModule.pop();
//}
//
//for (auto const& modul : moduls)
//{
// modul->CreateResourceDescriptor();
//}
//
//for (auto const& modul : moduls)
//{
// modul->Initialize();
//}
}
std::vector<std::string> System::Resource::ResourceManager::GetFileList(std::string const& pattern, std::string const& modulRef) const
{
std::vector<std::string> list;
const char* patternStr = pattern[0] == '/' ? &pattern[1] : pattern.c_str();
std::regex re(patternStr);
std::cmatch m;
if (!modulRef.empty())
{
const char* modulStr = modulRef[0] == '/' ? &modulRef[1] : modulRef.c_str();
ResourceDatabase* modul = GetResourceModul(modulStr);
if (modul)
{
for (const auto& path : modul->GetResourceMap())
{
if (pattern.empty())
{
list.push_back(System::String::format("%s;/%s", modulStr, path.first.c_str()));
continue;
}
if (std::regex_search(path.first.c_str(), m, re))
list.push_back(System::String::format("%s;/%s", modulStr, path.first.c_str()));
}
}
return list;
}
for (const auto& modul : mResourceModules)
{
for (const auto& path : modul.second->GetResourceMap())
{
if (pattern.empty())
{
list.push_back(System::String::format("%s;/%s", modul.first.c_str(), path.first.c_str()));
continue;
}
if (std::regex_search(path.first.c_str(), m, re))
list.push_back(System::String::format("%s;/%s", modul.first.c_str(), path.first.c_str()));
}
}
return list;
}
ResourceDatabase * System::Resource::ResourceManager::GetResourceModul(std::string const& name) const
{
auto modul = mResourceModules.find(name);
return modul != mResourceModules.end() ? modul->second.get() : nullptr;
}
void System::Resource::ResourceManager::LoadResources(const char* resourceRoot)
{
std::regex filter(R"(.*\.resx)");
System::FileSystem::TFileList flist;
System::FileSystem::GetFileList(resourceRoot, flist, false, &filter);
for (auto file : flist)
{
ResxFile resx;
LoadResxFile(file.string().c_str(), &resx);
uint32_t mid = 0;
for (auto& modul : resx.ModulList)
{
if (!strlen(modul.ModulEntry.ModulName))
continue;
ResourceDatabase* db = GetResourceModul(modul.ModulEntry.ModulName);
if (!db)
{
db = mResourceModulesById[modul.ModulEntry.ModulId] = (mResourceModules[modul.ModulEntry.ModulName] = std::make_shared<ResourceDatabase>(modul.ModulEntry.ModulName, modul.ModulEntry.ModulId)).get();
}
db->ParseResx(resx, mid++);
}
}
}
void System::Resource::ResourceManager::LoadResxFile(const char* file, ResxFile* fileData)
{
ResxFile _cache;
if (!fileData)
fileData = &_cache;
System::IO::StandardDataSource fileMgr;
fileData->File = fileMgr.OpenFile(file);
if (!fileData->File)
return;
ResxHeader * modulHeader;
do
{
fileData->ModulList.emplace_back();
auto& modul = fileData->ModulList.back();
memset(&modul.ModulEntry, 0, sizeof(modul.ModulEntry));
modulHeader = &modul.ModulEntry;
*fileData->File >> *modulHeader;
if (modulHeader->Signature != 'RSXA')
break;
if (!modulHeader->FileListTable)
break;
fileData->File->Seek(modulHeader->FileListTable, false);
size_t nextHEAD = fileData->File->Position() + modulHeader->NextHeader;
ResxFileListEntry* fileEntry;
do
{
modul.FileList.emplace_back();
fileEntry = &modul.FileList.back();
memset(fileEntry, 0, sizeof(fileEntry));
*fileData->File >> *fileEntry;
fileData->File->Seek(fileEntry->NextFileHeader, false);
} while (fileEntry->NextFileHeader);
fileData->File->Seek(nextHEAD, false);
} while (modulHeader->NextHeader);
}
ResourceObject * System::Resource::ResourceManager::_findResource(System::URI const& uri, uint64_t modulID) const
{
if (uri.GetDescriptor().m_scheme != "pack")
return nullptr;
const char* resourceRef = uri.GetDescriptor().m_path.LocalPath[0] == '/' ? &uri.GetDescriptor().m_path.LocalPath[1] : uri.GetDescriptor().m_path.LocalPath.c_str();
ResourceDatabase * modul = nullptr;
if (!uri.GetDescriptor().m_path.Assembly.empty())
{
const char* modulRef = uri.GetDescriptor().m_path.Assembly[0] == '/' ? &uri.GetDescriptor().m_path.Assembly[1] : uri.GetDescriptor().m_path.Assembly.c_str();
modul = GetResourceModul(modulRef);
if (!modul)
return nullptr;
auto resource = modul->GetResource(resourceRef);
if (!resource)
return nullptr;
return resource;
}
auto iModul = mResourceModulesById.find(modulID);
if (iModul != mResourceModulesById.end())
{
ResourceObject* resource = iModul->second->GetResource(resourceRef);
if (resource)
return resource;
}
for (auto db : mResourceModules)
{
ResourceObject* resource = db.second->GetResource(resourceRef);
if (resource)
return resource;
}
return nullptr;
}
|
02948cd8636be35ee5881ea9c2133591eb18b6cc | febcab69abf00cfcd2e72c095a88354163e1de72 | /SuperOverflow/MainPage.xaml.cpp | 61afbc075774b9e3031231f413cfffa63b65b384 | [] | no_license | kiewic/WindowsStoreApps | 4d2384822fb4860bb0cf1af8fc2c0f6b323f3bfb | 38df28c7c20f743bbc565b41a47ce18c22847796 | refs/heads/master | 2021-01-20T06:56:44.883930 | 2015-05-31T23:20:03 | 2015-05-31T23:20:03 | 10,319,054 | 3 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 3,213 | cpp | MainPage.xaml.cpp | //
// MainPage.xaml.cpp
// Implementation of the MainPage class.
//
#include "pch.h"
#include "MainPage.xaml.h"
#include "SuperHttpRequestCallback.h"
using namespace SuperOverflow;
using namespace Concurrency;
using namespace Microsoft::WRL;
using namespace Microsoft::WRL::Details; // Make
using namespace Platform;
using namespace Windows::Foundation;
using namespace Windows::Foundation::Collections;
using namespace Windows::Security::Authentication::Web;
using namespace Windows::UI::Xaml;
using namespace Windows::UI::Xaml::Controls;
using namespace Windows::UI::Xaml::Controls::Primitives;
using namespace Windows::UI::Xaml::Data;
using namespace Windows::UI::Xaml::Input;
using namespace Windows::UI::Xaml::Media;
using namespace Windows::UI::Xaml::Navigation;
MainPage::MainPage()
{
InitializeComponent();
}
/// <summary>
/// Invoked when this page is about to be displayed in a Frame.
/// </summary>
/// <param name="e">Event data that describes how this page was reached. The Parameter
/// property is typically used to configure the page.</param>
void MainPage::OnNavigatedTo(NavigationEventArgs^ e)
{
(void) e; // Unused parameter
ComPtr<IXMLHTTPRequest2> xhr;
CheckHResult(CoCreateInstance(CLSID_XmlHttpRequest, nullptr, CLSCTX_INPROC, IID_PPV_ARGS(&xhr)));
cancellation_token cancellationToken = cancellation_token::none();
// Create the callback.
ComPtr<SuperHttpRequestCallback> superCallback = Make<SuperHttpRequestCallback>(xhr.Get(), cancellationToken);
CheckHResult(superCallback ? S_OK : E_OUTOFMEMORY);
// Create a request.
CheckHResult(xhr->Open(L"GET", L"http://kiewic.com", superCallback.Get(), nullptr, nullptr, nullptr, nullptr));
CheckHResult(xhr->Send(nullptr, 0));
}
void MainPage::DoAuthentication()
{
String^ clientId = "1481";
String^ redirectUri = "https://stackexchange.com/oauth/login_success";
String^ scope = "read_inbox,no_expiry ";
String^ authUri = "https://stackexchange.com/oauth";
authUri += "?client_id=" + clientId + "&redirect_uri=" + redirectUri + "&scope=" + scope + "&display=popup&response_type=token";
Uri^ startURI = ref new Uri(authUri);
Uri^ endURI = ref new Uri(redirectUri);
try
{
create_task(WebAuthenticationBroker::AuthenticateAsync(WebAuthenticationOptions::None, startURI, endURI)).then([=](WebAuthenticationResult^ result)
{
Uri^ responseUri;
switch (result->ResponseStatus)
{
case WebAuthenticationStatus::ErrorHttp:
OutputDebugString(("ErrorHttp: " + result->ResponseErrorDetail + "\r\n")->Data());
break;
case WebAuthenticationStatus::Success:
OutputDebugString(L"Success\r\n");
OutputDebugString((result->ResponseData + "\r\n")->Data());
responseUri = ref new Uri(result->ResponseData);
break;
case WebAuthenticationStatus::UserCancel:
OutputDebugString(L"UserCancel\r\n");
break;
}
});
}
catch (Exception^ ex)
{
OutputDebugString(("Error launching WebAuth " + ex->Message)->Data());
}
}
|
f9c8e372884f8d5a9b294dc49fc1701fae2dcccb | eb2f8b3271e8ef9c9b092fcaeff3ff8307f7af86 | /Grade 10-12/2018 autumn/NOIP/NOIP2018提高组Day2程序包/answers/GD-0576/game/game.cpp | d9819ac2d0509f6d87fb972fe87d8c47cdbe0a17 | [] | no_license | Orion545/OI-Record | 0071ecde8f766c6db1f67b9c2adf07d98fd4634f | fa7d3a36c4a184fde889123d0a66d896232ef14c | refs/heads/master | 2022-01-13T19:39:22.590840 | 2019-05-26T07:50:17 | 2019-05-26T07:50:17 | 188,645,194 | 4 | 2 | null | null | null | null | UTF-8 | C++ | false | false | 300 | cpp | game.cpp | #include <bits/stdc++.h>
using namespace std;
int m,n;
int ma[22][22];
int main() {
freopen("game.in","r",stdin);
freopen("game.out","w",stdout);
cin>>n>>m;
long long sum=0;
if(n<m){
int c=n;
n=m;
m=c;
}
if(m==2){
sum+=(pow(2,n-1)-1)*4;
sum+=pow(2,n+1);
}
cout<<sum;
return 0;
}
|
93dcb8870d8aa569539e9a8953cfa349d05f3819 | a33aac97878b2cb15677be26e308cbc46e2862d2 | /program_data/PKU_raw/74/205.c | 9996326938db8fe31c30348783fbb98fb46a792f | [] | 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 | 438 | c | 205.c | int main()
{
int m,n,i,j,k=0,t=0,p=0,q,a,b,c=0,d=0;
int x[100];
scanf("%d %d",&m,&n);
for(i=m;i<=n;i++)
{for(j=1;j<=i;j++) {if(i%j==0) t++;}
if(t==2)
{b=i;
for(a=log10(b);a>=0;a--) {x[k]=b/(pow(10,a));b=b-x[k]*pow(10,a);k++;}
q=log10(i);
for(j=0;j<=q;j++)
{if(x[j]!=x[q-j]) {p=1;}}
if(p==0&&d==1){printf(",%d",i);}
if(p==0&&d==0){printf("%d",i);c=1;d=1;}
}
t=0;p=0;k=0;}
if(c==0) {printf("no");}
} |
e8baed54e9d8a978c622361d3edfbf109779f03b | 93900a65eae71204e3a3c855f9199ac725ec3e0f | /Day006/Template_3/Point.cpp | 9d22da16e60c61548383d3b82c72194bfa0fb027 | [] | no_license | deanlee-practice/Sprint4---C-Programing | 3fd04cca999105c61ab596532bb5453ab71fe926 | f8449b95e8993569af6859656b002fe12b4505ba | refs/heads/master | 2023-07-15T00:49:55.124759 | 2021-08-18T08:36:07 | 2021-08-18T08:36:07 | 397,523,498 | 0 | 0 | null | null | null | null | UHC | C++ | false | false | 848 | cpp | Point.cpp | /*
평면 위의 한 점을 객체화하는 클래스 Point를 일반화하는 템플릿으로 구현하시오.
*/
#include <iostream>
using namespace std;
template <typename T> // 여러 개를 쓸 땐 추가 나열 ', typename Q>'
class Point {
T x, y;
public:
Point(T x, T y);
void setX(T x);
void setY(T y);
T getX();
T getY();
};
template <typename T>
Point<T>::Point(T x, T y) : x(x), y(y) {}
template <typename T>
void Point<T>::setX(T x) {
this->x = x;
}
template <typename T>
void Point<T>::setY(T y) {
this->y = y;
}
template <typename T>
T Point<T>::getX() {
return x;
}
template <typename T>
T Point<T>::getY() {
return y;
}
int main() {
Point<double> pos1(1.5, 2.4);
cout << "x = " << pos1.getX() << endl;
cout << "y = " << pos1.getY() << endl;
return 0;
} |
bc1739db20a2690f3cf19aa58efb516c9237b5df | e7be352adc2d9265729e0c09583980b453bb3f04 | /SnakeProject/include/Food.h | df1e7a8d94254335c3ae8ef8b44fa2d025f2f094 | [] | no_license | NgocBich2012/game | 7c18f3e9e2f1ccea6e96d951261f6dd5dd539fcb | babb42f293ea0a2ea23dff1d9717cde7c24f4232 | refs/heads/master | 2021-09-15T10:22:37.601188 | 2018-05-30T11:36:51 | 2018-05-30T11:36:51 | 125,468,378 | 0 | 1 | null | null | null | null | UTF-8 | C++ | false | false | 1,162 | h | Food.h | #ifndef FOOD_H
#define FOOD_H
#include "Frame.h"
#include "PublicFunction.h"
#define WIDTH_FOOD 1
#define HEIGHT_FOOD 1
class Food
{
public:
Food();
~Food();
void setX(const int &x) {x_ = x;}
int getX() const {return x_;}
void setY(const int &y) {y_ = y;}
int getY() const {return y_;}
void setCFood(const char& c_food) {c_food_ = c_food;}
char getCFood() const {return c_food_;}
void setIndexColor(const int& index) {index_color_ = index;}
int getIndexColor() const {return index_color_;}
void setWidth(const int& width){width_ = width;}
int getWidth() const {return width_;}
void setHeight(const int& height) {height_ = height;}
int getHeight() const {return height_;}
void displayFood();
void update();
private:
int x_; // tọa độ x của thức ăn
int y_; // tọa độ y của thức ăn
int width_;
int height_;
char c_food_; // kí tự thức ăn
int index_color_; // màu thức ăn
};
#endif // FOOD_H
|
8cea91ebf081bdc6b5c3875afe700ea723b82e67 | c1cb57667eab96641fe97c3e5b5e7e169012fedd | /Source/Visualiser.cpp | ba17cf1b2f695101f24b0ad1f1484bb2bc36b032 | [] | no_license | JacobMills22/Spectrum | ca8d81b6faaff667f6592a9c53e21e0195badae6 | 76046b291d5f3502919c3d751fec7d9282dc549f | refs/heads/master | 2021-05-06T21:35:21.047622 | 2018-01-31T12:52:31 | 2018-01-31T12:52:31 | 112,544,053 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 6,108 | cpp | Visualiser.cpp |
//#pragma once
#include "Visualiser.h"
AudioVisualiser::AudioVisualiser(int bands) : cube(bands, spectralCubeID), droplet(bands, dropletID)
{
// OpenGL Initialisation.
openGLContext.setRenderer(this);
openGLContext.attachTo(*this);
openGLContext.setContinuousRepainting(true);
// Set Rotation Position.
rotation[xAxis].value = 0.0;
rotation[xAxis].min = 0.0;
rotation[xAxis].max = 0.0;
rotation[yAxis].value = 0.0;
rotation[yAxis].min = 0.0;
rotation[yAxis].max = 0.0;
// Set Number of bands for the cube to render.
cube.setNumOfBands(bands);
droplet.setNumOfBands(bands);
// Start timer at a rate of 50ms.
startTimer(50);
}
AudioVisualiser::~AudioVisualiser()
{
// Stop OpenGL from painting and stop timer.
openGLContext.setContinuousRepainting(false);
stopTimer();
}
void AudioVisualiser::newOpenGLContextCreated()
{
glViewport(0.0f, 0.0f, width, height); // Set the Position, Width and Height of the Window for OpenGL to render in.
glMatrixMode(GL_PROJECTION); // Set matrix mode to Projection, so that the camera properties can be modified.
glLoadIdentity(); // Reset Matrix to Default state (Just in case any rotation or transalation takes place).
glOrtho(0.0, width, 0, height, 0.0, 1000.0); // Set the space for the coordinate system.
glMatrixMode(GL_MODELVIEW); // Set Matrix mode back to standar Modelview so that transform properties such as rotation can be modified.
glLoadIdentity(); // Reset Matrix to Default state (Just in case any rotation or transalation takes place).
}
void AudioVisualiser::renderOpenGL()
{
glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT); // Clear Colour and Depth Buffers.
glEnable(GL_DEPTH_TEST); // Enable and set depth range, This allows the OpenGL
glDepthFunc(GL_LESS); // Context to use its depth buffer. Without this OpenGL will
glDepthRange(0.0, 2000.0); // not be able to render 3D shapes correctly.
// Center rendering to the center of the window and rotate if needed.
glPushMatrix(); // Sets the current Matrix to apply transformations.
glTranslatef(width * 0.5, height * 0.5, -500);
glRotatef(rotation[xAxis].value, 1, 0, 0);
glRotatef(rotation[yAxis].value, 0, 1, 0);
glRotatef(0, 0, 0, 1);
glTranslatef(-width * 0.5, -height * 0.5, 500);
if (cube.getDrawingState() == true) { cube.renderVisualisation(width * 0.5, height * 0.5, -500, 300); } // Draw Cube.
else if (droplet.getDrawingState() == true) {droplet.renderVisualisation(width * 0.5, height * 0.5, -500, 300); } // Draw Droplet.
glPopMatrix(); // Load the transformed matrix data.
}
void AudioVisualiser::openGLContextClosing()
{
}
void AudioVisualiser::timerCallback()
{
if (rotationState[xAxis] == true) { rotateVisualiser(xAxis); } // Rotate if required.
if (rotationState[yAxis] == true) { rotateVisualiser(yAxis); } // Rotate if required.
}
void AudioVisualiser::setSpectrumData(int index, float value)
{
if (cube.getDrawingState() == true) { cube.setSpectrumData(index, value, bandDecay); } // Set current spectrum data if cube is being drawn
if (droplet.getDrawingState() == true) { droplet.setSpectrumData(index, value, bandDecay); } // Set current spectrum data if droplet is being drawn
}
void AudioVisualiser::rotateVisualiser(int axis)
{ // Rotate visualiser with a "Ping-Pong" style.
if (rotation[axis].invertRotation == true) // if visualiser should be rotating backwards
{
rotation[axis].value -= getRotationSpeed(); // Decrement the rotation value by the current speed of rotation.
if (rotation[axis].value <= rotation[axis].min) { rotation[axis].invertRotation = false; } // Once the value reaches the minimum
} // set the visualiser to rotate forwards.
if (rotation[axis].invertRotation == false) // if visualiser should be rotating forwards
{
rotation[axis].value += getRotationSpeed(); // Increment the rotation value by the current speed of rotation.
if (rotation[axis].value >= rotation[axis].max) { rotation[axis].invertRotation = true; } // Once the value reaches the maximum
} // set the visualiser to rotate backwards.
}
void AudioVisualiser::setSize(int Width, int Height)
{
width = Width;
height = Height;
}
void AudioVisualiser::setVisualisationToDraw(int index)
{
cube.setDrawingState(false);
droplet.setDrawingState(false);
if (index == spectralCubeID)
{
cube.setDrawingState(true);
}
else if (index == dropletID)
{
droplet.setDrawingState(true);
}
}
void AudioVisualiser::setHorizontalRotationMin(float value)
{
rotation[xAxis].min = value;
rotation[xAxis].value = value;
}
void AudioVisualiser::setHorizontalRotationMax(float value)
{
rotation[xAxis].max = value;
rotation[xAxis].value = value;
}
void AudioVisualiser::setVerticleRotationMin(float value)
{
rotation[yAxis].min = value;
rotation[yAxis].value = value;
}
void AudioVisualiser::setVerticleRotationMax(float value)
{
rotation[yAxis].max = value;
rotation[yAxis].value = value;
}
void AudioVisualiser::setRotatingXState(bool state)
{
rotationState[xAxis] = state;
}
void AudioVisualiser::setRotatingYState(bool state)
{
rotationState[yAxis] = state;
}
void AudioVisualiser::setRotationSpeed(float value)
{
rotationSpeed = value;
}
float AudioVisualiser::getRotationSpeed()
{
return rotationSpeed;
}
void AudioVisualiser::setNumOfBandsToRender(int bands)
{
numOfBands = bands;
cube.setNumOfBands(bands);
droplet.setNumOfBands(bands);
}
int AudioVisualiser::getNumOfBandsToRender()
{
return numOfBands;
}
void AudioVisualiser::setBandDecay(int value)
{
bandDecay = value;
}
void AudioVisualiser::setRenderColour(int index, float red, float green, float blue)
{
cube.setRenderColour(index, red, green, blue);
droplet.setRenderColour(index, red, green, blue);
}
|
5523da9c9885342891b249ef33b062addde1d977 | f5aaa36d97dfcaaf5117f06aae7174f6822f214d | /matrices/matrices.cpp | c8bc0784346c4544e714f58feb12a2a14ef8a09b | [
"MIT"
] | permissive | triffon/up-2018-19 | 0efcfdb508e9f1ab38ed36719f1868f0c3fbc65c | 19ef291fbd1d8054cd66cb9451b041b45636f596 | refs/heads/master | 2020-04-01T11:49:46.075704 | 2019-02-20T07:48:25 | 2019-02-26T21:29:27 | 153,179,415 | 1 | 1 | null | null | null | null | UTF-8 | C++ | false | false | 2,867 | cpp | matrices.cpp | #include <iostream>
using namespace std;
void testmatrices() {
const int MAX = 100;
int a[MAX][MAX], m, n;
cout << "m = ";cin >> m;
cout << "n = ";cin >> n;
for(int i = 0; i < m; i++)
for(int j = 0; j < n; j++) {
cout << "a[" << i
<< "][" << j
<< "] = ";
cin >> a[i][j];
}
for(int i = 0; i < m; i++) {
for(int j = 0; j < n; j++)
cout << a[i][j] << '\t';
cout << endl;
}
int sums[MAX] = {0};
for(int j = 0; j < n; j++)
for(int i = 0; i < m; i++)
sums[j] += a[i][j];
cout << "Суми по колони:\n";
for(int j = 0; j < n; j++)
cout << "sums[" << j << "] = " << sums[j] << endl;
int x;
cout << "x = ";cin >> x;
for(int i = 0; i < m; i++) {
int j = 0;
while (j < n && a[i][j] != x)
j++;
if (j < n)
cout << x << " се среща в ред " << i << endl;
}
int j = 0, min = 1;
while (j < n && min % 2 != 0) {
// намираме min = минималният елемент на колоната j
min = a[0][j];
for(int i = 1; i < m; i++)
if (a[i][j] < min)
min = a[i][j];
j++;
}
// j == n || min % 2 == 0
// min % 2 == 0 <-> min(a[0][j], a[1][j],..., a[m-1][j]) % 2 == 0
if (min % 2 == 0)
cout << "Колоната " << j-1 << " изпълнява условието\n";
else
cout << "Няма колона, която да изпълнява услоивието\n";
// transpose magic
for(int i = 0; i < m || i < n; i++)
for(int j = 0; j < i; j++) {
int tmp = a[i][j];
a[i][j] = a[j][i];
a[j][i] = tmp;
}
// !!! не работи правилно за матрица 3 x 4 !!!
for(int i = 0; i < n; i++) {
for(int j = 0; j < m; j++)
cout << a[i][j] << '\t';
cout << endl;
}
return;
}
int main() {
// testmatrices()
const int MAX = 10;
int a[MAX][MAX] = {0};
int n;
cout << "n = ";cin >> n;
int count = 1;
for(int i = 0; i < n; i++)
for(int j = 0; j < n; j++)
a[i][j] = count++;
for(int i = 0; i < n; i++) {
for(int j = 0; j < n; j++)
cout << a[i][j] << '\t';
cout << endl;
}
// първо над главния диагонал
// k := j - i e "номер" на диагонал
// диагоналът с номер k започва от (0, k) и завършва на (n - 1 - k, n - 1)
for(int k = 0; k < n; k++) {
for(int j = k; j < n; j++)
cout << a[j-k][j] << ' ';
cout << endl;
}
// сега под главния диагонал
// k := i - j e "номер" на диагонал
// диагоналът с номер k започва от (k, 0) и завършва на (n - 1, n - 1 - k)
for(int k = 1; k < n; k++) {
for(int i = k; i < n; i++)
cout << a[i][i-k] << ' ';
cout << endl;
}
}
|
00743f4da1c2bd42578635e1305b7ff13f1f9998 | 9b636508be71c2ef852f116cb5ab6eb3591b118d | /armbot/wrist.cpp | 0ce7172dfde8cc463ed9f7f0bdc8e1c3f354032b | [] | no_license | Pitt-RAS/armbot | 83f68277573e8444e58d44cea9ca4a58bdef63a8 | c7271f1e9f53055c9217f4f05310ca33e4b3abc3 | refs/heads/master | 2021-07-05T14:48:36.312455 | 2019-04-18T18:53:52 | 2019-04-18T18:53:52 | 148,067,327 | 2 | 1 | null | 2019-04-18T18:53:54 | 2018-09-09T21:28:40 | C++ | UTF-8 | C++ | false | false | 1,425 | cpp | wrist.cpp | #include "wrist.h"
#include "util.h"
#include "servomgr.h"
#include <Wire.h>
Wrist::Wrist()
{
}
Wrist::~Wrist()
{
}
void Wrist::attach()
{
I2C_setByte(0x06,29,0x68);
I2C_setByte(0x06,26,0x68);
I2C_setByte(0x10,27,0x68);
I2C_setByte(0x08,28,0x68);
I2C_setByte(0x02,0x37,0x68);
I2C_setByte(0x16,0x0A,0x0C);
}
void Wrist::test()
{
Serial.println("hi");
ServoMgr::write(1, 0);
delay(2000);
ServoMgr::write(1, 180);
Serial.println("lo");
delay(2000);
}
void Wrist::drive()
{
Serial.print("poll: ");
uint8_t buf[20];
I2C_read(buf,0x3B,14,0x68);
int16_t ax = -(buf[0] << 8 | buf[1]);
int16_t ay = -(buf[2] << 8 | buf[3]);
int16_t az = (buf[4] << 8 | buf[5]);
int16_t gx = -(buf[8] << 8 | buf[9]);
int16_t gy = -(buf[10] << 8 | buf[11]);
int16_t gz = (buf[12] << 8 | buf[13]);
//Serial.print("ax: ");
//Serial.print(ax);
//Serial.print("\tay: ");
//Serial.print(ay);
//Serial.print("\taz: ");
//Serial.print(az);
//Serial.print("\t\tgx: ");
//Serial.print(gx);
//Serial.print("\t\tgy: ");
//Serial.print(gy);
//Serial.print("\t\tgz: ");
//Serial.print(gz);
pitch = map(gx, GYRO_MIN, GYRO_MAX, 0, 180);
roll = map(gy, GYRO_MIN, GYRO_MAX, 0, 180);
//Serial.println();
delay(10);
ServoMgr::write(PITCH_SERVO, pitch);
ServoMgr::write(YAW_SERVO, roll);
}
|
dde19e721905f5c863b50ad0d204a3ca1c4d385c | 4870b2103697d579b33933c3636858569e046a83 | /src/core/g_palPlatformSettings.h | ce5519dc3a4c17cf110ce81349896ca51ad2e159 | [
"MIT"
] | permissive | StadiaMemories/pal | 89775cf28dd661558f7ca2bdd5cd8e7546f2700e | a83f67db9f0d2f16bbc698aeefa9c5e9476c993a | refs/heads/master | 2023-06-01T19:36:54.527742 | 2020-05-14T04:06:45 | 2020-05-14T04:09:20 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 215,044 | h | g_palPlatformSettings.h | /*
***********************************************************************************************************************
*
* Copyright (c) 2018-2020 Advanced Micro Devices, Inc. All Rights Reserved.
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in all
* copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
* SOFTWARE.
*
**********************************************************************************************************************/
/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
// WARNING! WARNING! WARNING! WARNING! WARNING! WARNING! WARNING! WARNING! WARNING! WARNING! WARNING!
//
// This code has been generated automatically. Do not hand-modify this code.
//
// When changes are needed, modify the tools generating this module in the tools\generate directory OR the
// appropriate settings_*.json file
//
// WARNING! WARNING! WARNING! WARNING! WARNING! WARNING! WARNING! WARNING! WARNING! WARNING! WARNING!
///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/**
***************************************************************************************************
* @file g_palPlatformSettings.h
* @brief auto-generated file.
* Contains the definition for the PAL settings struct and enums for initialization.
***************************************************************************************************
*/
#pragma once
#include "pal.h"
#include "palSettingsLoader.h"
namespace Pal
{
enum DebugOverlayLocation : uint32
{
DebugOverlayUpperLeft = 0,
DebugOverlayUpperRight = 1,
DebugOverlayLowerRight = 2,
DebugOverlayLowerLeft = 3,
DebugOverlayCount = 4
};
enum TimeGraphColor : uint32
{
BlackColor = 0,
RedColor = 1,
GreenColor = 2,
BlueColor = 3,
YellowColor = 4,
CyanColor = 5,
MagentaColor = 6,
WhiteColor = 7
};
enum GpuProfilerTraceModeFlags : uint32
{
GpuProfilerTraceDisabled = 0,
GpuProfilerTraceSpm = 1,
GpuProfilerTraceSqtt = 2
};
enum GpuProfilerGranularity : uint32
{
GpuProfilerGranularityDraw = 0,
GpuProfilerGranularityCmdBuf = 1,
GpuProfilerGranularityFrame = 2
};
enum Pm4InstrumentorDumpMode : uint32
{
Pm4InstrumentorDumpQueueDestroy = 0,
Pm4InstrumentorDumpQueueSubmit = 1
};
/// Pal auto-generated settings struct
struct PalPlatformSettings : public Pal::DriverSettings
{
#if PAL_ENABLE_PRINTS_ASSERTS
struct {
bool infoEnabled;
bool warningEnabled;
bool errorEnabled;
bool ScEnabled;
bool eventPrintEnabled;
bool eventPrintCbEnabled;
} dbgPrintConfig;
#endif
#if PAL_ENABLE_PRINTS_ASSERTS
bool assertsEnabled;
#endif
#if PAL_ENABLE_PRINTS_ASSERTS
bool alertsEnabled;
#endif
bool enableEventLogFile;
char eventLogDirectory[MaxPathStrLen];
char eventLogFilename[MaxPathStrLen];
bool debugOverlayEnabled;
struct {
bool visualConfirmEnabled;
bool timeGraphEnabled;
DebugOverlayLocation overlayLocation;
char renderedByString[MaxMiscStrLen];
char miscellaneousDebugString[MaxMiscStrLen];
bool printFrameNumber;
bool useDebugOverlayOnColorSpaceConversionCopy;
} debugOverlayConfig;
struct {
TimeGraphColor gridLineColor;
TimeGraphColor cpuLineColor;
TimeGraphColor gpuLineColor;
} timeGraphConfig;
struct {
uint32 maxBenchmarkTime;
bool usageLogEnable;
char usageLogDirectory[MaxPathStrLen];
char usageLogFilename[MaxPathStrLen];
bool logFrameStats;
char frameStatsLogDirectory[MaxPathStrLen];
uint32 maxLoggedFrames;
} overlayBenchmarkConfig;
struct {
bool combineNonLocal;
bool reportCmdAllocator;
bool reportExternal;
bool reportInternal;
bool displayPeakMemUsage;
} overlayMemoryInfoConfig;
GpuProfilerMode gpuProfilerMode;
size_t gpuProfilerTokenAllocatorSize;
struct {
char logDirectory[MaxPathStrLen];
uint32 startFrame;
uint32 frameCount;
bool recordPipelineStats;
bool breakSubmitBatches;
bool useFullPipelineHash;
uint32 traceModeMask;
} gpuProfilerConfig;
struct {
char globalPerfCounterConfigFile[MaxFileNameStrLen];
bool cacheFlushOnCounterCollection;
GpuProfilerGranularity granularity;
} gpuProfilerPerfCounterConfig;
struct {
uint32 tokenMask;
uint32 seMask;
uint64 pipelineHash;
bool pipelineHashAsApiPsoHash;
uint64 tsHashHi;
uint64 tsHashLo;
uint64 vsHashHi;
uint64 vsHashLo;
uint64 hsHashHi;
uint64 hsHashLo;
uint64 dsHashHi;
uint64 dsHashLo;
uint64 gsHashHi;
uint64 gsHashLo;
uint64 msHashHi;
uint64 msHashLo;
uint64 psHashHi;
uint64 psHashLo;
uint64 csHashHi;
uint64 csHashLo;
uint32 maxDraws;
bool addTtvHashes;
size_t bufferSize;
GpuProfilerStallMode stallBehavior;
} gpuProfilerSqttConfig;
struct {
char spmPerfCounterConfigFile[MaxFileNameStrLen];
uint32 spmTraceInterval;
size_t spmBufferSize;
} gpuProfilerSpmConfig;
bool cmdBufferLoggerEnabled;
struct {
uint32 cmdBufferLoggerAnnotations;
uint32 cmdBufferLoggerSingleStep;
bool embedDrawDispatchInfo;
} cmdBufferLoggerConfig;
bool pm4InstrumentorEnabled;
struct {
char logDirectory[MaxPathStrLen];
char filenameSuffix[MaxPathStrLen];
Pm4InstrumentorDumpMode dumpMode;
uint32 dumpInterval;
} pm4InstrumentorConfig;
bool interfaceLoggerEnabled;
struct {
char logDirectory[MaxPathStrLen];
bool multithreaded;
uint32 basePreset;
uint32 elevatedPreset;
} interfaceLoggerConfig;
};
#if PAL_ENABLE_PRINTS_ASSERTS
static const char* pDbgPrintConfig_InfoEnabledStr = "#87264462";
#endif
#if PAL_ENABLE_PRINTS_ASSERTS
static const char* pDbgPrintConfig_WarningEnabledStr = "#3111217572";
#endif
#if PAL_ENABLE_PRINTS_ASSERTS
static const char* pDbgPrintConfig_ErrorEnabledStr = "#1058771018";
#endif
#if PAL_ENABLE_PRINTS_ASSERTS
static const char* pDbgPrintConfig_ScEnabledStr = "#2827996440";
#endif
#if PAL_ENABLE_PRINTS_ASSERTS
static const char* pDbgPrintConfig_EventPrintEnabledStr = "#4283850211";
#endif
#if PAL_ENABLE_PRINTS_ASSERTS
static const char* pDbgPrintConfig_EventPrintCbEnabledStr = "#74653004";
#endif
#if PAL_ENABLE_PRINTS_ASSERTS
static const char* pAssertsEnabledStr = "#1110605001";
#endif
#if PAL_ENABLE_PRINTS_ASSERTS
static const char* pAlertsEnabledStr = "#3333004859";
#endif
static const char* pEnableEventLogFileStr = "#3288205286";
static const char* pDebugOverlayEnabledStr = "#3362163801";
static const char* pDebugOverlayConfig_VisualConfirmEnabledStr = "#1802476957";
static const char* pDebugOverlayConfig_TimeGraphEnabledStr = "#2933558408";
static const char* pDebugOverlayConfig_DebugOverlayLocationStr = "#3045745206";
static const char* pDebugOverlayConfig_RenderedByStringStr = "#3912270641";
static const char* pDebugOverlayConfig_MiscellaneousDebugStringStr = "#1196026490";
static const char* pDebugOverlayConfig_PrintFrameNumberStr = "#2763643877";
static const char* pDebugOverlayConfig_UseDebugOverlayOnColorSpaceConversionCopyStr = "#1533629425";
static const char* pTimeGraphConfig_GridLineColorStr = "#3989097989";
static const char* pTimeGraphConfig_CpuLineColorStr = "#689918007";
static const char* pTimeGraphConfig_GpuLineColorStr = "#2929386323";
static const char* pOverlayBenchmarkConfig_MaxBenchmarkTimeStr = "#480313510";
static const char* pOverlayBenchmarkConfig_UsageLogEnableStr = "#3176801238";
static const char* pOverlayBenchmarkConfig_UsageLogDirectoryStr = "#219820144";
static const char* pOverlayBenchmarkConfig_UsageLogFilenameStr = "#2551463600";
static const char* pOverlayBenchmarkConfig_LogFrameStatsStr = "#266798632";
static const char* pOverlayBenchmarkConfig_FrameStatsLogDirectoryStr = "#3945706803";
static const char* pOverlayBenchmarkConfig_MaxLoggedFramesStr = "#3387883484";
static const char* pOverlayMemoryInfoConfig_CombineNonLocalStr = "#452099995";
static const char* pOverlayMemoryInfoConfig_ReportCmdAllocatorStr = "#2545297707";
static const char* pOverlayMemoryInfoConfig_ReportExternalStr = "#1692103889";
static const char* pOverlayMemoryInfoConfig_ReportInternalStr = "#1276999751";
static const char* pOverlayMemoryInfoConfig_DisplayPeakMemUsageStr = "#2059768529";
static const char* pGpuProfilerModeStr = "#3490085415";
static const char* pGpuProfilerTokenAllocatorSizeStr = "#2716183183";
static const char* pGpuProfilerConfig_LogDirectoryStr = "#602986973";
static const char* pGpuProfilerConfig_StartFrameStr = "#17496565";
static const char* pGpuProfilerConfig_FrameCountStr = "#3630548216";
static const char* pGpuProfilerConfig_RecordPipelineStatsStr = "#1092484338";
static const char* pGpuProfilerConfig_BreakSubmitBatchesStr = "#2743656777";
static const char* pGpuProfilerConfig_UseFullPipelineHashStr = "#3204367348";
static const char* pGpuProfilerConfig_TraceModeMaskStr = "#2717664970";
static const char* pGpuProfilerPerfCounterConfig_GlobalPerfCounterConfigFileStr = "#1666123781";
static const char* pGpuProfilerPerfCounterConfig_CacheFlushOnCounterCollectionStr = "#3543519762";
static const char* pGpuProfilerPerfCounterConfig_GranularityStr = "#3380953453";
static const char* pGpuProfilerSqttConfig_TokenMaskStr = "#258959117";
static const char* pGpuProfilerSqttConfig_SEMaskStr = "#113814584";
static const char* pGpuProfilerSqttConfig_PipelineHashStr = "#562315366";
static const char* pGpuProfilerSqttConfig_PipelineHashAsApiPsoHashStr = "#1180115076";
static const char* pGpuProfilerSqttConfig_TsHashHiStr = "#3100319562";
static const char* pGpuProfilerSqttConfig_TsHashLoStr = "#3535846108";
static const char* pGpuProfilerSqttConfig_VsHashHiStr = "#3546147188";
static const char* pGpuProfilerSqttConfig_VsHashLoStr = "#2975119762";
static const char* pGpuProfilerSqttConfig_HsHashHiStr = "#3728558198";
static const char* pGpuProfilerSqttConfig_HsHashLoStr = "#3225818008";
static const char* pGpuProfilerSqttConfig_DsHashHiStr = "#2656705114";
static const char* pGpuProfilerSqttConfig_DsHashLoStr = "#2018464044";
static const char* pGpuProfilerSqttConfig_GsHashHiStr = "#4196229765";
static const char* pGpuProfilerSqttConfig_GsHashLoStr = "#338172111";
static const char* pGpuProfilerSqttConfig_MsHashHiStr = "#2228026635";
static const char* pGpuProfilerSqttConfig_MsHashLoStr = "#2329383897";
static const char* pGpuProfilerSqttConfig_PsHashHiStr = "#1306425790";
static const char* pGpuProfilerSqttConfig_PsHashLoStr = "#1340672576";
static const char* pGpuProfilerSqttConfig_CsHashHiStr = "#2590676505";
static const char* pGpuProfilerSqttConfig_CsHashLoStr = "#3160424003";
static const char* pGpuProfilerSqttConfig_MaxDrawsStr = "#2938324269";
static const char* pGpuProfilerSqttConfig_AddTtvHashesStr = "#121855179";
static const char* pGpuProfilerSqttConfig_BufferSizeStr = "#3633385103";
static const char* pGpuProfilerSqttConfig_StallBehaviorStr = "#1808881616";
static const char* pGpuProfilerSpmConfig_SpmPerfCounterConfigFileStr = "#1162192613";
static const char* pGpuProfilerSpmConfig_SpmTraceIntervalStr = "#3291932008";
static const char* pGpuProfilerSpmConfig_SpmBufferSizeStr = "#1857600927";
static const char* pCmdBufferLoggerEnabledStr = "#1206982834";
static const char* pCmdBufferLoggerConfig_CmdBufferLoggerAnnotationsStr = "#462141291";
static const char* pCmdBufferLoggerConfig_CmdBufferLoggerSingleStepStr = "#2784236609";
static const char* pCmdBufferLoggerConfig_EmbedDrawDispatchInfoStr = "#1801313176";
static const char* pPm4InstrumentorEnabledStr = "#817764955";
static const char* pPm4InstrumentorConfig_LogDirectoryStr = "#2823822363";
static const char* pPm4InstrumentorConfig_FilenameSuffixStr = "#1848754234";
static const char* pPm4InstrumentorConfig_DumpModeStr = "#1873500379";
static const char* pPm4InstrumentorConfig_DumpIntervalStr = "#1471065745";
static const char* pInterfaceLoggerEnabledStr = "#2678054117";
static const char* pInterfaceLoggerConfig_LogDirectoryStr = "#3997041373";
static const char* pInterfaceLoggerConfig_MultithreadedStr = "#4177532476";
static const char* pInterfaceLoggerConfig_BasePresetStr = "#3886684530";
static const char* pInterfaceLoggerConfig_ElevatedPresetStr = "#3991423149";
static const uint32 g_palPlatformNumSettings = 94;
static const SettingNameHash g_palPlatformSettingHashList[] = {
#if PAL_ENABLE_PRINTS_ASSERTS
87264462,
#endif
#if PAL_ENABLE_PRINTS_ASSERTS
3111217572,
#endif
#if PAL_ENABLE_PRINTS_ASSERTS
1058771018,
#endif
#if PAL_ENABLE_PRINTS_ASSERTS
2827996440,
#endif
#if PAL_ENABLE_PRINTS_ASSERTS
4283850211,
#endif
#if PAL_ENABLE_PRINTS_ASSERTS
74653004,
#endif
#if PAL_ENABLE_PRINTS_ASSERTS
1110605001,
#endif
#if PAL_ENABLE_PRINTS_ASSERTS
3333004859,
#endif
3288205286,
3789517094,
3387502554,
3362163801,
1802476957,
2933558408,
3045745206,
3912270641,
1196026490,
2763643877,
1533629425,
3989097989,
689918007,
2929386323,
480313510,
3176801238,
219820144,
2551463600,
266798632,
3945706803,
3387883484,
452099995,
2545297707,
1692103889,
1276999751,
2059768529,
3490085415,
2716183183,
602986973,
17496565,
3630548216,
1092484338,
2743656777,
3204367348,
2717664970,
1666123781,
3543519762,
3380953453,
258959117,
113814584,
562315366,
1180115076,
3100319562,
3535846108,
3546147188,
2975119762,
3728558198,
3225818008,
2656705114,
2018464044,
4196229765,
338172111,
2228026635,
2329383897,
1306425790,
1340672576,
2590676505,
3160424003,
2938324269,
121855179,
3633385103,
1808881616,
1162192613,
3291932008,
1857600927,
1206982834,
462141291,
2784236609,
1801313176,
817764955,
2823822363,
1848754234,
1873500379,
1471065745,
2678054117,
3997041373,
4177532476,
3886684530,
3991423149,
};
static const uint8 g_palPlatformJsonData[] = {
26, 250, 84, 220, 1, 92, 96, 106, 146, 207, 33, 32, 160, 3, 90, 155, 144, 218, 198, 78, 114, 176, 126, 93, 73, 14,
35, 100, 246, 56, 59, 44, 57, 20, 138, 53, 137, 42, 27, 8, 229, 59, 94, 194, 49, 22, 213, 135, 171, 196, 161, 14,
45, 34, 34, 61, 232, 36, 103, 94, 214, 160, 197, 1, 129, 99, 2, 145, 103, 102, 239, 97, 44, 11, 73, 81, 247, 220,
133, 159, 17, 255, 228, 97, 133, 114, 168, 191, 166, 31, 92, 208, 45, 88, 235, 91, 0, 25, 151, 155, 250, 5, 63, 105,
254, 118, 226, 87, 172, 48, 155, 152, 68, 133, 97, 242, 104, 165, 225, 113, 176, 135, 164, 117, 137, 80, 213, 220,
44, 139, 84, 68, 195, 210, 90, 199, 153, 238, 27, 151, 247, 237, 247, 194, 217, 56, 78, 63, 222, 3, 91, 190, 142,
205, 230, 244, 200, 45, 47, 197, 128, 13, 181, 224, 177, 89, 174, 112, 114, 210, 146, 100, 221, 59, 60, 87, 192,
144, 176, 157, 68, 18, 157, 212, 164, 34, 162, 223, 253, 212, 193, 6, 160, 214, 192, 44, 239, 33, 27, 219, 99, 161,
152, 203, 191, 212, 151, 234, 240, 74, 160, 254, 143, 58, 49, 243, 109, 209, 122, 179, 88, 195, 240, 226, 107, 16,
61, 209, 58, 225, 73, 229, 92, 103, 12, 61, 144, 62, 206, 129, 50, 204, 116, 14, 91, 60, 76, 66, 255, 2, 134, 233,
241, 63, 240, 235, 218, 207, 27, 4, 167, 191, 155, 138, 164, 241, 10, 27, 140, 158, 25, 87, 161, 186, 69, 116, 158,
133, 0, 46, 7, 23, 65, 233, 43, 26, 163, 74, 120, 100, 65, 130, 196, 48, 177, 11, 34, 145, 37, 170, 142, 4, 210,
145, 13, 43, 105, 121, 63, 90, 249, 101, 123, 171, 216, 91, 0, 85, 20, 86, 20, 22, 194, 177, 177, 226, 131, 208,
217, 27, 87, 195, 139, 172, 17, 249, 54, 9, 160, 92, 248, 237, 201, 71, 12, 68, 141, 194, 71, 158, 46, 46, 20, 217,
153, 220, 105, 45, 64, 31, 13, 166, 246, 90, 9, 49, 125, 249, 168, 117, 97, 169, 72, 130, 154, 154, 114, 1, 80, 126,
16, 83, 169, 101, 0, 152, 241, 101, 35, 215, 14, 135, 213, 250, 249, 26, 205, 154, 96, 97, 181, 7, 227, 111, 81,
106, 161, 84, 53, 80, 50, 111, 211, 72, 187, 157, 221, 35, 220, 235, 11, 114, 54, 93, 126, 114, 92, 191, 98, 225,
18, 8, 208, 95, 227, 196, 241, 15, 229, 221, 190, 252, 14, 195, 150, 7, 203, 61, 242, 61, 104, 139, 101, 33, 13,
234, 60, 213, 27, 87, 149, 220, 190, 115, 197, 250, 196, 67, 159, 226, 206, 240, 196, 245, 55, 31, 139, 120, 213, 6,
177, 151, 238, 184, 203, 165, 67, 6, 15, 58, 112, 81, 216, 159, 237, 5, 224, 34, 89, 33, 105, 29, 254, 14, 70, 42,
151, 207, 83, 55, 182, 186, 131, 210, 180, 90, 106, 210, 55, 219, 137, 203, 183, 55, 179, 201, 28, 21, 34, 189, 130,
145, 121, 9, 13, 5, 209, 147, 171, 1, 172, 144, 217, 148, 96, 37, 165, 103, 171, 112, 232, 240, 38, 165, 109, 169,
187, 72, 145, 185, 249, 26, 47, 49, 82, 144, 123, 90, 62, 166, 104, 223, 203, 137, 6, 215, 159, 114, 171, 35, 82,
70, 199, 170, 106, 113, 16, 66, 134, 208, 244, 141, 74, 255, 80, 107, 237, 50, 162, 113, 202, 76, 218, 56, 1, 79,
118, 35, 59, 76, 38, 22, 248, 71, 242, 42, 76, 76, 226, 125, 51, 29, 73, 126, 209, 232, 215, 64, 232, 166, 171, 210,
188, 251, 80, 49, 251, 92, 253, 132, 142, 150, 114, 5, 178, 29, 107, 135, 113, 234, 2, 209, 18, 74, 22, 179, 46,
197, 164, 24, 66, 103, 156, 161, 39, 41, 221, 148, 130, 119, 162, 111, 241, 0, 145, 249, 92, 180, 98, 106, 40, 156,
79, 85, 146, 39, 184, 156, 177, 241, 185, 227, 175, 129, 174, 178, 135, 15, 95, 9, 22, 33, 137, 226, 153, 95, 17,
23, 14, 177, 79, 4, 247, 169, 112, 66, 45, 217, 10, 235, 183, 216, 58, 45, 235, 252, 217, 166, 225, 105, 224, 168,
199, 106, 91, 150, 166, 156, 71, 62, 209, 106, 182, 228, 63, 221, 53, 252, 129, 128, 231, 242, 106, 218, 176, 76,
127, 58, 10, 169, 48, 142, 57, 148, 66, 58, 230, 12, 176, 120, 64, 74, 210, 124, 166, 184, 135, 179, 250, 141, 198,
220, 46, 24, 91, 239, 114, 252, 58, 29, 53, 47, 160, 212, 186, 20, 142, 149, 163, 24, 30, 31, 166, 181, 222, 155,
54, 130, 205, 205, 45, 77, 165, 61, 186, 79, 158, 55, 181, 122, 131, 236, 43, 91, 159, 3, 238, 69, 149, 204, 192,
70, 35, 43, 93, 16, 99, 71, 4, 128, 145, 45, 0, 98, 12, 54, 153, 143, 182, 68, 68, 203, 144, 147, 206, 41, 185, 10,
116, 11, 166, 92, 211, 9, 243, 2, 116, 72, 125, 99, 142, 192, 91, 188, 167, 48, 152, 82, 107, 206, 3, 199, 9, 247,
94, 125, 255, 18, 200, 67, 5, 174, 204, 148, 210, 220, 65, 120, 131, 249, 126, 110, 225, 98, 57, 86, 251, 239, 125,
213, 181, 165, 83, 5, 85, 49, 247, 8, 126, 54, 48, 140, 221, 79, 89, 74, 50, 72, 145, 168, 211, 59, 240, 25, 1, 249,
72, 93, 206, 67, 254, 23, 18, 227, 166, 254, 142, 29, 205, 129, 109, 140, 217, 162, 227, 240, 174, 137, 214, 132,
210, 111, 66, 243, 49, 112, 230, 171, 2, 183, 34, 38, 24, 31, 98, 181, 226, 133, 244, 173, 120, 26, 17, 182, 86,
238, 164, 207, 198, 145, 249, 152, 155, 244, 214, 67, 104, 150, 146, 152, 239, 231, 201, 173, 47, 62, 243, 12, 200,
89, 235, 80, 165, 244, 157, 59, 106, 251, 98, 149, 215, 135, 207, 40, 72, 122, 213, 232, 199, 34, 251, 157, 235, 78,
126, 190, 100, 196, 71, 53, 11, 5, 127, 162, 62, 146, 103, 148, 156, 84, 57, 162, 29, 110, 182, 240, 146, 113, 200,
70, 233, 57, 1, 147, 158, 71, 47, 232, 190, 196, 12, 22, 5, 25, 46, 195, 2, 252, 0, 106, 251, 135, 15, 84, 168, 35,
12, 89, 92, 218, 193, 86, 190, 167, 22, 102, 161, 98, 132, 167, 251, 219, 176, 167, 46, 235, 93, 28, 173, 17, 165,
199, 143, 112, 203, 125, 213, 39, 178, 242, 29, 143, 161, 83, 38, 154, 247, 29, 37, 169, 59, 34, 176, 45, 68, 232,
77, 178, 168, 233, 221, 226, 34, 63, 78, 174, 206, 97, 90, 239, 199, 244, 216, 63, 34, 53, 11, 91, 31, 59, 239, 14,
205, 155, 171, 206, 231, 126, 202, 212, 98, 204, 146, 221, 37, 155, 196, 34, 11, 85, 73, 14, 177, 131, 15, 2, 222,
214, 25, 239, 2, 153, 231, 239, 52, 39, 14, 192, 132, 170, 20, 189, 29, 30, 155, 98, 42, 11, 45, 45, 235, 25, 28,
18, 161, 151, 210, 248, 212, 223, 74, 154, 157, 106, 32, 109, 82, 148, 205, 44, 243, 111, 105, 78, 110, 187, 32,
180, 92, 173, 12, 164, 188, 86, 15, 202, 19, 42, 241, 200, 87, 50, 253, 31, 4, 164, 250, 183, 14, 214, 71, 247, 232,
223, 211, 222, 228, 55, 181, 114, 120, 82, 143, 217, 168, 166, 232, 139, 156, 38, 150, 247, 201, 146, 170, 86, 23,
7, 78, 53, 223, 77, 63, 20, 210, 241, 125, 171, 227, 210, 146, 12, 41, 104, 211, 225, 184, 197, 243, 230, 202, 129,
192, 240, 234, 120, 119, 213, 219, 249, 113, 246, 111, 151, 200, 114, 77, 166, 15, 64, 19, 36, 9, 118, 202, 189, 14,
21, 91, 133, 77, 124, 75, 159, 46, 177, 103, 236, 99, 90, 152, 95, 102, 36, 190, 180, 91, 20, 215, 112, 19, 101,
218, 135, 1, 29, 130, 229, 76, 77, 72, 227, 117, 179, 250, 2, 73, 62, 251, 234, 174, 198, 252, 40, 210, 98, 91, 46,
156, 136, 220, 187, 86, 251, 53, 116, 97, 143, 139, 208, 166, 225, 51, 56, 50, 176, 172, 145, 139, 198, 230, 56,
103, 227, 29, 66, 158, 234, 85, 8, 218, 62, 1, 18, 219, 242, 122, 207, 91, 151, 216, 186, 232, 196, 186, 246, 63, 2,
90, 28, 207, 75, 20, 6, 152, 42, 246, 156, 20, 189, 38, 165, 179, 82, 102, 120, 40, 195, 14, 164, 211, 245, 82, 180,
179, 224, 86, 36, 51, 155, 87, 74, 242, 231, 77, 20, 14, 55, 250, 205, 13, 21, 188, 185, 216, 136, 8, 142, 130, 19,
197, 149, 204, 171, 64, 88, 18, 146, 30, 0, 137, 217, 44, 74, 142, 32, 122, 5, 84, 193, 132, 203, 204, 246, 203, 68,
11, 67, 204, 4, 151, 72, 38, 173, 235, 129, 140, 247, 18, 185, 214, 82, 154, 87, 132, 143, 222, 77, 162, 149, 172,
36, 91, 246, 9, 185, 224, 3, 238, 158, 162, 183, 181, 85, 106, 128, 121, 117, 41, 86, 196, 35, 131, 246, 30, 38,
215, 159, 2, 247, 68, 179, 231, 151, 248, 160, 56, 227, 148, 98, 197, 73, 113, 48, 217, 252, 76, 180, 230, 229, 157,
222, 91, 177, 234, 36, 101, 67, 174, 97, 144, 252, 24, 51, 223, 38, 136, 36, 27, 45, 3, 214, 197, 28, 28, 114, 55,
157, 37, 215, 65, 219, 167, 97, 147, 27, 190, 124, 192, 65, 10, 167, 223, 25, 97, 33, 70, 44, 9, 145, 41, 70, 217,
23, 17, 23, 35, 179, 196, 230, 133, 120, 209, 253, 113, 21, 244, 238, 41, 147, 74, 100, 111, 204, 248, 77, 162, 239,
210, 35, 149, 72, 224, 190, 123, 80, 140, 219, 117, 45, 143, 183, 73, 94, 28, 154, 232, 113, 93, 159, 224, 170, 230,
120, 25, 107, 13, 99, 78, 212, 203, 111, 214, 125, 34, 245, 119, 134, 66, 101, 82, 179, 18, 111, 28, 111, 198, 254,
80, 56, 58, 53, 162, 6, 88, 228, 160, 78, 137, 192, 151, 32, 30, 77, 220, 89, 246, 206, 68, 138, 3, 235, 213, 144,
169, 220, 78, 245, 20, 158, 96, 157, 16, 4, 53, 44, 114, 140, 37, 170, 135, 161, 24, 9, 73, 248, 213, 23, 2, 102,
247, 46, 106, 243, 114, 5, 154, 11, 91, 145, 90, 177, 204, 12, 247, 147, 240, 238, 185, 30, 133, 146, 236, 171, 110,
51, 112, 71, 31, 204, 192, 145, 213, 21, 106, 140, 207, 22, 106, 127, 254, 85, 43, 40, 183, 204, 83, 67, 97, 125, 6,
35, 184, 240, 19, 22, 241, 102, 104, 129, 254, 191, 156, 224, 84, 109, 196, 126, 71, 82, 111, 85, 74, 71, 134, 218,
114, 87, 66, 254, 197, 197, 200, 90, 20, 52, 215, 76, 14, 37, 235, 158, 192, 145, 234, 53, 57, 36, 185, 17, 126, 20,
169, 13, 125, 127, 127, 184, 209, 99, 178, 191, 103, 46, 170, 177, 14, 13, 79, 15, 252, 76, 95, 145, 1, 61, 133,
123, 214, 151, 217, 241, 250, 232, 214, 130, 124, 56, 221, 9, 83, 151, 25, 32, 55, 68, 15, 12, 55, 169, 98, 234, 39,
156, 15, 253, 248, 132, 197, 36, 151, 64, 183, 211, 163, 19, 132, 122, 123, 74, 36, 140, 167, 2, 138, 203, 206, 79,
230, 112, 80, 41, 11, 66, 175, 19, 216, 47, 27, 97, 53, 135, 28, 246, 34, 176, 144, 71, 75, 119, 48, 68, 86, 233,
39, 152, 206, 5, 54, 20, 133, 92, 101, 235, 41, 139, 87, 135, 132, 204, 231, 17, 251, 95, 234, 151, 2, 232, 182,
191, 232, 39, 159, 206, 188, 15, 126, 69, 150, 57, 215, 108, 41, 105, 241, 127, 74, 42, 132, 189, 92, 241, 196, 11,
147, 175, 65, 8, 80, 34, 109, 1, 226, 189, 228, 167, 138, 146, 231, 121, 193, 225, 97, 213, 10, 185, 102, 97, 206,
127, 1, 136, 253, 106, 99, 27, 45, 15, 90, 228, 198, 171, 148, 86, 89, 56, 186, 123, 235, 171, 211, 26, 40, 139,
227, 65, 119, 148, 154, 208, 6, 100, 29, 74, 101, 156, 180, 121, 101, 236, 237, 32, 2, 193, 165, 23, 110, 247, 167,
101, 123, 119, 138, 232, 100, 249, 69, 45, 127, 113, 39, 123, 61, 100, 244, 199, 204, 235, 60, 46, 218, 253, 74,
246, 143, 131, 140, 191, 9, 78, 241, 230, 119, 127, 96, 121, 109, 161, 119, 134, 56, 34, 240, 234, 34, 64, 15, 135,
79, 1, 51, 218, 60, 148, 14, 238, 98, 147, 137, 185, 123, 174, 11, 48, 86, 133, 60, 18, 105, 204, 176, 22, 247, 163,
42, 245, 144, 230, 165, 54, 51, 204, 152, 112, 81, 178, 252, 41, 144, 80, 209, 208, 159, 246, 115, 8, 214, 251, 76,
116, 175, 134, 57, 170, 33, 83, 62, 97, 14, 51, 173, 101, 82, 95, 154, 224, 115, 146, 187, 86, 61, 12, 239, 84, 206,
70, 209, 40, 151, 31, 243, 176, 170, 5, 136, 103, 192, 112, 68, 7, 110, 71, 221, 144, 19, 197, 10, 219, 253, 66, 8,
112, 45, 79, 116, 213, 189, 121, 247, 68, 53, 133, 227, 45, 122, 16, 184, 69, 228, 157, 204, 253, 20, 98, 165, 244,
49, 168, 241, 7, 62, 46, 66, 114, 217, 192, 121, 133, 105, 175, 94, 155, 140, 152, 196, 107, 32, 122, 246, 139, 53,
22, 253, 205, 208, 247, 12, 103, 191, 27, 105, 61, 249, 192, 139, 241, 113, 30, 233, 191, 78, 128, 215, 178, 133, 3,
65, 132, 18, 6, 18, 185, 221, 234, 102, 246, 22, 223, 111, 201, 86, 6, 160, 233, 196, 117, 104, 61, 243, 203, 201,
71, 91, 115, 8, 116, 193, 50, 81, 12, 116, 154, 87, 22, 15, 240, 135, 113, 38, 194, 115, 85, 218, 64, 199, 165, 37,
91, 208, 70, 63, 71, 17, 110, 16, 65, 234, 149, 81, 102, 198, 66, 31, 51, 37, 194, 146, 57, 255, 166, 8, 14, 163,
246, 152, 106, 44, 158, 1, 123, 114, 71, 179, 152, 8, 32, 208, 135, 166, 8, 213, 243, 166, 198, 47, 164, 118, 79,
13, 154, 114, 28, 8, 209, 195, 125, 230, 53, 174, 244, 81, 29, 122, 253, 180, 113, 119, 194, 172, 192, 221, 102,
141, 65, 49, 37, 156, 206, 20, 58, 41, 175, 92, 198, 72, 165, 71, 38, 45, 25, 23, 28, 104, 165, 139, 245, 48, 17,
164, 169, 129, 206, 137, 136, 213, 14, 163, 65, 27, 197, 21, 141, 196, 109, 246, 73, 171, 135, 5, 197, 102, 157,
138, 147, 60, 129, 174, 103, 0, 109, 28, 240, 218, 250, 34, 26, 23, 0, 221, 228, 78, 71, 221, 120, 53, 51, 2, 84,
232, 91, 41, 135, 237, 227, 0, 240, 239, 67, 61, 163, 104, 135, 99, 135, 134, 61, 145, 238, 175, 192, 247, 131, 208,
84, 215, 83, 236, 247, 122, 142, 20, 227, 193, 202, 203, 249, 251, 79, 160, 132, 95, 104, 170, 152, 147, 69, 55, 56,
87, 202, 163, 26, 118, 241, 94, 125, 102, 148, 85, 126, 46, 186, 68, 114, 48, 1, 161, 15, 26, 188, 56, 29, 225, 161,
117, 18, 16, 28, 150, 212, 28, 218, 179, 73, 47, 246, 131, 7, 210, 6, 132, 100, 68, 32, 145, 168, 20, 72, 188, 38,
162, 224, 12, 50, 135, 47, 192, 162, 47, 180, 64, 8, 121, 87, 39, 224, 218, 107, 60, 236, 71, 37, 210, 139, 178,
153, 102, 176, 171, 27, 83, 27, 251, 19, 238, 12, 108, 32, 76, 248, 174, 235, 120, 199, 70, 180, 9, 92, 185, 247, 3,
113, 17, 178, 49, 24, 221, 162, 57, 44, 209, 98, 75, 117, 87, 226, 205, 74, 196, 94, 222, 233, 85, 83, 23, 87, 140,
94, 26, 41, 223, 236, 212, 104, 157, 205, 90, 77, 108, 75, 232, 168, 228, 17, 18, 27, 188, 59, 249, 181, 141, 150,
152, 91, 91, 118, 11, 216, 128, 15, 152, 51, 60, 152, 253, 29, 248, 52, 212, 190, 204, 237, 63, 4, 111, 40, 122,
108, 72, 151, 36, 94, 140, 99, 236, 133, 27, 29, 173, 63, 179, 151, 236, 194, 8, 192, 98, 212, 139, 216, 79, 71, 6,
118, 155, 165, 193, 101, 109, 195, 20, 26, 163, 91, 4, 56, 72, 106, 224, 241, 73, 169, 200, 131, 107, 58, 160, 108,
100, 226, 232, 124, 199, 32, 90, 153, 242, 241, 188, 123, 147, 221, 145, 190, 51, 18, 80, 52, 25, 186, 59, 156, 141,
13, 231, 108, 227, 227, 94, 54, 33, 144, 121, 187, 50, 14, 2, 69, 195, 55, 10, 54, 13, 25, 62, 174, 180, 116, 65,
149, 17, 24, 192, 243, 9, 12, 163, 103, 24, 221, 128, 199, 0, 27, 145, 14, 194, 204, 2, 181, 35, 0, 0, 95, 152, 125,
80, 116, 35, 190, 217, 206, 6, 237, 108, 168, 169, 117, 177, 214, 255, 255, 198, 223, 151, 232, 99, 96, 112, 62,
179, 35, 13, 66, 58, 116, 178, 106, 117, 153, 51, 120, 97, 91, 232, 204, 116, 111, 49, 233, 207, 213, 247, 102, 114,
46, 130, 213, 139, 9, 40, 185, 121, 176, 7, 17, 72, 69, 102, 113, 159, 169, 11, 22, 130, 235, 235, 15, 154, 247,
177, 248, 211, 94, 91, 163, 138, 175, 109, 168, 22, 45, 252, 156, 227, 74, 222, 177, 208, 18, 125, 245, 146, 211,
215, 101, 193, 57, 44, 131, 39, 187, 20, 176, 168, 166, 225, 207, 42, 127, 0, 96, 204, 156, 139, 49, 168, 229, 112,
55, 77, 226, 241, 90, 217, 13, 48, 13, 164, 44, 167, 72, 214, 181, 100, 22, 168, 109, 219, 126, 55, 12, 37, 67, 18,
148, 242, 150, 106, 75, 20, 222, 224, 137, 159, 215, 66, 93, 171, 78, 89, 235, 226, 23, 176, 148, 123, 139, 178, 95,
243, 73, 76, 178, 192, 155, 207, 69, 83, 40, 227, 240, 64, 222, 14, 250, 156, 133, 2, 122, 148, 148, 195, 71, 181,
87, 89, 204, 45, 106, 73, 137, 80, 57, 21, 204, 254, 203, 212, 170, 87, 97, 156, 133, 246, 67, 59, 131, 235, 10,
225, 219, 163, 1, 98, 133, 167, 230, 54, 98, 157, 22, 76, 90, 4, 19, 132, 39, 186, 78, 150, 56, 16, 140, 20, 45, 0,
21, 5, 173, 140, 147, 92, 187, 38, 144, 249, 16, 46, 51, 252, 222, 188, 32, 140, 163, 164, 171, 157, 62, 131, 240,
30, 222, 197, 166, 145, 209, 157, 165, 192, 129, 220, 154, 82, 205, 99, 249, 78, 90, 103, 33, 57, 5, 83, 21, 181, 4,
135, 42, 79, 194, 22, 11, 59, 6, 197, 155, 110, 73, 68, 22, 12, 105, 65, 255, 235, 45, 48, 136, 61, 71, 12, 117,
131, 70, 217, 29, 155, 250, 99, 129, 212, 92, 170, 177, 10, 244, 88, 18, 92, 173, 251, 134, 129, 163, 184, 130, 92,
92, 71, 157, 73, 164, 229, 72, 133, 97, 112, 233, 204, 84, 36, 178, 187, 186, 173, 13, 136, 152, 127, 126, 63, 19,
11, 34, 243, 169, 216, 126, 165, 241, 5, 33, 145, 97, 214, 209, 194, 120, 214, 52, 97, 244, 83, 75, 58, 169, 40, 1,
133, 247, 96, 220, 212, 166, 109, 228, 230, 159, 12, 165, 160, 197, 96, 113, 158, 110, 134, 60, 214, 89, 125, 104,
49, 73, 46, 137, 151, 148, 74, 29, 179, 218, 160, 198, 29, 186, 39, 243, 94, 30, 220, 89, 224, 148, 100, 130, 141,
111, 9, 208, 116, 39, 219, 24, 163, 23, 248, 128, 5, 237, 108, 112, 164, 159, 135, 46, 54, 45, 52, 246, 225, 107,
209, 199, 220, 75, 123, 101, 219, 125, 121, 128, 171, 243, 224, 120, 168, 238, 115, 218, 57, 136, 5, 218, 234, 73,
59, 184, 56, 93, 70, 82, 112, 35, 6, 120, 46, 131, 149, 168, 162, 184, 25, 153, 139, 77, 156, 176, 120, 162, 44, 0,
243, 135, 233, 86, 221, 25, 247, 12, 213, 23, 211, 168, 244, 65, 247, 179, 42, 247, 134, 222, 121, 59, 72, 235, 195,
94, 29, 83, 33, 107, 28, 135, 160, 216, 81, 49, 109, 51, 62, 73, 225, 218, 43, 68, 194, 10, 15, 183, 99, 83, 25, 30,
239, 20, 162, 219, 206, 80, 94, 76, 224, 155, 26, 181, 19, 24, 31, 2, 7, 216, 104, 150, 242, 225, 27, 61, 73, 115,
81, 149, 110, 129, 212, 15, 120, 86, 10, 89, 172, 208, 237, 167, 22, 226, 230, 211, 220, 22, 92, 59, 246, 237, 184,
150, 34, 10, 233, 144, 130, 141, 136, 5, 62, 106, 91, 208, 225, 209, 46, 230, 25, 92, 68, 136, 131, 22, 92, 145, 30,
124, 242, 41, 243, 102, 86, 250, 238, 105, 230, 207, 134, 13, 159, 9, 218, 146, 239, 135, 248, 35, 235, 51, 14, 4,
212, 202, 133, 79, 150, 246, 191, 95, 179, 245, 141, 105, 40, 80, 22, 162, 39, 248, 138, 101, 249, 128, 187, 154,
117, 200, 240, 242, 119, 139, 103, 160, 138, 96, 207, 214, 209, 139, 31, 240, 238, 1, 231, 22, 97, 46, 194, 52, 55,
128, 61, 138, 182, 253, 157, 196, 163, 44, 83, 253, 50, 155, 9, 225, 126, 144, 7, 8, 95, 222, 9, 255, 73, 138, 141,
17, 152, 36, 171, 131, 220, 66, 126, 149, 24, 206, 140, 153, 151, 186, 113, 242, 38, 56, 115, 218, 239, 121, 7, 93,
48, 182, 225, 55, 122, 36, 60, 138, 35, 11, 219, 157, 139, 227, 133, 71, 140, 155, 215, 228, 72, 116, 170, 156, 160,
20, 171, 125, 130, 229, 195, 97, 16, 254, 241, 151, 17, 6, 77, 173, 175, 69, 54, 106, 111, 116, 207, 175, 2, 39,
143, 51, 124, 171, 11, 148, 203, 31, 41, 134, 146, 40, 218, 79, 122, 166, 165, 150, 214, 118, 62, 142, 99, 198, 159,
116, 175, 26, 247, 143, 116, 191, 253, 152, 120, 143, 205, 206, 164, 208, 147, 245, 251, 134, 54, 53, 191, 222, 157,
97, 42, 115, 154, 97, 40, 159, 96, 45, 165, 26, 136, 118, 129, 48, 199, 218, 88, 159, 92, 176, 189, 141, 27, 226,
155, 176, 29, 217, 218, 65, 9, 34, 249, 54, 159, 232, 30, 197, 127, 161, 107, 155, 162, 109, 65, 91, 11, 222, 150,
144, 226, 168, 147, 64, 155, 25, 227, 98, 149, 0, 191, 149, 180, 162, 250, 138, 214, 222, 84, 31, 238, 230, 3, 150,
113, 51, 180, 14, 65, 111, 56, 65, 8, 223, 36, 93, 251, 87, 226, 99, 129, 152, 150, 190, 210, 157, 154, 138, 227,
176, 241, 71, 46, 142, 245, 188, 181, 174, 80, 141, 135, 150, 82, 160, 1, 194, 114, 164, 188, 146, 49, 185, 124,
226, 170, 86, 65, 252, 118, 215, 164, 220, 49, 192, 32, 49, 19, 92, 3, 252, 53, 198, 43, 141, 139, 84, 70, 74, 65,
228, 49, 4, 184, 107, 206, 17, 101, 32, 184, 222, 118, 173, 18, 41, 248, 168, 150, 237, 149, 56, 148, 83, 235, 225,
166, 14, 199, 89, 21, 78, 145, 176, 176, 32, 205, 120, 115, 28, 135, 26, 229, 186, 174, 6, 193, 161, 88, 169, 157,
85, 20, 192, 216, 93, 127, 12, 20, 49, 112, 201, 146, 221, 244, 92, 215, 81, 235, 224, 155, 51, 155, 196, 72, 225,
123, 83, 199, 213, 167, 101, 254, 109, 41, 134, 225, 255, 152, 64, 165, 136, 202, 253, 12, 227, 171, 80, 50, 78, 4,
239, 103, 14, 180, 142, 45, 250, 140, 142, 8, 145, 199, 205, 24, 106, 30, 160, 91, 144, 47, 254, 44, 96, 86, 85,
118, 209, 228, 104, 21, 176, 93, 154, 2, 60, 111, 89, 150, 222, 230, 98, 182, 3, 201, 221, 124, 175, 223, 205, 9,
147, 194, 123, 192, 230, 2, 3, 116, 126, 237, 75, 249, 158, 40, 99, 10, 179, 174, 183, 162, 76, 128, 55, 138, 42,
105, 219, 104, 111, 64, 9, 27, 232, 124, 208, 150, 114, 33, 172, 196, 203, 200, 206, 222, 60, 87, 24, 37, 178, 202,
209, 182, 78, 255, 184, 27, 2, 62, 111, 40, 195, 171, 66, 200, 231, 135, 109, 176, 106, 27, 247, 13, 105, 171, 98,
66, 30, 50, 81, 83, 93, 85, 111, 137, 34, 11, 18, 77, 176, 21, 209, 193, 126, 32, 197, 199, 153, 81, 145, 39, 131,
105, 159, 9, 231, 171, 107, 85, 216, 146, 238, 56, 225, 192, 102, 0, 74, 97, 179, 43, 5, 87, 130, 159, 218, 225,
208, 38, 21, 19, 171, 204, 43, 162, 217, 81, 75, 31, 38, 253, 167, 220, 145, 238, 28, 231, 219, 53, 240, 48, 208,
250, 54, 113, 99, 100, 209, 42, 234, 195, 74, 19, 205, 133, 78, 197, 252, 6, 205, 93, 32, 88, 105, 75, 133, 131, 2,
110, 89, 207, 121, 95, 121, 234, 102, 212, 77, 183, 32, 51, 198, 208, 149, 64, 0, 239, 157, 189, 192, 31, 105, 192,
91, 180, 222, 80, 214, 99, 14, 192, 9, 222, 27, 120, 17, 92, 48, 72, 232, 106, 238, 220, 136, 191, 61, 208, 35, 166,
46, 126, 177, 42, 218, 159, 122, 249, 92, 255, 199, 190, 49, 151, 53, 22, 75, 233, 205, 16, 119, 223, 79, 199, 252,
158, 225, 153, 231, 107, 209, 130, 45, 240, 116, 79, 78, 164, 102, 159, 31, 206, 157, 125, 210, 161, 215, 162, 77,
117, 72, 214, 162, 88, 194, 25, 232, 123, 116, 28, 80, 87, 45, 70, 147, 238, 232, 211, 14, 31, 101, 120, 197, 208,
227, 190, 53, 11, 106, 83, 90, 33, 44, 203, 31, 242, 191, 119, 208, 181, 172, 176, 159, 54, 218, 159, 253, 106, 142,
227, 202, 208, 3, 48, 3, 114, 205, 165, 3, 65, 214, 108, 33, 61, 120, 94, 4, 196, 92, 220, 207, 54, 133, 159, 163,
169, 214, 22, 107, 253, 154, 179, 131, 154, 69, 148, 84, 136, 143, 225, 68, 105, 245, 86, 229, 189, 154, 4, 220,
150, 47, 110, 146, 113, 159, 122, 215, 1, 78, 237, 114, 139, 221, 57, 252, 199, 148, 250, 119, 248, 23, 88, 175,
173, 22, 70, 246, 149, 157, 250, 113, 18, 161, 173, 71, 160, 221, 235, 107, 110, 69, 171, 200, 205, 101, 174, 44,
137, 87, 201, 182, 19, 95, 157, 60, 180, 209, 242, 38, 166, 180, 98, 245, 204, 162, 192, 167, 138, 17, 202, 81, 136,
246, 193, 26, 143, 180, 240, 206, 185, 179, 39, 196, 39, 204, 7, 132, 117, 189, 71, 158, 125, 106, 64, 15, 67, 96,
238, 148, 242, 205, 221, 67, 4, 135, 104, 15, 238, 192, 193, 118, 175, 72, 50, 232, 64, 37, 89, 148, 182, 28, 182,
151, 72, 181, 245, 218, 46, 232, 160, 129, 162, 161, 169, 157, 34, 80, 49, 254, 167, 135, 117, 74, 118, 171, 132,
209, 87, 216, 94, 169, 68, 251, 211, 124, 249, 128, 129, 21, 194, 166, 217, 15, 216, 234, 173, 80, 253, 139, 194,
90, 101, 81, 79, 105, 76, 69, 119, 0, 27, 6, 185, 98, 83, 28, 189, 64, 242, 172, 216, 53, 245, 94, 170, 167, 158,
12, 206, 181, 192, 130, 103, 208, 30, 58, 230, 174, 88, 108, 87, 102, 82, 160, 84, 159, 120, 242, 248, 133, 168,
168, 18, 58, 150, 101, 117, 60, 245, 138, 98, 225, 88, 76, 136, 142, 62, 53, 77, 123, 130, 36, 252, 184, 56, 169,
29, 208, 206, 221, 22, 189, 90, 18, 201, 48, 154, 196, 90, 53, 243, 34, 48, 202, 58, 31, 175, 41, 97, 97, 184, 16,
58, 101, 146, 152, 56, 14, 94, 32, 20, 205, 109, 231, 36, 151, 112, 248, 125, 154, 192, 137, 102, 143, 23, 139, 172,
66, 126, 57, 6, 131, 57, 21, 227, 72, 209, 129, 85, 0, 176, 31, 120, 209, 154, 94, 65, 179, 158, 65, 66, 188, 127,
138, 179, 121, 202, 231, 98, 80, 209, 156, 95, 17, 166, 78, 98, 69, 204, 236, 81, 20, 153, 250, 114, 172, 90, 136,
230, 13, 124, 237, 48, 171, 39, 138, 141, 146, 240, 130, 33, 51, 130, 56, 65, 181, 214, 30, 26, 119, 12, 142, 246,
103, 156, 194, 184, 162, 199, 127, 176, 222, 240, 160, 223, 138, 27, 114, 85, 161, 102, 189, 37, 73, 126, 32, 175,
168, 46, 214, 235, 134, 50, 248, 252, 249, 253, 247, 169, 156, 10, 110, 240, 21, 7, 201, 235, 247, 115, 127, 140,
131, 232, 181, 43, 170, 192, 239, 153, 174, 210, 182, 172, 128, 18, 200, 138, 176, 40, 181, 170, 126, 190, 100, 11,
232, 93, 162, 252, 179, 214, 228, 234, 60, 125, 99, 52, 247, 142, 90, 224, 112, 41, 230, 26, 40, 121, 101, 192, 79,
193, 172, 198, 57, 134, 73, 124, 103, 231, 34, 82, 30, 148, 213, 143, 181, 115, 73, 17, 217, 10, 240, 130, 73, 247,
197, 88, 248, 117, 181, 70, 46, 69, 10, 56, 194, 214, 219, 217, 242, 81, 232, 238, 243, 20, 252, 1, 199, 222, 78,
237, 132, 174, 67, 63, 235, 106, 229, 195, 202, 144, 146, 25, 91, 252, 233, 15, 81, 12, 135, 134, 104, 3, 31, 201,
55, 110, 177, 14, 173, 204, 212, 37, 215, 211, 160, 164, 237, 111, 39, 86, 67, 155, 201, 194, 109, 130, 188, 103,
31, 19, 252, 231, 237, 200, 173, 167, 180, 176, 194, 89, 235, 78, 155, 59, 164, 70, 193, 149, 218, 167, 155, 160,
121, 152, 117, 95, 123, 120, 231, 114, 68, 13, 86, 121, 127, 241, 143, 32, 93, 210, 219, 134, 91, 15, 132, 224, 74,
28, 5, 219, 96, 75, 131, 219, 167, 32, 210, 64, 225, 29, 177, 141, 236, 178, 112, 60, 130, 15, 18, 246, 25, 244,
123, 186, 22, 9, 156, 78, 138, 184, 240, 92, 122, 86, 72, 206, 17, 9, 149, 19, 116, 33, 240, 46, 202, 1, 17, 200,
122, 116, 235, 163, 225, 1, 222, 53, 61, 73, 155, 209, 76, 135, 1, 130, 19, 184, 132, 222, 132, 96, 174, 75, 190,
243, 169, 82, 160, 38, 47, 202, 217, 32, 166, 243, 8, 143, 149, 196, 8, 145, 21, 122, 47, 182, 176, 160, 200, 184,
243, 28, 194, 1, 13, 150, 116, 143, 53, 243, 141, 224, 139, 90, 158, 89, 81, 76, 124, 248, 91, 170, 21, 135, 19,
200, 46, 56, 93, 156, 47, 116, 252, 155, 119, 32, 66, 246, 5, 167, 153, 232, 129, 98, 205, 74, 69, 63, 177, 206, 66,
25, 114, 171, 134, 141, 250, 86, 52, 61, 230, 228, 18, 131, 176, 35, 87, 92, 254, 58, 251, 31, 172, 224, 61, 184,
207, 16, 45, 12, 26, 88, 114, 232, 116, 21, 85, 242, 131, 96, 189, 121, 120, 8, 243, 101, 208, 234, 163, 215, 0, 2,
150, 77, 246, 5, 177, 47, 178, 78, 192, 226, 195, 171, 224, 182, 239, 53, 73, 50, 140, 162, 181, 205, 253, 158, 21,
92, 133, 48, 37, 225, 149, 69, 152, 13, 112, 152, 120, 112, 251, 10, 226, 46, 223, 63, 149, 227, 186, 223, 218, 10,
161, 208, 182, 15, 51, 138, 229, 139, 11, 246, 21, 103, 41, 81, 45, 43, 83, 28, 41, 221, 231, 129, 217, 21, 188, 96,
95, 137, 105, 84, 190, 121, 237, 178, 9, 151, 30, 118, 65, 12, 76, 36, 247, 82, 3, 228, 136, 166, 190, 126, 161,
201, 18, 12, 20, 92, 229, 214, 207, 147, 225, 198, 2, 228, 12, 107, 214, 205, 163, 12, 1, 242, 56, 16, 220, 227, 13,
207, 177, 49, 169, 141, 228, 34, 72, 61, 203, 134, 229, 155, 97, 61, 234, 5, 251, 125, 142, 107, 167, 199, 249, 155,
227, 135, 177, 49, 178, 80, 151, 248, 189, 226, 188, 46, 104, 216, 231, 233, 117, 207, 159, 230, 19, 196, 145, 181,
78, 8, 8, 122, 4, 224, 78, 163, 167, 90, 102, 136, 231, 153, 56, 116, 127, 151, 0, 206, 52, 0, 246, 185, 77, 68,
241, 53, 170, 8, 13, 48, 140, 81, 29, 235, 253, 235, 182, 59, 171, 56, 144, 24, 52, 106, 41, 183, 172, 175, 164,
223, 158, 161, 129, 49, 73, 234, 25, 176, 42, 176, 160, 221, 194, 89, 31, 175, 20, 228, 72, 227, 43, 19, 113, 51,
195, 232, 167, 179, 16, 218, 61, 29, 143, 181, 4, 167, 243, 192, 36, 126, 237, 33, 138, 162, 120, 63, 189, 37, 133,
231, 94, 158, 125, 82, 2, 25, 0, 219, 236, 10, 153, 177, 238, 140, 110, 88, 115, 251, 200, 57, 125, 11, 71, 239, 94,
46, 29, 246, 102, 114, 112, 242, 72, 112, 214, 200, 22, 102, 93, 202, 251, 202, 51, 43, 116, 192, 60, 108, 31, 58,
123, 204, 235, 227, 193, 147, 201, 192, 105, 116, 165, 250, 118, 250, 83, 79, 160, 51, 108, 216, 169, 51, 78, 121,
84, 1, 28, 23, 112, 152, 200, 103, 136, 187, 43, 111, 152, 181, 80, 1, 21, 237, 228, 85, 48, 29, 15, 3, 101, 28,
183, 72, 125, 248, 25, 216, 33, 27, 38, 205, 208, 46, 230, 203, 152, 129, 86, 116, 116, 115, 45, 252, 197, 140, 14,
204, 31, 39, 30, 82, 182, 86, 36, 67, 41, 141, 136, 19, 0, 230, 158, 172, 121, 148, 67, 9, 41, 155, 83, 46, 249, 71,
84, 41, 193, 105, 26, 18, 55, 132, 126, 157, 128, 210, 161, 122, 33, 81, 130, 121, 78, 142, 231, 222, 220, 241, 35,
32, 214, 133, 31, 118, 51, 204, 236, 239, 160, 228, 213, 23, 34, 195, 86, 227, 102, 131, 211, 220, 11, 212, 191,
167, 124, 248, 239, 228, 133, 193, 134, 223, 236, 124, 16, 178, 37, 120, 63, 61, 180, 231, 137, 169, 26, 196, 78,
211, 43, 149, 170, 36, 42, 215, 140, 31, 211, 182, 59, 167, 216, 177, 114, 45, 138, 94, 173, 46, 225, 55, 53, 30,
105, 239, 140, 176, 83, 50, 234, 4, 220, 166, 201, 129, 120, 48, 71, 213, 53, 33, 198, 239, 64, 3, 63, 1, 241, 217,
185, 192, 124, 67, 154, 153, 29, 91, 18, 116, 161, 30, 109, 32, 200, 2, 123, 15, 230, 232, 31, 131, 236, 84, 139,
98, 185, 6, 96, 192, 167, 183, 154, 80, 80, 233, 129, 184, 163, 108, 0, 147, 142, 4, 8, 144, 102, 184, 108, 120, 82,
151, 77, 166, 190, 66, 29, 109, 224, 99, 240, 252, 81, 128, 63, 146, 107, 25, 22, 231, 46, 162, 237, 80, 141, 207,
95, 177, 78, 148, 79, 151, 43, 215, 12, 26, 234, 153, 100, 122, 89, 200, 226, 10, 13, 229, 58, 96, 160, 97, 203, 16,
36, 246, 134, 243, 222, 88, 187, 177, 156, 205, 1, 158, 140, 229, 2, 141, 98, 7, 193, 63, 211, 31, 60, 75, 9, 72,
27, 18, 126, 224, 36, 83, 136, 88, 22, 220, 67, 213, 164, 23, 151, 241, 108, 121, 156, 157, 75, 128, 112, 73, 209,
67, 126, 160, 11, 211, 40, 139, 230, 151, 145, 153, 175, 88, 253, 243, 251, 9, 101, 64, 46, 225, 168, 29, 133, 231,
204, 33, 101, 165, 73, 181, 37, 242, 188, 180, 195, 115, 3, 17, 30, 20, 60, 33, 204, 17, 195, 39, 51, 143, 70, 196,
136, 146, 91, 75, 188, 89, 68, 179, 114, 175, 24, 184, 153, 134, 212, 160, 48, 208, 210, 108, 6, 4, 100, 202, 148,
84, 219, 95, 170, 148, 134, 100, 145, 43, 91, 115, 87, 131, 200, 2, 9, 34, 150, 89, 11, 82, 73, 84, 152, 48, 226,
179, 164, 33, 186, 128, 213, 141, 170, 131, 192, 172, 238, 220, 159, 172, 82, 222, 98, 250, 13, 254, 11, 143, 237,
222, 100, 196, 97, 231, 221, 175, 182, 26, 45, 129, 118, 28, 194, 21, 143, 107, 71, 128, 89, 71, 176, 153, 140, 244,
45, 105, 249, 177, 215, 238, 23, 229, 154, 67, 153, 89, 164, 0, 232, 40, 203, 45, 54, 236, 169, 177, 47, 141, 104,
15, 127, 83, 17, 2, 106, 122, 36, 172, 158, 254, 79, 110, 86, 194, 222, 43, 172, 160, 214, 129, 162, 74, 42, 47,
108, 7, 254, 191, 16, 205, 242, 80, 163, 145, 24, 132, 144, 104, 65, 35, 11, 243, 60, 203, 241, 164, 45, 134, 209,
52, 112, 71, 235, 183, 116, 229, 0, 96, 243, 203, 248, 132, 63, 137, 109, 115, 30, 143, 221, 139, 126, 144, 75, 167,
7, 47, 235, 239, 140, 23, 161, 192, 179, 58, 54, 95, 10, 218, 100, 180, 133, 33, 157, 28, 214, 25, 42, 45, 196, 242,
41, 95, 131, 161, 0, 177, 255, 180, 191, 42, 254, 165, 165, 58, 251, 223, 208, 40, 225, 225, 97, 242, 238, 156, 126,
0, 104, 201, 59, 241, 152, 137, 162, 198, 192, 109, 16, 32, 160, 229, 153, 61, 18, 185, 31, 38, 108, 82, 129, 251,
0, 130, 115, 124, 213, 197, 138, 30, 98, 251, 51, 196, 53, 79, 45, 67, 146, 200, 126, 139, 80, 7, 199, 25, 176, 167,
188, 241, 16, 113, 186, 0, 211, 92, 105, 152, 222, 85, 147, 149, 173, 10, 230, 247, 55, 49, 121, 50, 25, 232, 82,
48, 41, 160, 0, 13, 108, 130, 157, 93, 59, 65, 85, 245, 192, 97, 45, 43, 210, 165, 87, 207, 238, 237, 46, 159, 197,
86, 160, 162, 110, 210, 106, 65, 133, 200, 187, 209, 148, 16, 83, 15, 170, 216, 28, 175, 119, 248, 161, 192, 207,
194, 253, 253, 61, 205, 106, 109, 191, 170, 147, 142, 115, 143, 62, 200, 238, 137, 157, 43, 158, 205, 118, 163, 220,
10, 31, 198, 43, 129, 88, 26, 37, 56, 82, 220, 190, 166, 77, 142, 145, 27, 8, 113, 1, 144, 238, 35, 155, 79, 15, 34,
244, 4, 252, 2, 51, 112, 21, 102, 245, 197, 160, 42, 146, 213, 182, 222, 118, 94, 199, 122, 232, 161, 177, 115, 138,
241, 113, 37, 169, 204, 68, 229, 76, 20, 15, 79, 75, 172, 144, 206, 171, 200, 26, 116, 62, 177, 129, 143, 11, 162,
255, 75, 211, 232, 236, 31, 182, 60, 108, 92, 27, 145, 126, 10, 103, 142, 198, 143, 43, 194, 121, 179, 47, 33, 79,
51, 183, 231, 145, 137, 69, 152, 139, 138, 124, 227, 17, 25, 109, 63, 63, 124, 154, 199, 210, 26, 46, 51, 140, 182,
53, 44, 181, 211, 63, 38, 250, 145, 41, 99, 109, 90, 202, 116, 71, 33, 93, 216, 4, 83, 156, 35, 140, 76, 254, 21,
222, 27, 96, 159, 68, 145, 12, 118, 177, 138, 107, 246, 192, 120, 218, 18, 87, 143, 8, 133, 33, 171, 147, 71, 58,
205, 63, 35, 15, 93, 3, 171, 50, 223, 29, 0, 24, 246, 213, 243, 247, 186, 103, 133, 219, 69, 231, 210, 135, 151,
101, 84, 153, 44, 56, 202, 234, 11, 25, 253, 23, 137, 98, 229, 91, 135, 129, 41, 33, 120, 97, 142, 102, 36, 115, 3,
17, 6, 174, 13, 75, 116, 179, 194, 44, 203, 150, 238, 176, 13, 39, 209, 120, 23, 1, 160, 200, 208, 75, 212, 213,
144, 46, 245, 193, 150, 79, 34, 146, 175, 141, 229, 161, 81, 91, 21, 69, 100, 40, 71, 170, 173, 78, 137, 225, 206,
64, 56, 112, 39, 165, 97, 61, 9, 93, 228, 234, 59, 161, 244, 162, 47, 148, 192, 155, 128, 87, 227, 14, 22, 102, 145,
243, 23, 5, 90, 134, 123, 60, 119, 36, 175, 15, 237, 186, 227, 103, 51, 36, 52, 198, 52, 109, 154, 166, 251, 216,
232, 43, 228, 126, 184, 17, 20, 92, 113, 107, 172, 97, 81, 63, 246, 169, 200, 15, 58, 191, 130, 103, 224, 108, 147,
20, 242, 141, 32, 244, 254, 47, 38, 210, 194, 180, 141, 245, 64, 73, 89, 63, 176, 110, 156, 221, 116, 195, 154, 236,
220, 236, 250, 34, 183, 253, 15, 72, 26, 88, 6, 11, 121, 196, 203, 155, 203, 126, 67, 12, 140, 229, 78, 99, 253,
184, 175, 116, 90, 123, 151, 134, 114, 218, 120, 59, 224, 154, 89, 12, 78, 53, 80, 140, 213, 151, 91, 190, 155, 90,
101, 236, 78, 106, 29, 16, 103, 87, 87, 59, 223, 177, 104, 149, 136, 92, 73, 129, 159, 202, 129, 108, 253, 59, 28,
9, 61, 108, 89, 202, 91, 150, 152, 118, 169, 153, 217, 174, 184, 211, 227, 234, 42, 175, 31, 187, 50, 189, 115, 247,
207, 175, 211, 227, 87, 39, 114, 196, 81, 159, 96, 75, 164, 29, 164, 50, 237, 209, 178, 110, 149, 42, 20, 84, 208,
208, 43, 127, 47, 200, 56, 88, 3, 42, 119, 61, 215, 82, 115, 41, 55, 251, 105, 122, 152, 53, 21, 31, 144, 5, 194,
40, 83, 70, 251, 140, 64, 231, 247, 139, 25, 60, 220, 253, 116, 182, 39, 222, 204, 16, 183, 70, 75, 30, 231, 124,
131, 71, 158, 247, 84, 176, 46, 251, 48, 171, 232, 110, 119, 25, 124, 90, 143, 53, 144, 205, 18, 34, 126, 181, 155,
9, 132, 162, 213, 167, 231, 72, 11, 166, 134, 71, 215, 203, 112, 108, 99, 31, 250, 105, 152, 155, 125, 94, 86, 167,
18, 207, 32, 58, 159, 172, 90, 115, 172, 66, 207, 195, 6, 247, 115, 185, 238, 103, 121, 17, 90, 127, 157, 199, 185,
49, 172, 76, 255, 57, 24, 199, 207, 65, 251, 148, 103, 220, 2, 233, 236, 18, 195, 78, 22, 151, 7, 89, 49, 64, 70,
200, 86, 191, 72, 246, 0, 90, 206, 28, 169, 40, 53, 193, 115, 237, 194, 104, 172, 75, 213, 95, 66, 92, 90, 34, 117,
50, 173, 6, 24, 241, 124, 195, 73, 141, 116, 198, 183, 57, 205, 106, 83, 221, 109, 97, 162, 52, 77, 131, 43, 17, 51,
77, 189, 137, 93, 4, 143, 11, 104, 109, 205, 45, 227, 108, 168, 91, 157, 115, 133, 28, 158, 100, 226, 135, 31, 124,
68, 227, 232, 87, 180, 250, 121, 130, 10, 29, 166, 24, 66, 235, 236, 135, 53, 85, 177, 28, 167, 165, 159, 226, 177,
173, 191, 44, 218, 11, 4, 139, 250, 121, 210, 125, 48, 130, 144, 28, 68, 250, 11, 151, 68, 20, 132, 58, 74, 152, 89,
192, 17, 156, 201, 80, 32, 108, 3, 45, 155, 131, 156, 43, 12, 102, 191, 2, 54, 231, 48, 99, 131, 195, 54, 198, 117,
214, 157, 207, 200, 48, 204, 114, 27, 14, 158, 167, 93, 220, 27, 105, 89, 63, 228, 118, 241, 161, 207, 142, 190,
237, 155, 16, 26, 13, 216, 57, 15, 102, 206, 85, 213, 65, 146, 223, 89, 72, 84, 192, 26, 141, 235, 201, 116, 1, 174,
174, 246, 124, 192, 217, 209, 75, 66, 70, 224, 20, 254, 47, 67, 73, 24, 88, 188, 81, 2, 169, 40, 168, 87, 39, 106,
96, 125, 83, 189, 124, 7, 194, 76, 15, 180, 63, 222, 237, 214, 42, 213, 29, 152, 178, 224, 105, 193, 4, 103, 117,
148, 71, 67, 22, 80, 194, 33, 218, 50, 64, 208, 33, 168, 216, 10, 117, 11, 90, 174, 146, 66, 26, 69, 202, 34, 167,
94, 23, 218, 152, 71, 48, 237, 229, 138, 2, 39, 22, 136, 19, 33, 196, 174, 43, 164, 98, 39, 154, 77, 147, 83, 226,
132, 245, 6, 106, 62, 255, 99, 125, 191, 94, 69, 144, 133, 232, 44, 65, 48, 163, 56, 165, 175, 116, 173, 2, 160,
139, 56, 99, 19, 123, 35, 112, 71, 166, 59, 43, 236, 164, 242, 172, 145, 21, 15, 73, 105, 163, 84, 135, 158, 13, 11,
246, 21, 31, 59, 86, 247, 3, 8, 181, 11, 98, 160, 69, 34, 45, 221, 73, 114, 202, 0, 75, 40, 235, 67, 59, 93, 34,
210, 192, 34, 156, 115, 179, 223, 201, 5, 168, 29, 45, 81, 153, 35, 98, 27, 120, 14, 3, 106, 132, 44, 115, 41, 222,
71, 77, 157, 234, 66, 175, 137, 123, 86, 2, 188, 66, 208, 184, 111, 80, 88, 96, 95, 167, 14, 177, 15, 11, 123, 5,
249, 95, 94, 25, 22, 166, 159, 228, 254, 224, 194, 31, 65, 214, 239, 246, 59, 154, 141, 45, 255, 103, 159, 170, 194,
22, 159, 118, 148, 119, 66, 108, 43, 56, 186, 144, 30, 69, 123, 43, 21, 216, 235, 186, 38, 42, 105, 49, 171, 46, 95,
38, 194, 48, 55, 9, 184, 153, 117, 146, 16, 77, 44, 198, 180, 120, 190, 244, 34, 75, 218, 207, 9, 169, 187, 149,
139, 234, 210, 169, 217, 32, 104, 128, 79, 210, 159, 141, 218, 254, 165, 174, 198, 23, 198, 171, 40, 140, 34, 206,
133, 134, 80, 100, 92, 162, 42, 233, 210, 146, 205, 229, 211, 127, 5, 68, 196, 89, 85, 90, 212, 148, 215, 235, 105,
187, 98, 171, 39, 141, 123, 33, 245, 146, 43, 233, 245, 127, 88, 69, 187, 34, 53, 8, 56, 173, 231, 155, 28, 121,
110, 8, 146, 96, 100, 94, 149, 236, 58, 118, 194, 124, 12, 89, 170, 176, 62, 218, 98, 151, 200, 67, 190, 213, 241,
48, 38, 176, 25, 216, 253, 42, 211, 92, 124, 144, 90, 43, 170, 212, 184, 253, 151, 140, 11, 30, 151, 59, 150, 137,
167, 212, 248, 180, 74, 238, 13, 254, 10, 112, 20, 247, 129, 48, 58, 159, 159, 233, 13, 20, 150, 66, 99, 47, 148,
210, 193, 108, 139, 153, 138, 106, 135, 246, 99, 117, 30, 60, 113, 145, 219, 84, 187, 199, 68, 69, 142, 252, 178,
233, 181, 76, 215, 65, 91, 84, 209, 132, 100, 43, 95, 198, 10, 179, 130, 176, 5, 185, 186, 100, 211, 76, 248, 46,
91, 165, 87, 197, 14, 133, 150, 150, 202, 57, 117, 198, 136, 42, 146, 94, 198, 171, 173, 160, 48, 5, 116, 22, 188,
192, 224, 222, 253, 157, 47, 31, 159, 168, 58, 164, 209, 93, 207, 132, 100, 25, 22, 11, 130, 107, 104, 132, 54, 114,
105, 9, 121, 226, 147, 33, 237, 183, 211, 43, 30, 144, 70, 1, 18, 54, 247, 255, 41, 104, 118, 137, 222, 124, 213,
231, 201, 111, 102, 185, 50, 192, 186, 164, 173, 205, 100, 61, 40, 113, 175, 44, 127, 218, 150, 162, 173, 97, 17,
39, 108, 94, 44, 84, 49, 5, 111, 5, 162, 236, 221, 234, 42, 156, 158, 202, 229, 190, 59, 186, 134, 130, 216, 31, 45,
57, 144, 75, 109, 95, 210, 187, 135, 45, 48, 2, 181, 147, 181, 243, 202, 212, 221, 162, 230, 45, 130, 165, 163, 44,
163, 25, 67, 47, 243, 198, 201, 182, 60, 81, 155, 115, 208, 214, 39, 121, 194, 199, 24, 226, 189, 36, 89, 62, 86,
123, 163, 86, 155, 73, 69, 200, 145, 66, 135, 94, 153, 28, 83, 23, 70, 40, 231, 249, 142, 42, 179, 133, 67, 156,
241, 190, 82, 246, 251, 131, 232, 150, 151, 84, 177, 134, 14, 165, 39, 51, 231, 29, 216, 191, 147, 181, 151, 153,
163, 73, 57, 182, 32, 141, 11, 64, 239, 250, 52, 74, 80, 71, 1, 232, 171, 102, 36, 151, 88, 153, 25, 232, 164, 222,
124, 66, 67, 236, 248, 187, 157, 174, 93, 20, 203, 98, 10, 118, 218, 228, 62, 115, 138, 241, 210, 45, 52, 184, 247,
176, 20, 101, 131, 48, 11, 35, 117, 142, 38, 80, 52, 5, 253, 157, 17, 11, 96, 29, 164, 228, 100, 244, 16, 61, 20,
159, 21, 196, 11, 226, 55, 84, 47, 77, 189, 56, 58, 66, 46, 201, 47, 29, 193, 18, 33, 107, 23, 146, 102, 136, 193,
87, 99, 243, 117, 255, 130, 4, 186, 195, 240, 248, 171, 138, 125, 118, 228, 254, 230, 208, 179, 3, 16, 166, 196,
150, 28, 146, 160, 37, 49, 202, 197, 180, 219, 243, 113, 32, 17, 16, 73, 191, 62, 23, 89, 194, 114, 82, 225, 60, 96,
149, 5, 29, 93, 4, 84, 108, 158, 198, 20, 36, 54, 210, 31, 213, 29, 245, 218, 242, 197, 158, 219, 138, 129, 81, 184,
175, 106, 246, 158, 101, 91, 146, 252, 94, 17, 51, 224, 65, 185, 51, 54, 103, 209, 166, 46, 200, 36, 165, 21, 56,
47, 118, 90, 235, 18, 116, 127, 159, 28, 48, 180, 120, 252, 77, 229, 12, 44, 179, 131, 28, 190, 53, 195, 18, 23,
237, 206, 147, 132, 34, 108, 118, 111, 251, 79, 42, 94, 237, 46, 75, 107, 170, 132, 0, 210, 98, 163, 205, 220, 227,
175, 223, 121, 229, 185, 166, 219, 80, 43, 140, 242, 7, 151, 172, 40, 162, 234, 199, 94, 96, 165, 97, 234, 31, 170,
32, 190, 222, 154, 1, 70, 53, 88, 68, 25, 36, 213, 82, 189, 184, 11, 163, 191, 225, 178, 125, 78, 91, 39, 65, 129,
76, 56, 106, 220, 113, 162, 93, 109, 155, 12, 100, 37, 55, 116, 144, 77, 48, 50, 63, 14, 166, 151, 62, 167, 10, 68,
139, 218, 143, 107, 1, 128, 143, 19, 147, 193, 148, 174, 141, 61, 156, 153, 129, 210, 155, 19, 21, 55, 149, 226, 3,
243, 131, 107, 231, 98, 186, 46, 25, 110, 25, 30, 51, 100, 239, 210, 70, 148, 42, 88, 104, 114, 51, 190, 239, 94,
188, 235, 106, 191, 28, 219, 104, 219, 167, 50, 196, 21, 139, 87, 190, 59, 140, 85, 135, 84, 140, 119, 97, 171, 18,
86, 108, 203, 107, 60, 53, 85, 176, 122, 136, 157, 84, 11, 193, 190, 88, 4, 125, 92, 176, 159, 60, 123, 11, 221,
152, 66, 164, 66, 44, 130, 37, 65, 145, 242, 230, 67, 160, 110, 114, 83, 198, 220, 215, 191, 194, 2, 74, 243, 231,
28, 167, 118, 195, 36, 197, 233, 246, 155, 161, 6, 159, 154, 118, 151, 64, 61, 110, 40, 181, 67, 201, 184, 88, 45,
23, 183, 63, 126, 242, 219, 63, 210, 34, 111, 79, 239, 73, 23, 183, 78, 78, 20, 85, 20, 63, 188, 214, 19, 151, 154,
36, 10, 58, 205, 142, 119, 251, 110, 132, 55, 21, 116, 50, 238, 1, 163, 41, 66, 187, 252, 84, 16, 219, 73, 242, 98,
23, 107, 8, 37, 198, 100, 240, 59, 231, 61, 18, 8, 238, 8, 231, 133, 185, 237, 115, 142, 46, 165, 55, 14, 42, 55,
139, 60, 173, 196, 48, 17, 167, 120, 11, 126, 122, 119, 132, 142, 36, 42, 126, 252, 150, 22, 112, 82, 228, 83, 80,
226, 33, 254, 87, 123, 5, 236, 107, 237, 21, 39, 152, 70, 224, 69, 226, 205, 212, 50, 61, 181, 192, 62, 59, 16, 91,
0, 23, 96, 210, 73, 166, 71, 221, 209, 165, 59, 45, 245, 245, 146, 92, 34, 44, 13, 34, 86, 185, 232, 255, 3, 166,
73, 12, 162, 104, 83, 62, 210, 3, 76, 66, 225, 239, 82, 7, 122, 216, 249, 24, 16, 216, 12, 41, 169, 202, 188, 35,
29, 107, 208, 4, 21, 13, 155, 100, 172, 210, 241, 63, 93, 242, 189, 180, 63, 250, 213, 244, 100, 61, 206, 102, 91,
166, 72, 151, 51, 133, 180, 76, 137, 168, 59, 68, 95, 190, 214, 114, 152, 112, 99, 16, 55, 55, 190, 206, 216, 48,
137, 139, 56, 187, 31, 97, 158, 184, 7, 162, 179, 105, 156, 175, 253, 120, 47, 103, 202, 41, 222, 115, 211, 113, 68,
33, 92, 4, 224, 82, 148, 162, 103, 181, 226, 174, 172, 127, 243, 58, 253, 221, 22, 71, 212, 212, 231, 158, 190, 165,
180, 84, 133, 113, 238, 77, 14, 105, 3, 249, 139, 107, 71, 108, 155, 99, 133, 255, 2, 36, 103, 19, 162, 69, 112,
142, 36, 18, 67, 95, 59, 65, 110, 121, 53, 33, 180, 200, 15, 97, 239, 1, 28, 92, 181, 179, 132, 253, 97, 12, 155,
39, 9, 68, 222, 161, 86, 76, 158, 93, 126, 220, 101, 8, 24, 108, 186, 186, 28, 143, 87, 239, 79, 22, 194, 205, 252,
193, 154, 217, 170, 23, 226, 54, 85, 70, 57, 245, 135, 28, 243, 57, 192, 62, 213, 146, 238, 87, 18, 163, 194, 182,
100, 11, 86, 99, 31, 76, 19, 21, 49, 245, 75, 43, 14, 209, 181, 102, 74, 162, 125, 175, 206, 26, 29, 9, 28, 179, 22,
108, 136, 71, 83, 166, 140, 60, 171, 198, 19, 13, 239, 58, 200, 180, 248, 79, 112, 46, 188, 161, 223, 207, 71, 92,
134, 214, 40, 181, 214, 175, 170, 130, 202, 150, 18, 7, 249, 142, 254, 40, 25, 67, 135, 14, 166, 9, 165, 161, 113,
115, 97, 180, 57, 255, 25, 147, 181, 4, 162, 28, 168, 213, 124, 150, 62, 185, 155, 15, 17, 247, 134, 67, 219, 107,
64, 39, 185, 134, 65, 242, 54, 198, 78, 209, 165, 180, 211, 132, 133, 79, 255, 4, 40, 130, 18, 155, 86, 184, 72,
131, 98, 175, 122, 237, 148, 155, 88, 245, 245, 150, 148, 241, 148, 65, 110, 103, 129, 218, 236, 220, 202, 145, 7,
219, 200, 92, 23, 164, 160, 112, 95, 193, 140, 62, 46, 208, 106, 246, 250, 208, 211, 63, 165, 163, 206, 232, 116,
24, 77, 96, 36, 102, 79, 241, 182, 121, 140, 250, 73, 219, 152, 164, 162, 160, 23, 143, 100, 30, 185, 199, 162, 205,
80, 15, 34, 31, 91, 51, 163, 132, 4, 116, 107, 185, 71, 96, 53, 104, 23, 16, 21, 199, 203, 4, 188, 56, 30, 65, 204,
51, 192, 150, 18, 72, 203, 34, 102, 100, 19, 206, 238, 119, 74, 120, 1, 68, 1, 174, 78, 132, 171, 166, 139, 159,
248, 55, 148, 57, 45, 139, 103, 125, 157, 183, 162, 7, 126, 86, 227, 188, 109, 186, 20, 254, 254, 16, 79, 212, 183,
5, 228, 86, 243, 49, 229, 206, 100, 147, 166, 207, 246, 81, 49, 66, 126, 147, 141, 49, 73, 216, 64, 113, 53, 112,
233, 214, 96, 138, 82, 131, 141, 198, 86, 71, 74, 106, 239, 99, 216, 118, 107, 148, 224, 197, 78, 0, 74, 98, 44,
109, 250, 209, 81, 152, 188, 232, 104, 234, 108, 75, 87, 49, 91, 220, 232, 166, 174, 25, 25, 182, 115, 179, 134,
165, 251, 239, 35, 115, 209, 218, 23, 132, 137, 5, 213, 125, 34, 123, 109, 82, 201, 208, 249, 205, 35, 35, 77, 7, 8,
250, 202, 86, 99, 104, 0, 215, 139, 70, 128, 171, 227, 189, 182, 58, 43, 244, 173, 156, 87, 108, 223, 255, 3, 127,
142, 194, 133, 180, 230, 23, 106, 52, 31, 148, 183, 207, 1, 194, 150, 236, 216, 196, 75, 64, 78, 20, 181, 114, 94,
235, 180, 159, 54, 49, 174, 136, 228, 38, 78, 92, 110, 165, 57, 225, 214, 219, 70, 101, 100, 6, 49, 9, 105, 120,
201, 46, 159, 224, 81, 143, 24, 184, 255, 194, 131, 178, 252, 152, 135, 67, 12, 88, 213, 108, 74, 23, 191, 125, 222,
63, 238, 195, 32, 69, 60, 34, 233, 42, 82, 250, 7, 111, 157, 228, 23, 90, 134, 182, 178, 36, 168, 127, 175, 185,
194, 229, 147, 56, 160, 24, 143, 221, 7, 1, 31, 108, 249, 205, 146, 206, 32, 160, 252, 32, 246, 117, 60, 53, 118,
16, 35, 249, 130, 51, 164, 248, 177, 253, 168, 208, 145, 220, 132, 130, 142, 98, 47, 51, 122, 247, 35, 236, 202,
251, 157, 76, 31, 219, 42, 235, 4, 128, 217, 16, 213, 49, 11, 199, 88, 59, 221, 60, 230, 123, 115, 9, 244, 198, 93,
115, 157, 220, 149, 180, 132, 83, 168, 247, 104, 24, 80, 27, 149, 157, 245, 122, 40, 114, 154, 175, 192, 67, 10, 34,
47, 83, 95, 58, 172, 53, 12, 195, 254, 156, 38, 1, 107, 12, 213, 41, 25, 140, 212, 95, 152, 151, 118, 52, 113, 39,
237, 91, 2, 205, 154, 92, 206, 50, 212, 57, 97, 214, 64, 98, 232, 224, 239, 117, 244, 214, 25, 180, 40, 110, 227,
112, 140, 185, 150, 31, 227, 241, 104, 120, 69, 198, 91, 73, 30, 83, 130, 135, 56, 200, 99, 164, 100, 76, 196, 128,
48, 19, 63, 30, 252, 87, 225, 27, 222, 24, 17, 160, 100, 66, 73, 50, 244, 85, 53, 202, 180, 137, 75, 114, 147, 135,
122, 161, 224, 65, 187, 177, 105, 92, 246, 237, 103, 216, 209, 138, 123, 170, 91, 82, 247, 70, 103, 182, 205, 123,
236, 35, 17, 4, 173, 244, 94, 223, 17, 89, 127, 53, 40, 114, 94, 129, 22, 198, 14, 164, 250, 105, 219, 206, 202,
212, 28, 35, 80, 179, 91, 187, 4, 206, 222, 136, 48, 145, 202, 225, 89, 220, 98, 107, 29, 190, 30, 35, 108, 53, 231,
197, 251, 124, 199, 127, 146, 205, 2, 195, 80, 193, 25, 55, 49, 239, 161, 66, 232, 14, 121, 144, 158, 44, 56, 168,
68, 102, 221, 69, 76, 123, 14, 71, 9, 10, 0, 57, 218, 244, 104, 36, 4, 142, 39, 15, 102, 113, 161, 94, 94, 228, 235,
84, 248, 175, 66, 98, 206, 59, 44, 77, 192, 109, 73, 95, 129, 139, 22, 107, 240, 133, 152, 138, 69, 121, 222, 140,
70, 223, 209, 5, 130, 85, 7, 215, 1, 30, 129, 6, 5, 181, 138, 169, 160, 16, 63, 172, 26, 9, 43, 178, 173, 229, 201,
100, 65, 83, 172, 97, 26, 107, 116, 131, 133, 75, 224, 219, 156, 76, 121, 94, 110, 176, 163, 102, 2, 14, 137, 129,
10, 104, 8, 215, 216, 137, 89, 176, 75, 115, 85, 162, 4, 122, 125, 40, 61, 27, 191, 46, 248, 127, 73, 1, 245, 14,
246, 43, 237, 153, 220, 108, 112, 27, 43, 253, 240, 251, 247, 79, 58, 226, 189, 65, 244, 200, 141, 237, 169, 252,
150, 68, 222, 94, 75, 229, 113, 125, 233, 196, 194, 105, 52, 139, 7, 49, 111, 42, 187, 215, 124, 5, 13, 236, 141,
23, 166, 33, 150, 101, 134, 39, 92, 32, 14, 225, 1, 226, 119, 243, 201, 23, 214, 175, 70, 230, 37, 40, 114, 113,
115, 129, 43, 84, 184, 252, 39, 202, 175, 83, 109, 18, 116, 46, 69, 117, 249, 158, 10, 134, 75, 76, 137, 168, 176,
17, 209, 178, 133, 111, 226, 200, 42, 164, 100, 11, 5, 18, 118, 244, 5, 121, 68, 217, 76, 103, 54, 94, 183, 99, 255,
239, 48, 23, 181, 46, 103, 15, 254, 194, 136, 72, 22, 125, 171, 205, 45, 29, 76, 227, 128, 57, 143, 157, 188, 181,
205, 134, 134, 125, 75, 113, 19, 249, 61, 224, 40, 206, 36, 237, 146, 241, 60, 156, 78, 30, 115, 167, 113, 173, 127,
146, 90, 204, 203, 162, 72, 16, 8, 238, 62, 244, 98, 66, 37, 89, 87, 53, 239, 94, 215, 145, 185, 203, 49, 174, 138,
0, 213, 250, 214, 223, 63, 58, 60, 212, 220, 45, 66, 175, 17, 94, 19, 158, 219, 177, 182, 252, 222, 12, 38, 186,
247, 50, 138, 188, 96, 31, 241, 126, 64, 17, 235, 58, 159, 148, 49, 77, 145, 128, 148, 115, 240, 125, 4, 114, 182,
34, 127, 186, 186, 153, 249, 166, 42, 73, 227, 11, 95, 126, 167, 105, 93, 231, 114, 52, 102, 119, 8, 12, 206, 46,
244, 8, 188, 6, 111, 193, 122, 1, 72, 183, 12, 90, 170, 26, 130, 104, 220, 155, 40, 103, 157, 79, 34, 133, 235, 73,
22, 147, 98, 9, 76, 226, 33, 147, 178, 93, 224, 104, 156, 40, 49, 236, 62, 70, 234, 215, 202, 188, 64, 92, 202, 253,
164, 2, 242, 147, 134, 236, 62, 31, 9, 193, 235, 250, 215, 169, 174, 21, 202, 62, 11, 200, 74, 106, 152, 222, 160,
133, 115, 15, 37, 188, 97, 152, 201, 98, 10, 91, 138, 189, 255, 171, 193, 6, 212, 99, 63, 84, 182, 12, 108, 171, 42,
53, 154, 30, 140, 121, 136, 199, 112, 23, 184, 118, 232, 32, 231, 102, 48, 69, 190, 41, 59, 63, 68, 94, 63, 252,
137, 4, 35, 43, 33, 207, 244, 227, 191, 103, 249, 42, 0, 0, 186, 41, 199, 243, 227, 113, 141, 235, 243, 127, 171,
150, 213, 128, 100, 122, 223, 178, 163, 231, 77, 64, 64, 157, 72, 74, 211, 186, 162, 45, 241, 12, 188, 97, 36, 123,
195, 44, 106, 67, 131, 79, 105, 222, 206, 106, 103, 19, 66, 41, 139, 165, 189, 90, 160, 162, 160, 234, 125, 228,
147, 4, 153, 91, 60, 68, 152, 12, 4, 168, 196, 154, 37, 195, 145, 235, 190, 147, 183, 110, 34, 245, 98, 243, 235,
101, 33, 242, 96, 110, 52, 72, 218, 212, 43, 181, 2, 126, 64, 121, 161, 246, 84, 118, 163, 178, 221, 163, 63, 222,
77, 23, 220, 101, 218, 22, 244, 6, 2, 34, 108, 106, 71, 221, 9, 148, 90, 47, 23, 155, 41, 39, 89, 204, 123, 218, 23,
68, 56, 243, 227, 243, 217, 184, 35, 174, 158, 91, 249, 222, 88, 75, 89, 167, 58, 93, 209, 161, 10, 38, 133, 237,
188, 98, 29, 34, 1, 239, 124, 93, 8, 199, 152, 65, 146, 57, 19, 213, 161, 141, 4, 199, 248, 85, 1, 95, 23, 89, 226,
182, 133, 58, 48, 75, 149, 209, 96, 20, 175, 123, 163, 190, 133, 75, 99, 16, 44, 194, 87, 109, 60, 8, 82, 250, 36,
50, 42, 96, 156, 11, 109, 72, 42, 163, 190, 112, 200, 114, 89, 158, 219, 174, 209, 138, 64, 86, 177, 30, 195, 162,
200, 41, 177, 20, 205, 76, 91, 152, 12, 138, 216, 149, 216, 29, 173, 235, 200, 232, 146, 132, 133, 144, 12, 17, 76,
2, 251, 51, 203, 227, 147, 186, 29, 14, 94, 15, 34, 78, 93, 231, 149, 81, 35, 49, 180, 25, 128, 42, 9, 204, 42, 129,
116, 151, 222, 110, 161, 128, 10, 161, 70, 192, 17, 13, 181, 251, 69, 230, 75, 211, 171, 239, 205, 209, 216, 219,
97, 117, 215, 9, 140, 149, 69, 47, 197, 251, 56, 48, 212, 137, 161, 82, 14, 248, 25, 231, 14, 39, 20, 21, 177, 211,
181, 37, 164, 157, 71, 66, 246, 213, 114, 219, 255, 133, 135, 246, 215, 177, 129, 67, 57, 195, 200, 83, 39, 138,
103, 78, 95, 38, 110, 75, 21, 143, 9, 69, 182, 237, 210, 72, 212, 89, 88, 224, 101, 67, 129, 155, 37, 252, 197, 117,
149, 156, 198, 242, 234, 154, 95, 119, 78, 219, 221, 105, 142, 111, 238, 159, 29, 117, 128, 140, 214, 30, 60, 30,
213, 110, 8, 95, 249, 23, 167, 253, 247, 127, 131, 15, 236, 243, 222, 11, 244, 21, 101, 137, 149, 214, 102, 218,
127, 114, 81, 54, 192, 61, 2, 6, 213, 67, 96, 64, 168, 243, 238, 16, 93, 11, 237, 140, 125, 228, 94, 195, 230, 20,
148, 30, 231, 173, 171, 164, 86, 108, 62, 168, 173, 120, 44, 127, 160, 229, 76, 188, 2, 39, 125, 245, 158, 254, 211,
121, 126, 241, 253, 16, 110, 97, 48, 164, 125, 215, 124, 116, 55, 5, 95, 238, 113, 17, 65, 166, 52, 58, 229, 39, 57,
100, 249, 151, 212, 174, 22, 57, 96, 214, 10, 127, 47, 81, 177, 114, 173, 170, 206, 66, 217, 171, 92, 15, 114, 53,
221, 186, 145, 11, 78, 175, 233, 84, 240, 175, 117, 155, 154, 246, 226, 105, 14, 6, 178, 2, 52, 205, 21, 79, 119,
185, 154, 214, 215, 249, 181, 38, 46, 159, 220, 83, 66, 153, 113, 214, 5, 185, 67, 53, 223, 153, 164, 193, 32, 38,
218, 69, 173, 155, 187, 205, 22, 249, 209, 214, 139, 189, 178, 159, 92, 123, 62, 182, 223, 248, 10, 134, 244, 105,
106, 90, 108, 76, 179, 85, 224, 75, 49, 214, 158, 203, 248, 67, 8, 38, 233, 126, 100, 235, 137, 144, 67, 135, 105,
250, 213, 14, 188, 43, 125, 192, 18, 173, 225, 8, 252, 217, 16, 143, 148, 233, 58, 111, 125, 233, 247, 46, 133, 231,
252, 111, 219, 33, 128, 35, 9, 223, 224, 198, 27, 140, 186, 135, 227, 235, 245, 104, 127, 232, 125, 162, 41, 90,
133, 97, 170, 139, 122, 165, 29, 143, 247, 29, 173, 11, 176, 49, 197, 1, 194, 22, 174, 136, 226, 23, 238, 29, 1,
229, 137, 77, 167, 66, 117, 27, 42, 108, 31, 181, 85, 85, 121, 27, 82, 124, 14, 170, 123, 15, 252, 235, 67, 183, 89,
182, 41, 212, 86, 128, 103, 23, 152, 169, 195, 10, 253, 82, 176, 13, 231, 210, 35, 166, 124, 114, 244, 76, 249, 195,
182, 107, 205, 146, 30, 226, 86, 25, 93, 154, 63, 149, 197, 79, 225, 95, 96, 184, 96, 88, 181, 131, 81, 229, 38,
222, 180, 70, 106, 22, 10, 46, 255, 170, 77, 147, 159, 255, 220, 148, 5, 2, 250, 108, 118, 203, 234, 189, 49, 93,
142, 95, 121, 255, 110, 68, 94, 107, 157, 171, 129, 101, 75, 71, 188, 231, 176, 171, 12, 26, 140, 36, 173, 47, 73,
159, 143, 145, 119, 61, 219, 34, 71, 66, 251, 164, 133, 143, 58, 251, 94, 193, 15, 73, 13, 189, 135, 176, 225, 167,
112, 253, 182, 190, 74, 209, 42, 136, 121, 48, 232, 47, 30, 101, 44, 228, 216, 78, 68, 188, 39, 246, 221, 250, 173,
145, 181, 249, 3, 112, 170, 179, 136, 144, 106, 137, 21, 180, 77, 86, 43, 187, 234, 33, 190, 27, 238, 173, 142, 175,
77, 73, 225, 212, 155, 207, 68, 179, 246, 6, 116, 61, 93, 171, 121, 234, 162, 162, 239, 102, 219, 57, 135, 230, 84,
218, 93, 74, 135, 166, 202, 55, 166, 119, 5, 110, 83, 24, 242, 16, 244, 153, 49, 52, 200, 223, 103, 10, 195, 152,
141, 200, 156, 184, 202, 228, 175, 136, 29, 45, 187, 107, 84, 196, 217, 222, 242, 229, 47, 232, 209, 90, 128, 220,
202, 6, 71, 144, 55, 121, 32, 80, 17, 43, 5, 244, 14, 2, 40, 10, 113, 249, 138, 15, 195, 209, 125, 61, 179, 193, 70,
47, 41, 16, 96, 5, 184, 17, 84, 117, 54, 78, 34, 8, 190, 83, 247, 193, 188, 180, 185, 103, 184, 19, 91, 241, 196,
125, 106, 94, 43, 160, 213, 164, 121, 71, 215, 189, 222, 58, 254, 20, 145, 52, 66, 156, 10, 48, 15, 113, 199, 21,
101, 246, 76, 58, 67, 244, 70, 175, 7, 174, 13, 72, 185, 182, 53, 125, 106, 146, 17, 4, 225, 10, 197, 14, 30, 167,
84, 103, 136, 56, 67, 60, 130, 255, 23, 157, 43, 116, 27, 239, 145, 17, 243, 92, 193, 154, 9, 134, 206, 219, 111,
84, 113, 17, 175, 211, 77, 98, 191, 248, 15, 90, 99, 188, 105, 99, 188, 160, 60, 63, 199, 155, 187, 3, 23, 103, 121,
165, 221, 130, 123, 179, 200, 251, 251, 53, 241, 136, 236, 34, 197, 215, 16, 39, 229, 115, 212, 75, 113, 99, 243,
87, 14, 163, 226, 11, 231, 235, 176, 103, 120, 18, 142, 234, 2, 13, 237, 159, 71, 114, 188, 5, 9, 197, 108, 61, 230,
101, 66, 247, 178, 169, 67, 169, 109, 215, 4, 36, 243, 167, 234, 141, 168, 82, 109, 214, 200, 139, 60, 227, 110,
108, 13, 228, 161, 202, 174, 110, 10, 25, 182, 46, 205, 121, 80, 38, 157, 146, 119, 192, 184, 84, 48, 66, 215, 26,
181, 72, 124, 253, 231, 106, 226, 221, 224, 123, 136, 135, 136, 203, 229, 78, 68, 28, 3, 160, 174, 178, 30, 213, 97,
11, 248, 46, 87, 113, 211, 184, 178, 246, 237, 39, 218, 148, 39, 213, 74, 101, 90, 32, 44, 248, 92, 114, 71, 136,
253, 16, 130, 15, 69, 36, 168, 73, 155, 232, 43, 53, 80, 4, 149, 74, 16, 165, 251, 141, 95, 110, 85, 155, 141, 55,
4, 82, 237, 126, 245, 115, 133, 110, 37, 164, 129, 44, 32, 66, 34, 99, 142, 237, 105, 162, 243, 180, 191, 175, 169,
187, 127, 128, 43, 219, 222, 55, 18, 205, 184, 162, 47, 52, 162, 3, 196, 149, 23, 147, 248, 117, 95, 96, 58, 174,
245, 77, 79, 11, 225, 166, 247, 195, 111, 26, 247, 37, 12, 95, 68, 83, 176, 108, 141, 151, 94, 81, 247, 168, 45,
243, 83, 136, 75, 231, 188, 6, 175, 245, 79, 130, 69, 233, 82, 142, 120, 41, 248, 204, 180, 140, 229, 137, 216, 84,
106, 51, 52, 142, 79, 13, 234, 65, 112, 237, 205, 87, 201, 26, 195, 36, 85, 149, 118, 205, 255, 195, 243, 142, 229,
253, 172, 254, 195, 164, 199, 14, 166, 124, 169, 145, 102, 95, 190, 70, 33, 133, 173, 181, 110, 11, 50, 72, 253,
145, 138, 121, 211, 151, 247, 102, 79, 94, 169, 119, 179, 48, 19, 102, 118, 66, 165, 242, 243, 140, 33, 113, 151,
192, 73, 246, 45, 74, 203, 114, 236, 244, 199, 218, 193, 123, 154, 197, 148, 125, 232, 140, 191, 183, 47, 205, 26,
84, 22, 7, 83, 238, 155, 229, 218, 3, 30, 101, 234, 49, 55, 230, 28, 1, 3, 176, 42, 52, 33, 170, 59, 178, 220, 251,
180, 162, 54, 194, 137, 181, 66, 181, 126, 124, 144, 241, 197, 127, 113, 174, 92, 100, 119, 161, 190, 82, 22, 207,
3, 132, 140, 168, 86, 44, 127, 147, 103, 185, 141, 88, 160, 225, 193, 128, 215, 221, 155, 154, 38, 195, 48, 97, 115,
76, 75, 172, 181, 226, 143, 129, 80, 239, 225, 34, 220, 69, 105, 42, 84, 135, 18, 158, 132, 95, 222, 198, 175, 15,
74, 104, 173, 235, 1, 202, 147, 117, 17, 79, 58, 222, 76, 232, 49, 75, 171, 73, 25, 157, 116, 199, 146, 41, 121,
127, 142, 248, 47, 211, 12, 16, 48, 15, 52, 90, 172, 93, 150, 175, 26, 2, 232, 215, 101, 108, 123, 36, 45, 114, 84,
113, 210, 33, 23, 92, 47, 116, 5, 100, 219, 130, 100, 191, 65, 234, 221, 238, 29, 209, 37, 53, 33, 141, 172, 241,
59, 239, 208, 119, 160, 210, 20, 92, 106, 96, 116, 233, 236, 143, 211, 239, 115, 119, 89, 172, 35, 236, 23, 202,
163, 45, 222, 133, 206, 32, 163, 43, 42, 165, 43, 197, 92, 180, 235, 239, 77, 206, 137, 230, 31, 223, 162, 200, 239,
162, 225, 147, 92, 26, 181, 154, 24, 111, 220, 19, 152, 85, 25, 112, 196, 179, 41, 44, 108, 36, 218, 37, 199, 25,
217, 26, 132, 34, 32, 4, 169, 175, 92, 161, 222, 160, 155, 3, 30, 119, 154, 249, 169, 167, 33, 147, 175, 66, 197,
210, 170, 40, 121, 200, 153, 206, 99, 103, 108, 143, 237, 18, 3, 34, 221, 6, 89, 78, 112, 2, 248, 131, 244, 42, 87,
238, 5, 11, 173, 175, 207, 38, 138, 178, 102, 63, 21, 108, 123, 179, 245, 67, 221, 60, 0, 172, 35, 162, 115, 5, 156,
62, 133, 129, 112, 204, 49, 47, 218, 221, 249, 91, 101, 43, 85, 169, 39, 253, 157, 220, 195, 7, 223, 250, 221, 49,
8, 188, 226, 229, 149, 61, 3, 65, 81, 21, 54, 238, 88, 170, 65, 103, 69, 53, 56, 234, 142, 58, 180, 251, 102, 43,
135, 81, 1, 229, 52, 48, 171, 3, 174, 47, 181, 190, 112, 87, 242, 107, 139, 140, 180, 16, 136, 141, 222, 149, 229,
209, 220, 239, 33, 147, 254, 203, 86, 173, 5, 123, 219, 72, 57, 158, 23, 18, 25, 15, 27, 136, 102, 248, 58, 199,
113, 222, 163, 33, 119, 164, 192, 57, 53, 155, 255, 33, 23, 165, 203, 34, 235, 79, 59, 171, 158, 135, 74, 41, 225,
133, 20, 161, 24, 61, 196, 235, 181, 136, 78, 112, 28, 246, 81, 194, 124, 211, 106, 225, 192, 13, 184, 188, 92, 7,
98, 50, 230, 122, 10, 250, 248, 85, 21, 44, 72, 49, 178, 21, 225, 236, 185, 223, 246, 222, 142, 21, 220, 34, 164,
88, 238, 19, 131, 2, 124, 167, 16, 39, 6, 83, 172, 184, 195, 89, 57, 125, 123, 5, 39, 213, 241, 219, 227, 15, 84,
163, 118, 20, 20, 169, 68, 75, 123, 231, 61, 81, 191, 225, 156, 186, 232, 47, 3, 49, 49, 24, 38, 4, 204, 169, 6,
203, 84, 109, 141, 88, 112, 15, 87, 50, 39, 61, 118, 182, 21, 225, 59, 121, 53, 222, 181, 220, 247, 216, 244, 192,
169, 231, 117, 117, 153, 1, 228, 77, 39, 119, 166, 160, 105, 158, 196, 53, 251, 154, 157, 179, 197, 23, 175, 121,
115, 226, 220, 47, 175, 205, 32, 115, 185, 87, 39, 40, 88, 215, 238, 93, 202, 23, 33, 20, 140, 238, 82, 97, 40, 87,
197, 174, 151, 109, 241, 211, 198, 152, 30, 151, 199, 47, 54, 61, 71, 183, 171, 128, 242, 53, 11, 65, 106, 73, 52,
14, 138, 253, 30, 134, 125, 75, 211, 248, 182, 133, 31, 23, 246, 42, 219, 117, 133, 65, 66, 151, 72, 82, 44, 185,
66, 171, 171, 190, 210, 213, 200, 235, 41, 117, 32, 134, 233, 128, 98, 28, 33, 157, 106, 81, 11, 97, 133, 237, 63,
164, 3, 159, 164, 58, 106, 15, 92, 138, 85, 103, 184, 121, 150, 166, 229, 166, 123, 67, 164, 205, 53, 81, 187, 202,
69, 162, 155, 202, 84, 188, 38, 123, 138, 22, 94, 160, 180, 248, 152, 176, 76, 76, 241, 2, 73, 2, 139, 77, 189, 87,
147, 111, 243, 30, 126, 4, 186, 50, 37, 198, 180, 119, 52, 31, 193, 65, 22, 27, 139, 84, 3, 115, 213, 101, 170, 229,
188, 167, 111, 235, 246, 58, 66, 245, 85, 159, 107, 165, 187, 234, 67, 186, 112, 157, 53, 200, 41, 100, 17, 253,
142, 239, 25, 30, 19, 217, 59, 172, 237, 43, 80, 89, 2, 199, 71, 178, 125, 69, 6, 9, 187, 37, 138, 148, 190, 67,
160, 74, 212, 227, 103, 66, 17, 163, 11, 61, 30, 18, 67, 161, 120, 211, 201, 81, 150, 88, 35, 195, 86, 98, 79, 182,
140, 112, 98, 72, 181, 53, 186, 108, 233, 172, 149, 229, 106, 97, 75, 219, 233, 208, 245, 8, 111, 242, 114, 166, 95,
200, 214, 198, 92, 92, 214, 215, 211, 203, 239, 114, 18, 246, 58, 178, 78, 165, 181, 65, 219, 97, 249, 7, 166, 24,
132, 56, 163, 50, 110, 104, 224, 230, 170, 111, 154, 229, 66, 133, 110, 99, 186, 175, 27, 186, 155, 228, 250, 164,
188, 228, 180, 252, 160, 132, 254, 18, 173, 221, 65, 83, 25, 84, 43, 10, 221, 85, 54, 29, 7, 243, 16, 242, 135, 82,
171, 113, 105, 116, 228, 118, 161, 101, 160, 236, 218, 113, 220, 213, 212, 165, 192, 218, 161, 153, 130, 69, 33, 82,
173, 18, 116, 100, 106, 53, 255, 163, 42, 198, 155, 205, 102, 118, 182, 110, 240, 248, 201, 88, 2, 15, 84, 82, 51,
172, 222, 47, 125, 152, 184, 169, 154, 204, 216, 97, 89, 57, 222, 4, 127, 53, 140, 61, 32, 247, 16, 234, 54, 147,
120, 95, 246, 172, 87, 39, 252, 23, 129, 228, 151, 177, 69, 49, 208, 130, 56, 60, 46, 184, 185, 43, 153, 36, 84,
183, 58, 238, 200, 212, 116, 0, 98, 83, 240, 216, 73, 16, 240, 203, 159, 7, 159, 224, 57, 244, 148, 152, 246, 166,
113, 214, 146, 181, 239, 180, 167, 252, 202, 43, 29, 156, 156, 43, 227, 101, 164, 253, 29, 208, 90, 68, 125, 231,
140, 245, 101, 30, 160, 254, 84, 214, 234, 108, 21, 82, 240, 97, 13, 223, 188, 13, 55, 228, 219, 32, 116, 233, 70,
209, 236, 154, 32, 143, 90, 87, 54, 26, 18, 21, 150, 102, 63, 172, 186, 120, 69, 32, 198, 185, 4, 238, 130, 140, 91,
205, 6, 34, 55, 253, 238, 0, 24, 185, 35, 243, 176, 52, 143, 169, 50, 248, 33, 117, 237, 239, 69, 94, 39, 69, 201,
197, 132, 227, 63, 227, 84, 236, 3, 248, 6, 120, 228, 10, 189, 120, 57, 218, 246, 62, 71, 110, 137, 171, 196, 63,
181, 236, 236, 13, 115, 233, 137, 243, 112, 238, 87, 47, 162, 5, 101, 182, 124, 138, 93, 197, 72, 160, 118, 173,
202, 225, 140, 192, 118, 171, 254, 222, 90, 227, 147, 56, 168, 79, 67, 17, 209, 166, 46, 102, 140, 127, 86, 65, 25,
188, 219, 200, 92, 231, 202, 66, 178, 15, 108, 56, 11, 175, 220, 214, 87, 3, 96, 38, 94, 177, 46, 111, 241, 110, 47,
216, 166, 153, 79, 23, 102, 9, 197, 192, 254, 180, 223, 155, 146, 100, 59, 115, 107, 29, 223, 6, 131, 65, 55, 107,
181, 26, 177, 231, 37, 114, 250, 20, 230, 74, 14, 45, 96, 155, 69, 255, 107, 204, 244, 140, 181, 118, 61, 145, 39,
249, 157, 6, 102, 137, 45, 214, 202, 32, 80, 47, 166, 195, 114, 82, 88, 168, 102, 244, 248, 224, 18, 180, 252, 42,
88, 64, 93, 0, 100, 176, 30, 0, 4, 86, 127, 158, 184, 244, 4, 216, 4, 68, 149, 136, 232, 66, 181, 15, 69, 23, 255,
245, 209, 104, 207, 115, 21, 52, 74, 168, 67, 77, 79, 132, 225, 255, 254, 16, 109, 6, 224, 254, 4, 202, 38, 113, 21,
2, 112, 120, 12, 66, 89, 139, 186, 97, 150, 187, 54, 7, 129, 117, 38, 98, 105, 40, 4, 202, 51, 112, 17, 28, 4, 150,
9, 83, 214, 140, 196, 78, 52, 45, 132, 99, 139, 107, 7, 252, 113, 18, 237, 136, 14, 154, 138, 39, 231, 195, 18, 56,
117, 218, 213, 36, 201, 22, 242, 117, 231, 227, 90, 242, 184, 82, 243, 150, 243, 55, 194, 57, 208, 86, 179, 166,
147, 19, 64, 138, 124, 154, 117, 103, 208, 179, 232, 120, 44, 234, 226, 197, 119, 237, 163, 224, 137, 10, 156, 22,
41, 21, 47, 63, 247, 142, 210, 184, 189, 31, 222, 157, 165, 5, 33, 46, 47, 213, 123, 73, 49, 234, 211, 126, 54, 198,
246, 225, 22, 159, 108, 155, 105, 191, 80, 146, 53, 5, 40, 16, 147, 174, 85, 116, 188, 175, 220, 83, 205, 142, 207,
101, 211, 153, 233, 164, 82, 140, 214, 158, 86, 197, 79, 40, 106, 61, 80, 242, 115, 111, 99, 183, 233, 134, 209,
137, 216, 88, 199, 36, 160, 24, 164, 159, 146, 59, 155, 225, 170, 211, 184, 130, 71, 42, 239, 154, 204, 184, 216,
64, 223, 101, 235, 203, 104, 87, 87, 116, 18, 198, 28, 30, 146, 146, 127, 125, 148, 126, 10, 172, 208, 63, 87, 182,
124, 226, 20, 155, 230, 159, 26, 73, 67, 169, 231, 210, 163, 134, 164, 197, 112, 76, 243, 140, 21, 162, 246, 80,
224, 90, 130, 185, 0, 196, 71, 134, 72, 60, 230, 32, 197, 182, 201, 189, 91, 127, 234, 130, 141, 66, 107, 94, 244,
163, 235, 67, 186, 8, 31, 15, 212, 255, 78, 113, 153, 87, 165, 120, 196, 229, 185, 239, 130, 174, 172, 159, 15, 27,
96, 247, 109, 89, 18, 223, 0, 99, 47, 54, 90, 195, 124, 187, 1, 1, 181, 24, 57, 168, 190, 104, 248, 20, 213, 157,
207, 26, 108, 122, 89, 88, 80, 223, 31, 118, 147, 71, 196, 91, 215, 214, 38, 32, 71, 249, 213, 160, 35, 211, 253,
193, 11, 197, 37, 72, 141, 104, 217, 129, 207, 180, 11, 136, 8, 74, 116, 189, 212, 49, 16, 199, 53, 49, 205, 227,
13, 32, 91, 74, 153, 24, 130, 250, 138, 88, 224, 179, 12, 0, 235, 155, 41, 217, 17, 9, 135, 80, 6, 192, 222, 234,
125, 102, 245, 72, 29, 80, 209, 65, 33, 106, 54, 144, 1, 39, 223, 144, 10, 233, 112, 210, 22, 54, 162, 15, 112, 252,
100, 42, 99, 18, 19, 22, 15, 241, 140, 8, 0, 15, 222, 112, 59, 154, 217, 47, 119, 42, 241, 91, 220, 212, 122, 251,
84, 241, 30, 244, 182, 197, 45, 165, 209, 23, 83, 164, 92, 86, 124, 249, 145, 74, 56, 111, 192, 225, 66, 1, 143,
184, 178, 83, 35, 244, 151, 251, 89, 161, 159, 57, 212, 125, 15, 228, 224, 250, 196, 185, 140, 82, 72, 226, 2, 144,
63, 225, 251, 163, 127, 98, 193, 12, 124, 93, 113, 59, 88, 92, 225, 174, 14, 172, 145, 201, 234, 169, 146, 44, 202,
8, 215, 187, 90, 234, 144, 60, 129, 106, 246, 69, 138, 141, 161, 226, 40, 216, 232, 12, 186, 23, 42, 19, 77, 133,
144, 124, 83, 173, 102, 16, 130, 142, 201, 86, 36, 146, 228, 152, 4, 18, 212, 146, 247, 214, 206, 15, 48, 89, 66,
192, 241, 235, 31, 18, 14, 141, 57, 72, 114, 250, 92, 69, 92, 182, 121, 137, 102, 7, 92, 43, 197, 116, 75, 32, 207,
249, 142, 164, 44, 19, 183, 100, 63, 13, 154, 220, 18, 16, 76, 14, 101, 2, 129, 220, 188, 70, 14, 126, 162, 253, 98,
239, 43, 128, 2, 158, 106, 104, 62, 219, 155, 180, 150, 105, 243, 221, 14, 255, 50, 61, 30, 235, 205, 114, 255, 226,
108, 124, 251, 205, 52, 156, 137, 150, 152, 191, 57, 232, 133, 228, 200, 10, 68, 217, 210, 199, 218, 60, 188, 24,
223, 89, 95, 16, 69, 213, 237, 199, 225, 74, 4, 24, 45, 46, 42, 38, 92, 182, 60, 228, 179, 31, 100, 231, 170, 41,
203, 167, 6, 167, 251, 116, 219, 155, 231, 184, 218, 138, 11, 253, 114, 103, 182, 215, 62, 8, 131, 51, 246, 214,
245, 58, 60, 43, 243, 38, 195, 131, 237, 211, 199, 101, 86, 82, 115, 182, 29, 180, 99, 72, 72, 34, 56, 94, 168, 59,
166, 53, 192, 40, 60, 17, 110, 253, 98, 139, 220, 193, 77, 36, 228, 231, 138, 244, 45, 35, 214, 194, 139, 83, 57,
210, 64, 211, 174, 1, 139, 57, 2, 136, 166, 204, 209, 188, 34, 163, 162, 61, 104, 94, 245, 118, 153, 112, 163, 212,
88, 100, 76, 137, 223, 135, 75, 105, 71, 103, 228, 167, 77, 81, 236, 89, 95, 152, 163, 78, 240, 224, 16, 199, 211,
2, 172, 242, 96, 171, 101, 70, 96, 88, 39, 13, 222, 12, 5, 199, 119, 30, 110, 124, 143, 99, 198, 197, 222, 236, 96,
213, 191, 141, 157, 79, 110, 211, 183, 40, 235, 54, 18, 7, 122, 50, 152, 90, 34, 171, 181, 27, 114, 148, 19, 179, 3,
222, 233, 50, 13, 101, 92, 6, 112, 142, 107, 156, 43, 29, 245, 208, 197, 172, 242, 181, 163, 112, 125, 220, 135, 83,
127, 132, 135, 47, 132, 233, 0, 38, 46, 96, 182, 177, 12, 30, 31, 89, 135, 24, 92, 17, 237, 224, 111, 157, 203, 25,
76, 23, 198, 164, 180, 97, 19, 184, 155, 95, 208, 212, 170, 151, 206, 186, 198, 34, 136, 182, 58, 190, 194, 126,
184, 92, 62, 57, 246, 27, 36, 240, 83, 20, 112, 86, 191, 202, 197, 73, 5, 231, 50, 55, 230, 99, 44, 121, 241, 52,
246, 169, 79, 168, 32, 49, 125, 181, 138, 109, 145, 40, 233, 204, 88, 143, 228, 123, 164, 161, 86, 184, 111, 2, 168,
54, 200, 109, 166, 199, 4, 238, 36, 191, 37, 160, 178, 95, 170, 110, 48, 15, 84, 216, 181, 50, 167, 220, 170, 77,
119, 252, 217, 250, 138, 173, 133, 159, 176, 126, 152, 64, 20, 149, 62, 225, 71, 178, 91, 151, 208, 114, 146, 46,
74, 14, 158, 119, 239, 16, 73, 113, 176, 151, 169, 53, 139, 166, 42, 21, 248, 170, 96, 194, 20, 186, 207, 94, 240,
222, 41, 22, 191, 182, 147, 142, 39, 216, 44, 240, 101, 192, 255, 216, 29, 108, 247, 109, 197, 19, 137, 160, 18, 30,
224, 208, 118, 197, 211, 57, 150, 126, 169, 160, 42, 178, 173, 175, 39, 254, 132, 183, 240, 41, 192, 160, 141, 115,
243, 174, 161, 70, 69, 189, 4, 108, 39, 246, 138, 52, 29, 48, 167, 31, 3, 175, 68, 197, 255, 105, 65, 159, 136, 185,
108, 42, 75, 135, 122, 231, 6, 146, 110, 87, 226, 48, 5, 16, 36, 175, 138, 123, 146, 72, 171, 183, 111, 237, 113,
216, 37, 84, 102, 226, 86, 56, 61, 133, 25, 244, 124, 184, 30, 171, 163, 35, 246, 41, 116, 194, 101, 237, 119, 244,
205, 6, 61, 39, 164, 209, 164, 33, 155, 89, 126, 187, 243, 8, 110, 2, 138, 243, 105, 116, 236, 148, 34, 198, 191,
38, 200, 155, 92, 78, 174, 247, 166, 33, 249, 201, 63, 231, 235, 127, 169, 127, 10, 54, 95, 13, 239, 5, 36, 197, 33,
82, 44, 213, 59, 106, 196, 117, 60, 151, 176, 133, 1, 96, 28, 222, 142, 73, 103, 48, 1, 50, 142, 64, 215, 39, 122,
65, 168, 141, 232, 161, 172, 155, 201, 129, 96, 115, 50, 98, 151, 26, 119, 229, 8, 55, 216, 137, 138, 22, 24, 165,
121, 6, 163, 6, 29, 159, 163, 103, 131, 2, 75, 75, 228, 79, 198, 110, 209, 195, 1, 239, 98, 21, 0, 250, 9, 102, 93,
223, 97, 64, 157, 226, 241, 206, 61, 134, 182, 180, 17, 206, 183, 224, 148, 19, 51, 122, 26, 118, 221, 64, 41, 200,
27, 247, 20, 83, 69, 224, 200, 234, 69, 117, 44, 232, 13, 107, 84, 254, 9, 106, 54, 228, 60, 31, 152, 183, 240, 101,
35, 246, 0, 159, 233, 235, 252, 252, 37, 20, 71, 145, 130, 144, 142, 166, 65, 183, 193, 21, 56, 131, 222, 236, 159,
204, 116, 149, 94, 212, 84, 115, 28, 201, 99, 98, 212, 1, 31, 203, 78, 189, 145, 76, 177, 172, 184, 251, 129, 177,
148, 0, 48, 149, 182, 80, 230, 252, 31, 230, 181, 27, 248, 82, 215, 148, 195, 184, 2, 119, 80, 124, 15, 252, 168,
229, 124, 173, 64, 59, 77, 116, 108, 106, 19, 84, 28, 173, 246, 47, 100, 27, 209, 97, 63, 49, 59, 113, 106, 122,
115, 91, 87, 210, 27, 30, 99, 213, 20, 21, 117, 54, 182, 8, 66, 217, 170, 5, 135, 190, 245, 255, 247, 232, 163, 49,
138, 92, 146, 215, 173, 18, 115, 2, 117, 2, 65, 192, 121, 111, 4, 166, 148, 82, 40, 144, 236, 228, 147, 99, 91, 14,
198, 252, 20, 150, 93, 90, 64, 180, 160, 62, 139, 112, 56, 158, 23, 172, 187, 230, 255, 66, 111, 253, 67, 95, 248,
203, 23, 215, 33, 251, 91, 40, 203, 35, 71, 77, 215, 86, 220, 178, 150, 215, 77, 115, 153, 107, 67, 105, 224, 204,
247, 144, 141, 61, 151, 89, 144, 145, 192, 67, 238, 135, 4, 137, 230, 4, 82, 238, 15, 186, 150, 190, 145, 237, 104,
120, 36, 237, 224, 96, 200, 191, 42, 116, 103, 17, 31, 11, 236, 27, 200, 253, 143, 247, 37, 28, 138, 96, 168, 51,
186, 141, 220, 97, 82, 33, 141, 129, 184, 120, 63, 25, 239, 67, 0, 66, 13, 50, 192, 67, 181, 180, 112, 33, 15, 63,
184, 156, 221, 231, 39, 212, 207, 136, 54, 194, 102, 193, 71, 195, 127, 100, 195, 114, 217, 213, 233, 121, 85, 244,
31, 110, 175, 62, 72, 80, 4, 147, 92, 2, 106, 150, 240, 28, 185, 25, 153, 108, 247, 115, 92, 197, 27, 200, 101, 67,
91, 105, 199, 171, 111, 188, 243, 57, 11, 30, 71, 30, 0, 210, 122, 97, 141, 242, 34, 155, 87, 87, 32, 153, 232, 118,
41, 194, 82, 200, 110, 218, 135, 247, 160, 15, 73, 10, 86, 186, 191, 27, 206, 227, 111, 150, 98, 78, 38, 170, 36,
133, 131, 253, 232, 231, 149, 33, 74, 230, 221, 130, 11, 191, 111, 185, 75, 27, 108, 19, 13, 15, 170, 87, 225, 1,
221, 42, 238, 146, 10, 10, 69, 255, 202, 134, 55, 200, 92, 27, 46, 38, 29, 134, 74, 131, 153, 61, 40, 63, 241, 52,
76, 143, 151, 89, 208, 147, 238, 0, 210, 35, 99, 121, 181, 72, 94, 47, 15, 107, 44, 184, 142, 74, 175, 0, 225, 134,
105, 168, 97, 238, 199, 167, 200, 146, 124, 127, 59, 157, 15, 5, 237, 60, 17, 60, 73, 247, 193, 80, 208, 88, 187, 2,
93, 14, 15, 169, 77, 108, 10, 202, 96, 22, 27, 29, 166, 51, 95, 75, 194, 121, 132, 129, 118, 37, 130, 63, 193, 237,
163, 93, 117, 69, 206, 69, 109, 118, 69, 235, 115, 117, 79, 242, 68, 81, 231, 107, 152, 98, 82, 136, 214, 105, 41,
50, 79, 22, 35, 139, 80, 33, 3, 48, 241, 138, 91, 191, 106, 60, 85, 14, 71, 242, 179, 43, 7, 179, 222, 102, 125,
232, 204, 159, 62, 31, 9, 203, 242, 43, 10, 223, 149, 53, 67, 101, 114, 186, 88, 1, 71, 24, 34, 155, 105, 159, 240,
213, 22, 70, 90, 6, 203, 209, 82, 246, 38, 62, 113, 163, 139, 176, 29, 112, 125, 245, 182, 105, 98, 83, 206, 45,
239, 51, 144, 110, 233, 231, 59, 209, 215, 99, 62, 53, 89, 41, 127, 2, 85, 16, 114, 150, 100, 141, 227, 125, 116, 9,
156, 250, 209, 128, 253, 38, 121, 238, 234, 94, 85, 112, 25, 73, 174, 238, 229, 21, 197, 24, 81, 13, 10, 87, 68,
161, 72, 150, 140, 254, 69, 47, 79, 205, 2, 101, 113, 179, 217, 124, 36, 167, 28, 26, 8, 173, 47, 15, 222, 194, 148,
188, 59, 37, 157, 172, 49, 42, 224, 136, 223, 140, 246, 0, 11, 155, 202, 93, 143, 183, 240, 105, 218, 103, 92, 74,
39, 223, 157, 215, 48, 176, 141, 118, 175, 15, 66, 15, 226, 6, 133, 249, 215, 224, 188, 80, 68, 181, 134, 215, 161,
201, 106, 61, 113, 223, 200, 31, 139, 151, 235, 153, 119, 235, 139, 166, 246, 76, 206, 165, 254, 226, 59, 253, 16,
146, 118, 16, 233, 169, 93, 38, 79, 65, 56, 55, 113, 244, 123, 100, 143, 3, 15, 49, 196, 233, 96, 50, 104, 131, 87,
224, 137, 47, 24, 19, 98, 203, 115, 101, 3, 97, 224, 209, 134, 57, 241, 3, 254, 207, 216, 219, 195, 103, 20, 10,
230, 38, 243, 144, 243, 52, 215, 5, 99, 40, 173, 84, 47, 218, 31, 197, 97, 194, 97, 178, 161, 230, 1, 150, 189, 62,
243, 141, 121, 98, 39, 101, 53, 96, 40, 92, 8, 243, 185, 179, 134, 69, 56, 46, 31, 43, 113, 58, 36, 6, 57, 12, 175,
0, 64, 136, 84, 189, 151, 36, 251, 80, 223, 128, 139, 249, 177, 108, 25, 223, 143, 138, 177, 136, 159, 119, 167,
222, 63, 107, 98, 130, 61, 105, 220, 76, 229, 117, 231, 219, 79, 210, 36, 201, 202, 213, 219, 18, 235, 173, 16, 109,
176, 68, 130, 100, 235, 234, 222, 91, 89, 77, 191, 140, 11, 208, 187, 212, 74, 170, 212, 187, 197, 129, 110, 166,
66, 47, 81, 45, 32, 126, 201, 0, 109, 110, 25, 102, 221, 97, 74, 235, 6, 87, 13, 197, 99, 201, 48, 172, 250, 98,
127, 6, 142, 0, 219, 169, 31, 6, 165, 241, 208, 206, 239, 166, 74, 25, 90, 99, 110, 126, 64, 164, 10, 172, 126, 78,
39, 134, 12, 65, 59, 212, 154, 35, 51, 128, 237, 10, 108, 212, 158, 105, 125, 157, 239, 131, 182, 167, 7, 242, 136,
87, 107, 107, 206, 91, 80, 171, 204, 234, 83, 158, 185, 127, 191, 185, 89, 204, 45, 132, 60, 166, 81, 27, 80, 228,
36, 149, 129, 36, 2, 163, 41, 154, 35, 50, 27, 28, 182, 151, 238, 63, 85, 13, 115, 157, 169, 2, 159, 37, 246, 30,
157, 81, 220, 143, 70, 226, 224, 214, 137, 117, 53, 161, 216, 97, 175, 199, 2, 250, 117, 184, 16, 153, 29, 186, 61,
214, 42, 81, 228, 41, 107, 253, 54, 25, 51, 242, 94, 18, 25, 166, 57, 113, 27, 131, 101, 169, 84, 237, 234, 32, 125,
31, 78, 39, 218, 166, 179, 123, 92, 144, 189, 222, 251, 25, 215, 4, 98, 62, 226, 121, 98, 170, 180, 118, 163, 10,
70, 145, 249, 217, 223, 55, 181, 174, 120, 68, 173, 80, 87, 177, 217, 142, 34, 23, 109, 176, 60, 136, 1, 226, 91,
102, 121, 90, 123, 123, 243, 198, 102, 240, 25, 206, 255, 132, 5, 79, 109, 29, 94, 214, 18, 228, 238, 11, 157, 64,
92, 107, 6, 24, 109, 233, 156, 204, 22, 59, 189, 102, 173, 130, 162, 181, 127, 227, 73, 148, 248, 17, 52, 78, 199,
54, 202, 78, 134, 180, 202, 124, 17, 136, 142, 17, 71, 209, 218, 111, 22, 255, 163, 67, 1, 126, 83, 69, 244, 129,
231, 100, 130, 61, 225, 220, 198, 249, 230, 84, 174, 143, 25, 155, 105, 87, 207, 222, 246, 150, 9, 102, 210, 63,
238, 27, 174, 13, 43, 13, 29, 30, 112, 27, 184, 20, 84, 232, 252, 75, 69, 45, 144, 118, 153, 140, 14, 168, 204, 197,
113, 81, 173, 81, 152, 194, 105, 241, 76, 33, 203, 67, 216, 255, 57, 10, 134, 213, 196, 216, 79, 184, 76, 90, 246,
119, 98, 76, 197, 251, 253, 152, 73, 209, 201, 168, 180, 246, 212, 9, 14, 91, 10, 57, 167, 167, 188, 241, 15, 251,
191, 174, 158, 57, 128, 132, 140, 183, 13, 8, 155, 187, 17, 123, 245, 206, 140, 28, 111, 47, 84, 79, 225, 38, 151,
137, 210, 189, 110, 106, 122, 199, 133, 34, 140, 98, 201, 50, 176, 161, 248, 85, 174, 110, 53, 104, 185, 194, 131,
159, 167, 172, 190, 14, 247, 56, 16, 160, 86, 121, 201, 239, 157, 56, 219, 60, 249, 216, 237, 150, 251, 78, 43, 247,
203, 167, 5, 238, 140, 220, 233, 206, 83, 228, 213, 131, 10, 49, 211, 166, 119, 161, 36, 88, 236, 1, 98, 62, 89,
241, 4, 59, 115, 99, 77, 186, 171, 35, 68, 84, 249, 225, 73, 227, 48, 148, 72, 171, 135, 42, 95, 51, 29, 77, 5, 22,
90, 175, 188, 127, 83, 195, 236, 217, 10, 39, 215, 54, 162, 178, 19, 206, 180, 90, 70, 215, 116, 133, 136, 117, 75,
170, 146, 55, 84, 71, 234, 255, 92, 179, 224, 71, 204, 29, 112, 105, 104, 113, 237, 235, 40, 45, 231, 198, 171, 243,
19, 176, 219, 166, 122, 71, 165, 200, 18, 158, 54, 245, 91, 162, 42, 80, 6, 247, 85, 82, 69, 13, 246, 30, 239, 233,
228, 54, 129, 126, 54, 102, 19, 81, 134, 97, 108, 102, 9, 154, 134, 177, 115, 47, 62, 83, 166, 51, 175, 46, 44, 10,
128, 158, 86, 35, 128, 124, 144, 20, 64, 121, 62, 241, 217, 93, 85, 36, 58, 58, 242, 63, 146, 172, 64, 5, 167, 113,
96, 63, 172, 84, 149, 255, 214, 242, 107, 97, 69, 31, 97, 217, 168, 86, 8, 148, 62, 6, 124, 121, 53, 63, 201, 57,
177, 78, 0, 89, 204, 28, 38, 130, 170, 96, 168, 74, 149, 172, 209, 59, 252, 194, 11, 161, 43, 88, 249, 123, 147,
165, 125, 201, 122, 133, 42, 39, 94, 232, 75, 43, 120, 100, 37, 232, 155, 46, 51, 104, 31, 231, 238, 67, 229, 113,
74, 70, 156, 196, 12, 32, 174, 217, 219, 152, 115, 124, 246, 186, 58, 29, 93, 64, 151, 230, 194, 16, 173, 206, 246,
102, 138, 48, 201, 152, 125, 250, 29, 41, 21, 5, 238, 203, 34, 77, 69, 100, 233, 227, 28, 222, 76, 62, 83, 7, 225,
88, 69, 105, 86, 149, 165, 105, 8, 123, 20, 149, 12, 157, 82, 180, 37, 67, 237, 60, 46, 96, 46, 113, 107, 7, 73,
211, 221, 221, 228, 159, 175, 208, 127, 165, 55, 241, 159, 96, 38, 83, 210, 241, 58, 62, 156, 10, 108, 169, 140, 8,
9, 121, 168, 177, 64, 251, 198, 186, 145, 80, 135, 195, 239, 185, 136, 54, 192, 211, 84, 161, 65, 10, 197, 78, 40,
169, 64, 38, 193, 219, 190, 241, 252, 83, 123, 234, 222, 234, 242, 37, 166, 201, 86, 232, 218, 208, 199, 62, 28,
143, 58, 72, 19, 192, 252, 221, 188, 146, 147, 250, 73, 18, 103, 81, 38, 15, 80, 71, 97, 164, 57, 251, 173, 94, 227,
206, 184, 124, 111, 196, 131, 6, 99, 50, 79, 32, 237, 169, 82, 169, 5, 254, 10, 68, 36, 247, 226, 8, 164, 139, 191,
207, 228, 210, 190, 3, 238, 160, 74, 242, 90, 250, 139, 246, 137, 205, 202, 197, 179, 144, 81, 224, 5, 130, 242,
197, 253, 23, 184, 164, 84, 88, 4, 27, 241, 114, 242, 70, 179, 213, 148, 18, 97, 173, 70, 241, 109, 165, 11, 13,
216, 98, 59, 22, 248, 47, 197, 220, 128, 35, 39, 81, 210, 93, 166, 165, 214, 94, 131, 163, 109, 95, 244, 82, 142,
136, 159, 101, 97, 14, 145, 125, 129, 106, 99, 167, 44, 34, 143, 92, 205, 148, 123, 17, 239, 119, 144, 123, 28, 233,
133, 164, 120, 212, 194, 182, 111, 197, 151, 156, 101, 115, 198, 5, 203, 190, 13, 222, 53, 197, 109, 69, 89, 239,
155, 136, 11, 231, 94, 148, 136, 40, 16, 149, 116, 85, 41, 204, 177, 66, 35, 193, 139, 98, 76, 62, 152, 1, 247, 189,
62, 143, 56, 230, 109, 153, 185, 21, 17, 59, 15, 220, 62, 62, 216, 201, 159, 117, 138, 202, 87, 20, 103, 236, 159,
253, 166, 148, 89, 205, 180, 151, 18, 57, 172, 191, 197, 211, 247, 110, 94, 11, 78, 23, 120, 222, 156, 52, 99, 25,
216, 3, 15, 213, 215, 195, 161, 123, 148, 113, 61, 40, 140, 74, 217, 63, 47, 239, 231, 56, 204, 28, 120, 176, 100,
221, 131, 13, 188, 247, 253, 162, 209, 255, 153, 47, 127, 41, 201, 114, 95, 147, 25, 37, 218, 36, 101, 34, 94, 163,
73, 118, 205, 213, 127, 60, 65, 93, 123, 11, 65, 248, 17, 44, 13, 73, 195, 226, 106, 137, 72, 5, 203, 52, 158, 141,
127, 210, 157, 166, 145, 215, 155, 94, 71, 64, 91, 78, 71, 77, 159, 95, 143, 238, 154, 122, 165, 73, 20, 92, 197,
50, 99, 41, 97, 106, 196, 143, 192, 149, 42, 182, 232, 208, 125, 59, 196, 44, 12, 88, 93, 55, 156, 52, 134, 128, 98,
90, 236, 46, 15, 232, 90, 142, 124, 182, 31, 142, 30, 203, 38, 58, 218, 214, 33, 204, 201, 246, 244, 4, 217, 3, 124,
201, 99, 54, 30, 33, 139, 195, 97, 177, 138, 59, 255, 68, 213, 121, 46, 169, 107, 204, 46, 225, 223, 182, 231, 154,
192, 234, 50, 229, 19, 42, 42, 149, 240, 76, 74, 164, 83, 26, 12, 75, 110, 65, 49, 106, 2, 115, 58, 39, 225, 193,
117, 25, 81, 22, 205, 96, 2, 238, 249, 246, 19, 119, 169, 88, 90, 33, 118, 138, 77, 230, 38, 57, 31, 31, 47, 80,
177, 77, 47, 251, 4, 85, 46, 15, 38, 34, 111, 117, 1, 45, 24, 21, 18, 35, 209, 90, 32, 227, 162, 21, 96, 73, 74,
151, 10, 179, 36, 98, 48, 35, 96, 96, 119, 240, 186, 236, 222, 83, 155, 118, 202, 123, 49, 245, 23, 153, 78, 21,
104, 110, 159, 82, 83, 33, 8, 175, 26, 248, 213, 191, 103, 105, 20, 2, 173, 43, 234, 217, 81, 10, 226, 190, 59, 136,
144, 230, 81, 175, 172, 192, 165, 18, 76, 109, 121, 204, 172, 9, 131, 146, 141, 197, 84, 197, 235, 73, 15, 155, 173,
201, 89, 157, 205, 171, 243, 14, 34, 80, 156, 83, 3, 164, 144, 152, 90, 2, 106, 224, 152, 180, 236, 69, 122, 103,
139, 121, 80, 105, 159, 170, 24, 100, 18, 38, 231, 167, 64, 251, 15, 62, 74, 143, 147, 10, 74, 197, 127, 190, 108,
50, 84, 102, 108, 178, 182, 91, 194, 49, 246, 3, 20, 103, 164, 41, 229, 148, 39, 142, 186, 230, 102, 94, 78, 67, 60,
34, 156, 151, 226, 177, 192, 219, 100, 244, 162, 210, 45, 1, 49, 215, 81, 72, 255, 109, 252, 247, 58, 64, 37, 114,
174, 248, 8, 178, 239, 18, 130, 169, 41, 239, 49, 83, 65, 5, 164, 31, 248, 178, 249, 124, 4, 60, 172, 126, 161, 231,
145, 186, 252, 168, 190, 130, 50, 75, 179, 151, 5, 147, 30, 209, 142, 86, 218, 193, 121, 76, 77, 53, 191, 9, 71,
139, 58, 147, 180, 147, 219, 97, 58, 189, 211, 28, 48, 126, 16, 64, 5, 251, 25, 50, 66, 130, 17, 200, 62, 152, 80,
225, 113, 255, 13, 63, 34, 105, 79, 146, 25, 61, 5, 151, 159, 123, 173, 20, 252, 255, 227, 247, 94, 66, 140, 196,
139, 11, 75, 67, 168, 10, 252, 123, 203, 110, 121, 212, 95, 153, 113, 11, 138, 27, 168, 42, 119, 195, 233, 59, 44,
174, 121, 64, 167, 183, 213, 221, 23, 229, 140, 189, 219, 193, 94, 108, 196, 106, 25, 227, 158, 70, 167, 66, 27, 69,
213, 170, 163, 21, 105, 67, 125, 177, 14, 41, 192, 171, 34, 238, 169, 66, 78, 18, 185, 71, 98, 220, 61, 223, 91,
156, 110, 152, 187, 7, 242, 155, 8, 188, 225, 3, 68, 43, 41, 131, 26, 55, 129, 161, 136, 200, 131, 105, 164, 254,
212, 242, 232, 124, 215, 113, 203, 50, 62, 164, 69, 241, 107, 84, 89, 196, 177, 172, 129, 190, 163, 23, 63, 216,
175, 143, 52, 103, 171, 195, 229, 208, 208, 158, 106, 202, 198, 145, 9, 122, 97, 3, 59, 249, 107, 110, 246, 123,
186, 211, 234, 43, 247, 230, 139, 24, 235, 46, 31, 251, 25, 170, 45, 172, 110, 102, 115, 21, 113, 132, 146, 198, 68,
8, 11, 226, 226, 246, 148, 122, 39, 216, 52, 62, 22, 42, 63, 177, 85, 232, 59, 79, 72, 244, 24, 160, 10, 123, 143,
192, 111, 94, 166, 223, 99, 88, 103, 168, 166, 183, 97, 208, 108, 232, 150, 118, 44, 180, 94, 129, 147, 134, 46,
115, 57, 28, 83, 125, 209, 34, 188, 190, 245, 47, 188, 107, 13, 231, 246, 159, 39, 28, 3, 49, 177, 133, 199, 60, 30,
169, 88, 97, 47, 83, 211, 59, 171, 23, 182, 97, 166, 118, 102, 143, 251, 166, 32, 132, 171, 211, 139, 176, 82, 29,
16, 222, 49, 206, 145, 135, 203, 27, 24, 107, 29, 65, 26, 185, 9, 61, 87, 241, 212, 11, 19, 243, 241, 163, 217, 214,
210, 151, 223, 103, 233, 122, 194, 181, 185, 105, 56, 179, 174, 140, 97, 172, 133, 76, 231, 255, 111, 14, 105, 186,
239, 99, 88, 243, 164, 4, 4, 163, 249, 83, 26, 21, 0, 34, 110, 74, 145, 202, 207, 223, 145, 66, 87, 252, 253, 6,
175, 95, 137, 27, 224, 82, 198, 7, 124, 31, 198, 80, 252, 23, 111, 40, 13, 225, 5, 107, 125, 217, 124, 129, 39, 104,
79, 6, 49, 20, 171, 23, 35, 232, 212, 134, 201, 108, 3, 205, 150, 204, 67, 83, 151, 248, 228, 252, 53, 152, 73, 189,
200, 85, 108, 211, 205, 127, 111, 79, 23, 26, 195, 63, 147, 16, 219, 108, 198, 100, 55, 178, 215, 62, 209, 6, 235,
5, 172, 204, 226, 81, 202, 172, 141, 6, 76, 167, 241, 250, 90, 83, 168, 88, 68, 246, 115, 89, 158, 205, 59, 43, 96,
212, 70, 186, 201, 213, 194, 21, 209, 24, 87, 43, 22, 239, 21, 227, 181, 54, 33, 91, 109, 66, 70, 6, 203, 248, 11,
76, 101, 45, 104, 15, 168, 71, 150, 117, 226, 26, 241, 172, 168, 89, 193, 107, 99, 91, 212, 159, 208, 210, 19, 66,
20, 119, 5, 131, 218, 111, 158, 61, 208, 209, 111, 98, 120, 124, 127, 16, 214, 170, 9, 255, 156, 82, 205, 104, 75,
33, 0, 144, 77, 60, 5, 137, 67, 64, 148, 87, 111, 246, 192, 58, 169, 142, 8, 241, 46, 156, 68, 221, 89, 195, 155,
212, 179, 130, 180, 247, 206, 172, 221, 74, 165, 217, 192, 7, 173, 175, 250, 21, 109, 221, 108, 3, 221, 100, 166,
48, 33, 157, 179, 119, 202, 63, 8, 185, 206, 33, 165, 7, 221, 76, 209, 72, 14, 115, 150, 230, 88, 221, 90, 130, 131,
231, 237, 84, 10, 217, 52, 168, 62, 183, 59, 243, 188, 177, 197, 97, 69, 217, 212, 40, 8, 63, 235, 79, 62, 93, 237,
36, 63, 212, 38, 51, 207, 62, 106, 33, 190, 245, 128, 73, 3, 179, 97, 77, 163, 182, 62, 204, 122, 28, 23, 213, 194,
238, 10, 2, 132, 227, 5, 32, 7, 146, 196, 6, 185, 97, 143, 24, 27, 87, 236, 159, 48, 120, 101, 127, 27, 95, 58, 57,
67, 189, 47, 97, 60, 13, 23, 213, 173, 6, 216, 102, 103, 61, 86, 51, 117, 114, 241, 228, 100, 154, 126, 151, 132,
238, 122, 30, 34, 91, 16, 181, 0, 14, 74, 222, 44, 132, 159, 96, 159, 177, 136, 202, 252, 13, 141, 182, 228, 212,
195, 40, 46, 155, 13, 203, 147, 168, 113, 4, 42, 115, 195, 246, 214, 54, 231, 119, 126, 207, 186, 189, 108, 9, 10,
231, 143, 185, 35, 92, 196, 200, 182, 81, 188, 148, 134, 68, 88, 66, 78, 2, 224, 75, 112, 121, 142, 113, 192, 84,
144, 27, 46, 101, 155, 30, 42, 149, 21, 71, 206, 18, 47, 120, 156, 21, 76, 242, 99, 219, 15, 104, 7, 39, 228, 8, 88,
199, 43, 128, 144, 113, 92, 81, 200, 128, 70, 19, 246, 206, 17, 168, 208, 231, 129, 46, 191, 211, 218, 205, 43, 82,
227, 193, 242, 4, 178, 154, 250, 163, 237, 23, 35, 72, 165, 156, 205, 250, 165, 27, 235, 207, 30, 174, 25, 172, 121,
100, 172, 231, 227, 254, 137, 114, 103, 73, 7, 162, 200, 235, 24, 72, 210, 190, 193, 15, 182, 70, 54, 246, 1, 113,
194, 114, 124, 151, 95, 48, 113, 160, 215, 124, 38, 132, 162, 87, 191, 200, 165, 227, 217, 50, 161, 235, 219, 195,
225, 226, 230, 121, 248, 95, 19, 121, 50, 221, 56, 163, 3, 194, 12, 166, 24, 74, 150, 239, 72, 28, 251, 0, 209, 213,
141, 81, 220, 164, 196, 60, 159, 214, 220, 88, 118, 204, 85, 244, 76, 124, 235, 36, 138, 209, 48, 42, 242, 170, 99,
181, 7, 150, 64, 235, 233, 249, 10, 22, 143, 100, 39, 64, 33, 20, 254, 167, 100, 246, 150, 70, 241, 14, 16, 74, 240,
77, 93, 77, 18, 71, 203, 53, 68, 133, 253, 132, 253, 66, 57, 3, 103, 132, 90, 150, 246, 77, 139, 66, 213, 112, 174,
100, 218, 155, 169, 184, 210, 210, 22, 27, 114, 76, 6, 127, 102, 194, 98, 124, 124, 147, 237, 103, 93, 132, 5, 230,
217, 20, 244, 51, 211, 128, 57, 147, 120, 94, 15, 221, 128, 41, 38, 55, 248, 73, 189, 1, 242, 11, 235, 207, 173,
242, 95, 72, 34, 144, 159, 249, 174, 68, 157, 88, 245, 184, 38, 172, 94, 234, 32, 211, 158, 177, 46, 93, 20, 164,
36, 129, 147, 45, 220, 112, 28, 49, 210, 120, 123, 105, 250, 116, 219, 248, 99, 89, 168, 136, 88, 114, 177, 81, 162,
109, 94, 29, 25, 18, 42, 133, 189, 95, 69, 92, 173, 12, 239, 165, 228, 219, 232, 158, 128, 187, 200, 144, 224, 27,
197, 191, 145, 193, 153, 49, 28, 100, 44, 147, 235, 119, 210, 244, 247, 133, 20, 227, 53, 151, 228, 81, 44, 201,
126, 217, 202, 152, 59, 255, 152, 204, 99, 176, 207, 28, 149, 136, 23, 125, 113, 190, 238, 62, 143, 93, 207, 111,
105, 109, 176, 92, 76, 78, 225, 82, 157, 250, 187, 205, 143, 224, 84, 206, 202, 240, 238, 73, 52, 115, 242, 193,
140, 192, 99, 51, 167, 98, 150, 183, 120, 68, 94, 118, 109, 124, 180, 191, 203, 106, 176, 0, 121, 30, 116, 69, 176,
32, 101, 253, 13, 244, 189, 211, 209, 62, 62, 244, 6, 250, 43, 183, 8, 64, 166, 52, 78, 108, 49, 17, 104, 103, 33,
71, 101, 249, 64, 136, 102, 193, 118, 69, 34, 76, 116, 36, 232, 113, 194, 194, 177, 234, 195, 240, 172, 164, 2, 99,
144, 80, 207, 61, 133, 87, 232, 50, 237, 118, 59, 219, 142, 43, 129, 65, 98, 151, 187, 213, 181, 40, 33, 42, 80, 17,
97, 160, 176, 193, 145, 237, 39, 77, 22, 84, 131, 156, 151, 127, 112, 49, 132, 219, 64, 141, 53, 105, 35, 237, 191,
55, 120, 215, 39, 11, 6, 76, 228, 253, 139, 180, 28, 7, 106, 191, 185, 232, 106, 115, 107, 25, 124, 82, 92, 51, 17,
250, 99, 249, 247, 72, 247, 225, 203, 138, 33, 180, 235, 37, 20, 244, 236, 79, 26, 191, 153, 117, 86, 157, 221, 50,
69, 99, 146, 107, 170, 7, 38, 77, 236, 98, 227, 176, 52, 205, 115, 89, 46, 76, 61, 23, 154, 162, 95, 168, 87, 32,
215, 173, 211, 79, 52, 193, 185, 196, 92, 214, 166, 155, 67, 164, 42, 242, 239, 130, 78, 194, 7, 112, 8, 37, 99,
246, 242, 7, 114, 100, 172, 23, 175, 76, 117, 230, 165, 111, 45, 17, 0, 83, 191, 131, 117, 177, 196, 183, 226, 71,
198, 61, 8, 62, 179, 44, 243, 137, 152, 107, 175, 38, 66, 240, 79, 234, 153, 191, 15, 90, 176, 106, 229, 34, 151,
200, 240, 160, 113, 9, 147, 68, 138, 32, 93, 153, 29, 25, 83, 191, 128, 128, 206, 237, 41, 48, 235, 36, 13, 133,
245, 187, 57, 253, 193, 172, 22, 222, 36, 192, 68, 229, 82, 133, 62, 201, 0, 16, 113, 200, 149, 181, 84, 121, 214,
201, 221, 179, 172, 69, 157, 27, 204, 164, 7, 124, 109, 118, 181, 128, 125, 77, 2, 29, 213, 108, 146, 181, 192, 15,
233, 132, 44, 148, 51, 184, 239, 29, 52, 217, 11, 227, 98, 175, 43, 2, 106, 87, 77, 119, 24, 147, 242, 58, 213, 220,
0, 208, 44, 164, 199, 57, 108, 5, 253, 26, 236, 62, 161, 151, 218, 255, 215, 68, 35, 59, 15, 106, 205, 67, 146, 70,
117, 68, 114, 86, 184, 36, 30, 12, 107, 216, 252, 170, 161, 153, 18, 139, 167, 198, 255, 122, 47, 57, 80, 8, 174,
85, 122, 179, 222, 194, 16, 217, 176, 102, 28, 42, 215, 138, 224, 60, 72, 231, 70, 44, 0, 94, 72, 138, 240, 98, 127,
65, 215, 64, 146, 136, 113, 21, 192, 189, 123, 232, 216, 17, 30, 177, 113, 242, 29, 229, 126, 200, 236, 10, 209, 10,
165, 38, 22, 36, 105, 226, 112, 243, 32, 54, 251, 132, 82, 201, 246, 65, 115, 70, 41, 164, 74, 160, 21, 28, 100, 24,
231, 32, 88, 247, 214, 22, 37, 163, 27, 201, 116, 98, 99, 239, 196, 246, 164, 167, 125, 233, 146, 186, 225, 136, 62,
123, 247, 59, 56, 179, 192, 135, 15, 148, 9, 72, 19, 23, 64, 82, 28, 11, 120, 2, 28, 206, 60, 193, 82, 88, 31, 200,
113, 208, 66, 73, 135, 193, 107, 105, 86, 248, 100, 2, 216, 177, 232, 18, 187, 13, 1, 143, 28, 19, 155, 46, 166,
173, 95, 228, 138, 63, 10, 146, 88, 90, 54, 153, 199, 179, 187, 44, 240, 112, 21, 90, 48, 51, 202, 90, 49, 161, 89,
29, 72, 242, 2, 61, 173, 165, 154, 253, 242, 126, 213, 217, 244, 221, 129, 66, 46, 143, 57, 79, 250, 38, 131, 222,
60, 93, 168, 3, 57, 175, 96, 138, 157, 178, 197, 244, 246, 126, 173, 141, 56, 243, 112, 41, 192, 148, 60, 218, 187,
161, 209, 38, 190, 1, 233, 111, 6, 195, 145, 26, 45, 177, 122, 141, 65, 206, 4, 45, 244, 235, 140, 106, 137, 238,
173, 58, 115, 45, 150, 121, 48, 90, 60, 136, 19, 166, 4, 191, 225, 203, 133, 164, 233, 63, 75, 77, 146, 219, 248,
246, 172, 158, 217, 223, 247, 178, 255, 206, 105, 76, 75, 227, 123, 90, 130, 171, 189, 94, 109, 182, 211, 78, 15,
230, 81, 148, 99, 197, 136, 123, 218, 174, 250, 128, 244, 130, 159, 16, 160, 10, 196, 223, 251, 23, 78, 253, 86,
245, 24, 43, 109, 190, 168, 235, 14, 69, 42, 184, 147, 72, 39, 71, 169, 144, 242, 191, 207, 177, 33, 224, 108, 83,
104, 97, 30, 235, 195, 162, 107, 44, 174, 23, 80, 106, 144, 114, 156, 27, 255, 59, 103, 48, 180, 212, 30, 65, 62,
108, 19, 10, 212, 217, 157, 99, 255, 226, 244, 106, 120, 222, 185, 172, 217, 166, 255, 182, 170, 82, 31, 202, 102,
122, 98, 173, 59, 193, 240, 79, 143, 227, 244, 126, 182, 161, 200, 187, 179, 164, 29, 249, 156, 104, 182, 68, 68,
198, 122, 88, 144, 67, 28, 192, 194, 110, 159, 132, 82, 157, 181, 221, 133, 26, 160, 84, 133, 173, 51, 79, 30, 236,
238, 119, 133, 25, 57, 19, 85, 10, 95, 133, 236, 144, 61, 133, 214, 197, 96, 50, 204, 231, 95, 246, 190, 149, 41,
167, 170, 17, 148, 232, 72, 32, 171, 33, 190, 249, 5, 132, 177, 205, 213, 175, 68, 141, 1, 177, 64, 177, 86, 43,
153, 192, 250, 13, 194, 12, 182, 49, 151, 42, 9, 77, 45, 250, 233, 158, 201, 163, 52, 28, 51, 168, 31, 167, 99, 61,
182, 33, 128, 22, 131, 163, 220, 214, 69, 23, 72, 93, 48, 145, 180, 15, 244, 12, 212, 34, 212, 143, 187, 153, 220,
179, 147, 71, 65, 9, 8, 100, 68, 165, 43, 120, 134, 229, 2, 109, 87, 150, 67, 98, 21, 117, 55, 14, 162, 20, 114,
140, 80, 22, 63, 57, 204, 33, 36, 193, 39, 137, 29, 196, 151, 103, 165, 173, 147, 174, 103, 69, 43, 114, 154, 24,
146, 199, 143, 177, 147, 41, 60, 106, 1, 136, 91, 95, 138, 119, 184, 219, 243, 77, 34, 159, 153, 175, 36, 53, 126,
87, 147, 86, 19, 161, 34, 206, 172, 136, 50, 115, 158, 47, 241, 14, 109, 192, 194, 244, 42, 47, 166, 170, 58, 96,
225, 124, 83, 221, 97, 208, 180, 54, 121, 119, 3, 73, 108, 81, 169, 231, 196, 50, 24, 82, 156, 164, 111, 94, 154,
51, 13, 23, 57, 105, 141, 224, 33, 177, 214, 108, 19, 216, 125, 69, 199, 195, 73, 191, 194, 95, 56, 42, 112, 12,
245, 192, 168, 96, 214, 134, 45, 119, 92, 64, 63, 94, 80, 195, 233, 42, 189, 202, 236, 240, 98, 76, 8, 236, 106,
136, 240, 155, 247, 86, 225, 112, 65, 72, 207, 174, 26, 229, 123, 173, 241, 165, 107, 227, 163, 103, 181, 41, 165,
86, 212, 239, 224, 44, 3, 110, 41, 197, 71, 14, 82, 135, 216, 205, 43, 151, 204, 208, 206, 15, 103, 168, 20, 245,
22, 216, 112, 151, 53, 157, 171, 31, 49, 128, 112, 154, 107, 254, 35, 61, 76, 88, 164, 239, 147, 66, 235, 10, 143,
135, 192, 52, 0, 184, 170, 87, 170, 147, 63, 209, 210, 88, 15, 160, 166, 194, 90, 169, 238, 208, 25, 78, 48, 57,
155, 203, 15, 123, 77, 241, 188, 176, 123, 234, 145, 156, 157, 54, 253, 13, 102, 178, 242, 132, 131, 38, 254, 2,
180, 147, 202, 6, 184, 206, 251, 20, 192, 166, 149, 133, 217, 135, 180, 238, 237, 68, 46, 27, 224, 65, 43, 156, 79,
162, 45, 211, 166, 112, 48, 201, 221, 120, 250, 217, 221, 116, 122, 180, 123, 248, 184, 158, 42, 78, 98, 220, 60,
65, 74, 255, 142, 39, 99, 37, 243, 88, 137, 136, 173, 18, 53, 68, 191, 73, 219, 214, 224, 127, 219, 15, 238, 192,
15, 238, 228, 231, 7, 76, 123, 145, 189, 242, 177, 242, 132, 235, 181, 208, 53, 234, 107, 137, 122, 167, 32, 165,
172, 55, 198, 55, 151, 53, 93, 19, 41, 11, 151, 186, 76, 143, 76, 144, 93, 208, 76, 141, 221, 117, 136, 183, 217,
185, 183, 202, 227, 184, 225, 161, 24, 116, 77, 248, 171, 23, 186, 30, 87, 191, 181, 179, 122, 114, 188, 133, 91,
33, 204, 53, 229, 184, 138, 21, 93, 26, 23, 86, 247, 65, 27, 174, 73, 5, 31, 205, 115, 160, 83, 252, 93, 31, 30,
205, 109, 9, 247, 4, 156, 243, 200, 90, 24, 233, 12, 62, 108, 19, 167, 34, 132, 20, 156, 80, 57, 225, 178, 226, 141,
25, 80, 144, 96, 113, 114, 20, 18, 246, 15, 193, 162, 88, 60, 132, 143, 44, 1, 145, 223, 43, 214, 33, 217, 88, 145,
161, 6, 43, 91, 114, 150, 97, 246, 172, 31, 180, 69, 154, 116, 137, 10, 228, 12, 80, 183, 199, 254, 132, 206, 105,
79, 222, 49, 219, 63, 109, 58, 68, 154, 33, 154, 247, 97, 217, 129, 168, 238, 114, 41, 23, 60, 96, 154, 53, 48, 109,
51, 214, 92, 131, 176, 113, 120, 238, 186, 220, 187, 249, 209, 49, 202, 45, 189, 145, 86, 207, 226, 8, 215, 10, 198,
86, 147, 112, 144, 21, 156, 197, 21, 103, 191, 15, 69, 16, 254, 95, 152, 17, 114, 62, 178, 215, 191, 50, 219, 173,
117, 142, 48, 0, 138, 121, 248, 134, 84, 168, 110, 44, 9, 233, 194, 125, 85, 177, 9, 200, 47, 29, 68, 45, 23, 103,
221, 30, 245, 238, 188, 243, 234, 122, 125, 152, 15, 122, 98, 60, 4, 120, 254, 130, 126, 251, 165, 15, 191, 58, 251,
127, 227, 94, 102, 22, 10, 218, 245, 149, 141, 128, 103, 188, 217, 143, 62, 89, 97, 89, 142, 69, 251, 26, 254, 38,
12, 207, 14, 233, 153, 170, 143, 111, 171, 100, 152, 93, 176, 220, 89, 96, 223, 102, 130, 103, 132, 159, 66, 81,
168, 204, 44, 214, 27, 138, 240, 16, 34, 129, 100, 156, 119, 161, 123, 34, 114, 155, 194, 180, 144, 59, 205, 211,
197, 230, 217, 105, 177, 99, 174, 59, 20, 68, 13, 151, 18, 223, 245, 119, 67, 255, 94, 175, 60, 23, 87, 241, 251,
79, 80, 175, 196, 67, 156, 55, 71, 225, 13, 171, 69, 13, 76, 34, 151, 221, 99, 15, 87, 32, 103, 229, 88, 200, 85,
163, 182, 212, 31, 157, 7, 156, 106, 126, 153, 167, 121, 196, 104, 130, 83, 80, 138, 95, 139, 33, 92, 156, 38, 231,
127, 130, 120, 93, 238, 146, 37, 35, 46, 215, 94, 186, 145, 178, 121, 183, 6, 56, 177, 229, 143, 102, 130, 119, 159,
167, 178, 80, 89, 134, 84, 157, 59, 137, 43, 8, 195, 198, 143, 62, 45, 38, 175, 57, 100, 91, 27, 213, 135, 46, 225,
197, 153, 31, 62, 246, 203, 242, 47, 131, 31, 164, 193, 17, 6, 238, 0, 151, 114, 47, 84, 205, 99, 17, 254, 245, 193,
231, 233, 230, 179, 43, 248, 232, 89, 231, 32, 248, 219, 42, 31, 74, 65, 234, 118, 16, 146, 142, 56, 254, 77, 126,
64, 118, 80, 249, 224, 167, 159, 67, 18, 171, 37, 147, 89, 116, 72, 68, 115, 135, 69, 138, 78, 220, 57, 69, 123,
217, 166, 138, 214, 173, 143, 94, 220, 31, 34, 74, 80, 173, 3, 221, 213, 81, 83, 148, 235, 84, 180, 93, 127, 212,
97, 142, 85, 251, 187, 8, 239, 225, 94, 179, 155, 186, 196, 166, 61, 153, 232, 10, 255, 109, 165, 8, 94, 238, 143,
146, 136, 215, 28, 173, 136, 210, 182, 162, 40, 139, 144, 105, 204, 81, 110, 38, 204, 83, 75, 229, 216, 115, 184,
242, 105, 186, 219, 146, 200, 124, 23, 186, 213, 92, 93, 171, 141, 240, 112, 79, 95, 171, 120, 95, 223, 108, 116,
117, 28, 6, 8, 94, 253, 143, 83, 91, 174, 234, 6, 200, 5, 249, 197, 225, 147, 165, 58, 122, 241, 178, 207, 208, 66,
255, 237, 7, 144, 126, 130, 58, 115, 15, 53, 75, 250, 130, 163, 138, 1, 49, 204, 133, 85, 65, 62, 23, 178, 221, 155,
225, 55, 236, 222, 224, 53, 5, 40, 35, 15, 100, 13, 55, 79, 52, 62, 87, 178, 237, 219, 5, 110, 96, 60, 137, 152,
161, 128, 199, 123, 58, 19, 82, 103, 86, 122, 20, 248, 245, 176, 109, 3, 148, 61, 185, 74, 84, 123, 233, 244, 83,
243, 62, 203, 159, 150, 220, 73, 138, 164, 147, 243, 238, 83, 111, 201, 14, 48, 43, 229, 96, 223, 200, 215, 216,
155, 187, 1, 40, 127, 154, 211, 34, 2, 202, 121, 74, 25, 172, 183, 68, 170, 175, 122, 67, 119, 67, 251, 157, 2, 16,
111, 14, 78, 99, 172, 64, 143, 246, 246, 145, 45, 188, 242, 41, 42, 131, 16, 189, 184, 30, 41, 124, 114, 185, 18,
77, 219, 28, 202, 199, 113, 168, 3, 97, 215, 238, 182, 1, 180, 47, 122, 17, 144, 82, 136, 12, 65, 230, 157, 184, 62,
249, 180, 162, 60, 66, 100, 67, 85, 235, 100, 137, 108, 37, 248, 169, 162, 104, 233, 202, 12, 129, 9, 162, 183, 229,
65, 203, 245, 239, 51, 121, 111, 187, 13, 131, 44, 101, 8, 166, 77, 50, 191, 188, 85, 31, 32, 244, 100, 83, 228, 15,
232, 195, 215, 176, 29, 29, 242, 142, 168, 212, 42, 44, 30, 65, 204, 153, 235, 61, 203, 56, 158, 217, 139, 110, 44,
141, 46, 124, 126, 77, 203, 148, 104, 113, 43, 232, 87, 194, 147, 65, 113, 107, 168, 126, 78, 119, 91, 78, 201, 75,
128, 65, 210, 31, 196, 210, 222, 85, 242, 222, 18, 189, 210, 254, 145, 105, 196, 188, 186, 42, 155, 54, 122, 199,
16, 104, 45, 162, 53, 238, 137, 165, 16, 83, 120, 162, 165, 1, 194, 127, 209, 198, 181, 227, 76, 61, 238, 112, 194,
36, 36, 38, 67, 249, 34, 131, 27, 114, 100, 50, 202, 195, 133, 189, 200, 226, 163, 217, 122, 58, 131, 147, 52, 186,
172, 64, 204, 150, 33, 37, 164, 246, 133, 80, 61, 146, 203, 167, 38, 32, 30, 119, 56, 129, 48, 124, 7, 247, 136, 27,
228, 202, 186, 221, 54, 120, 229, 57, 94, 116, 211, 63, 134, 30, 85, 226, 23, 161, 24, 213, 5, 6, 200, 48, 216, 222,
165, 250, 195, 38, 84, 123, 208, 198, 215, 211, 220, 185, 68, 124, 37, 240, 46, 76, 58, 169, 43, 89, 198, 210, 8,
178, 226, 114, 49, 80, 178, 169, 137, 53, 56, 13, 124, 181, 74, 202, 80, 96, 219, 150, 224, 255, 236, 58, 145, 143,
60, 142, 61, 156, 193, 69, 18, 196, 135, 214, 96, 239, 114, 4, 54, 116, 229, 169, 45, 145, 227, 47, 92, 62, 183,
222, 71, 187, 208, 146, 234, 195, 161, 113, 9, 133, 117, 166, 167, 26, 32, 154, 82, 98, 69, 86, 104, 160, 24, 47,
64, 221, 61, 204, 228, 57, 25, 204, 35, 207, 251, 173, 56, 174, 22, 168, 44, 144, 51, 52, 180, 98, 88, 251, 220,
132, 45, 103, 182, 253, 131, 112, 16, 78, 165, 187, 103, 18, 178, 232, 57, 48, 65, 193, 239, 71, 33, 75, 26, 9, 165,
171, 155, 53, 215, 119, 85, 222, 12, 254, 190, 255, 59, 146, 144, 142, 204, 38, 19, 247, 18, 57, 231, 194, 30, 235,
202, 175, 177, 102, 132, 146, 52, 142, 16, 156, 218, 45, 147, 44, 209, 71, 99, 23, 37, 123, 142, 97, 173, 247, 196,
27, 185, 6, 198, 148, 79, 139, 216, 224, 171, 56, 27, 174, 225, 217, 62, 144, 45, 161, 246, 215, 16, 40, 109, 254,
125, 201, 80, 47, 173, 50, 13, 2, 22, 18, 182, 173, 155, 109, 192, 87, 138, 13, 81, 172, 4, 162, 205, 3, 222, 41,
113, 40, 24, 161, 207, 180, 43, 20, 131, 15, 14, 238, 34, 28, 97, 112, 65, 19, 219, 110, 163, 69, 189, 52, 19, 63,
174, 146, 84, 145, 146, 8, 156, 180, 63, 45, 85, 244, 85, 117, 17, 239, 254, 147, 31, 190, 164, 146, 210, 72, 200,
61, 129, 249, 224, 120, 51, 8, 199, 218, 188, 203, 186, 227, 59, 47, 237, 219, 245, 58, 218, 80, 55, 199, 200, 22,
210, 87, 71, 111, 4, 212, 134, 182, 22, 211, 128, 76, 146, 85, 241, 62, 148, 104, 203, 170, 181, 206, 85, 51, 61,
156, 25, 202, 225, 135, 163, 185, 225, 87, 141, 99, 69, 189, 73, 76, 95, 195, 33, 51, 112, 98, 126, 16, 83, 178,
200, 129, 64, 179, 13, 118, 229, 56, 118, 185, 123, 211, 224, 96, 94, 23, 189, 81, 221, 1, 53, 161, 165, 12, 77, 12,
58, 21, 191, 234, 21, 91, 95, 75, 110, 47, 123, 77, 240, 97, 244, 118, 98, 74, 234, 75, 91, 145, 65, 110, 82, 113,
43, 164, 213, 92, 32, 58, 99, 11, 251, 44, 186, 198, 14, 141, 119, 6, 210, 155, 149, 31, 95, 146, 69, 84, 79, 225,
188, 35, 104, 251, 144, 246, 223, 50, 26, 96, 72, 142, 120, 167, 46, 221, 176, 122, 16, 218, 61, 140, 35, 60, 222,
202, 147, 124, 140, 66, 182, 198, 158, 250, 183, 233, 129, 92, 186, 130, 254, 55, 24, 118, 134, 63, 196, 134, 183,
86, 92, 51, 107, 93, 229, 179, 16, 208, 10, 98, 175, 180, 31, 137, 81, 198, 185, 3, 171, 194, 246, 221, 117, 217,
239, 105, 227, 56, 131, 61, 177, 15, 210, 155, 62, 147, 225, 218, 183, 165, 0, 57, 197, 210, 1, 157, 142, 247, 212,
101, 225, 152, 228, 131, 144, 142, 112, 211, 243, 113, 110, 149, 15, 115, 65, 49, 136, 199, 222, 46, 60, 2, 50, 47,
32, 159, 113, 157, 169, 128, 220, 82, 51, 82, 77, 243, 54, 203, 121, 225, 40, 140, 207, 76, 135, 48, 61, 24, 82, 56,
122, 232, 216, 173, 225, 168, 100, 249, 199, 138, 91, 240, 151, 200, 238, 53, 1, 36, 118, 184, 187, 11, 16, 95, 56,
133, 211, 145, 98, 44, 47, 244, 19, 161, 92, 42, 178, 131, 109, 14, 83, 249, 166, 161, 24, 116, 165, 139, 219, 165,
26, 122, 214, 190, 238, 218, 71, 91, 143, 233, 157, 40, 225, 111, 130, 225, 245, 254, 147, 28, 154, 198, 158, 167,
67, 181, 225, 120, 177, 195, 52, 211, 149, 240, 125, 242, 134, 31, 171, 108, 17, 45, 69, 163, 146, 18, 211, 32, 89,
13, 85, 88, 218, 170, 225, 151, 220, 117, 59, 26, 63, 218, 113, 112, 144, 142, 179, 2, 84, 85, 69, 215, 35, 182, 46,
57, 51, 7, 37, 66, 7, 91, 5, 97, 223, 49, 79, 172, 183, 121, 214, 214, 77, 152, 124, 10, 73, 167, 195, 39, 96, 120,
114, 152, 246, 143, 43, 202, 28, 222, 7, 1, 82, 134, 112, 18, 47, 136, 55, 237, 137, 73, 135, 88, 150, 102, 88, 204,
204, 222, 253, 124, 198, 36, 86, 60, 231, 234, 158, 150, 101, 188, 127, 96, 132, 70, 221, 12, 154, 114, 230, 225,
251, 230, 246, 51, 199, 236, 7, 202, 46, 12, 11, 214, 200, 202, 62, 225, 217, 77, 60, 106, 187, 36, 18, 223, 141,
20, 216, 78, 207, 32, 20, 30, 142, 182, 128, 60, 58, 199, 248, 203, 193, 254, 188, 23, 171, 223, 61, 192, 65, 229,
72, 80, 194, 160, 106, 40, 33, 187, 17, 197, 241, 218, 243, 223, 22, 46, 212, 233, 92, 204, 213, 74, 108, 80, 127,
162, 125, 128, 24, 204, 127, 207, 165, 145, 12, 172, 122, 189, 55, 221, 76, 222, 160, 247, 111, 195, 178, 196, 9,
112, 3, 129, 65, 218, 49, 230, 78, 135, 122, 150, 200, 5, 79, 183, 10, 163, 162, 205, 129, 55, 200, 2, 85, 190, 93,
218, 95, 10, 45, 5, 14, 3, 166, 226, 143, 141, 250, 230, 102, 142, 234, 194, 246, 247, 32, 108, 46, 96, 111, 8, 92,
189, 136, 190, 62, 50, 182, 178, 126, 212, 176, 209, 140, 109, 83, 175, 238, 56, 243, 26, 85, 71, 89, 59, 24, 234,
97, 211, 241, 241, 157, 36, 145, 206, 78, 71, 162, 238, 49, 6, 130, 172, 116, 66, 199, 71, 89, 8, 112, 142, 26, 22,
112, 59, 34, 89, 229, 250, 126, 85, 177, 218, 57, 225, 232, 224, 22, 135, 147, 79, 13, 216, 138, 167, 71, 66, 200,
153, 46, 50, 187, 7, 247, 141, 221, 181, 22, 58, 0, 83, 165, 33, 73, 123, 13, 240, 188, 197, 191, 148, 75, 5, 208,
69, 12, 199, 2, 31, 199, 97, 1, 239, 26, 106, 56, 103, 197, 229, 137, 57, 209, 232, 24, 141, 249, 177, 56, 36, 59,
243, 115, 241, 158, 114, 79, 193, 72, 151, 2, 248, 225, 159, 205, 225, 122, 64, 161, 175, 124, 11, 71, 143, 239,
155, 63, 38, 111, 237, 31, 231, 247, 6, 190, 39, 253, 143, 169, 178, 85, 172, 47, 10, 170, 128, 140, 220, 6, 85,
204, 76, 36, 91, 151, 178, 83, 135, 145, 254, 113, 24, 161, 195, 225, 48, 124, 162, 136, 140, 168, 232, 99, 64, 115,
203, 10, 6, 204, 128, 131, 6, 48, 245, 108, 208, 35, 22, 216, 200, 55, 212, 189, 25, 29, 210, 48, 27, 176, 10, 202,
16, 209, 85, 90, 175, 179, 249, 231, 183, 145, 252, 83, 91, 248, 201, 35, 148, 51, 124, 145, 57, 34, 205, 226, 251,
101, 221, 99, 196, 103, 59, 171, 76, 242, 139, 157, 127, 8, 149, 72, 179, 73, 34, 242, 112, 16, 162, 214, 232, 174,
103, 167, 232, 243, 160, 55, 42, 188, 30, 56, 147, 40, 239, 65, 225, 203, 31, 76, 109, 213, 121, 123, 23, 131, 191,
22, 193, 167, 5, 88, 129, 79, 69, 174, 111, 169, 203, 213, 51, 175, 160, 123, 147, 12, 166, 49, 211, 199, 227, 123,
212, 147, 97, 12, 124, 15, 152, 234, 134, 201, 185, 207, 45, 161, 60, 181, 36, 205, 29, 180, 27, 172, 237, 236, 138,
211, 38, 187, 11, 81, 94, 75, 160, 6, 218, 10, 186, 109, 83, 84, 47, 220, 110, 33, 216, 51, 229, 58, 16, 146, 217,
183, 75, 155, 233, 160, 200, 200, 166, 167, 182, 189, 59, 155, 40, 80, 194, 0, 130, 166, 165, 93, 149, 37, 101, 214,
27, 211, 161, 76, 164, 10, 164, 191, 244, 80, 243, 122, 188, 123, 30, 92, 89, 134, 185, 27, 138, 103, 107, 51, 81,
49, 45, 84, 136, 200, 76, 14, 252, 208, 30, 84, 233, 30, 15, 153, 26, 35, 243, 172, 165, 15, 230, 226, 173, 63, 238,
182, 42, 23, 28, 212, 156, 119, 249, 146, 217, 56, 93, 63, 42, 194, 161, 251, 80, 211, 82, 10, 255, 154, 104, 190,
216, 141, 70, 64, 16, 169, 100, 160, 243, 134, 38, 196, 222, 138, 164, 63, 27, 49, 83, 42, 57, 147, 191, 167, 127,
244, 195, 142, 218, 98, 220, 7, 231, 229, 94, 0, 79, 218, 238, 102, 144, 86, 140, 248, 172, 228, 228, 113, 1, 149,
248, 252, 233, 150, 170, 67, 83, 232, 205, 161, 9, 251, 96, 173, 10, 202, 211, 3, 12, 77, 111, 73, 217, 149, 182,
143, 176, 151, 99, 58, 52, 72, 63, 25, 42, 226, 52, 131, 80, 103, 177, 163, 12, 210, 89, 174, 172, 161, 88, 31, 66,
232, 19, 170, 177, 171, 87, 55, 221, 104, 92, 148, 140, 234, 149, 132, 190, 5, 234, 202, 191, 48, 179, 98, 80, 102,
245, 63, 122, 34, 244, 105, 247, 58, 109, 28, 113, 17, 65, 2, 14, 46, 163, 20, 6, 160, 62, 206, 211, 178, 147, 171,
249, 14, 51, 76, 69, 211, 173, 56, 44, 118, 217, 24, 21, 55, 63, 126, 204, 212, 138, 210, 49, 27, 59, 64, 31, 209,
40, 37, 69, 14, 188, 172, 148, 208, 56, 211, 184, 194, 180, 37, 26, 90, 212, 220, 101, 215, 154, 17, 162, 101, 23,
170, 96, 176, 23, 227, 134, 128, 55, 207, 12, 11, 214, 241, 233, 88, 7, 183, 214, 9, 205, 84, 86, 61, 230, 245, 31,
238, 37, 27, 166, 115, 154, 190, 57, 204, 31, 196, 142, 160, 158, 209, 2, 156, 167, 17, 99, 78, 228, 211, 111, 88,
195, 6, 192, 224, 95, 210, 178, 110, 185, 34, 188, 54, 241, 141, 244, 65, 98, 75, 98, 3, 253, 142, 123, 197, 108,
200, 26, 247, 155, 59, 97, 95, 145, 9, 185, 191, 32, 47, 228, 144, 135, 236, 106, 184, 233, 199, 107, 185, 222, 116,
42, 93, 78, 134, 35, 64, 111, 224, 120, 229, 18, 187, 70, 143, 226, 232, 86, 119, 101, 17, 253, 202, 135, 80, 90,
82, 93, 192, 162, 184, 246, 193, 52, 54, 3, 170, 196, 162, 208, 84, 201, 92, 205, 113, 140, 178, 3, 89, 36, 160,
211, 209, 145, 107, 206, 19, 118, 14, 135, 113, 13, 6, 240, 77, 58, 104, 63, 53, 4, 198, 107, 74, 61, 178, 78, 136,
209, 63, 109, 55, 118, 188, 204, 232, 99, 6, 148, 230, 121, 196, 137, 93, 82, 128, 23, 140, 48, 47, 240, 237, 86,
33, 153, 102, 213, 40, 178, 191, 104, 66, 15, 45, 209, 225, 0, 214, 124, 89, 86, 124, 187, 23, 29, 155, 241, 132,
41, 211, 202, 79, 75, 250, 37, 222, 159, 97, 71, 59, 176, 59, 20, 211, 211, 56, 156, 129, 188, 135, 238, 111, 4, 78,
149, 56, 133, 132, 246, 54, 94, 109, 72, 255, 112, 84, 31, 102, 75, 127, 162, 130, 143, 205, 245, 0, 233, 148, 27,
244, 68, 181, 64, 190, 213, 229, 211, 133, 230, 178, 141, 151, 233, 66, 215, 1, 42, 133, 11, 117, 132, 27, 100, 206,
182, 112, 198, 68, 3, 134, 10, 49, 16, 4, 69, 218, 4, 206, 139, 217, 243, 11, 149, 81, 173, 22, 66, 191, 54, 177,
34, 44, 87, 22, 247, 178, 36, 48, 13, 205, 44, 185, 222, 38, 163, 27, 210, 88, 25, 45, 217, 208, 195, 226, 241, 63,
142, 18, 145, 168, 245, 29, 181, 53, 90, 232, 161, 148, 133, 227, 47, 30, 249, 76, 206, 252, 58, 182, 184, 53, 75,
127, 248, 250, 140, 232, 252, 77, 163, 135, 169, 153, 52, 86, 64, 104, 146, 30, 206, 53, 209, 172, 243, 19, 78, 77,
146, 195, 41, 73, 152, 232, 136, 65, 116, 177, 96, 44, 176, 52, 204, 247, 1, 250, 235, 112, 98, 253, 91, 109, 97,
144, 185, 192, 24, 255, 147, 40, 14, 57, 117, 255, 95, 205, 95, 158, 45, 30, 111, 96, 86, 116, 92, 28, 73, 226, 188,
231, 103, 99, 40, 210, 188, 27, 38, 124, 247, 249, 156, 116, 138, 173, 106, 21, 203, 109, 45, 127, 160, 80, 107,
204, 12, 230, 218, 206, 86, 163, 164, 130, 44, 230, 66, 128, 250, 245, 129, 33, 129, 136, 189, 237, 103, 208, 237,
230, 179, 227, 150, 234, 251, 144, 150, 237, 42, 149, 226, 175, 132, 207, 94, 191, 24, 48, 224, 180, 210, 219, 158,
12, 244, 40, 241, 43, 16, 88, 6, 31, 254, 237, 249, 207, 181, 97, 80, 125, 82, 6, 64, 150, 236, 244, 34, 11, 64,
205, 121, 111, 159, 119, 220, 53, 133, 196, 131, 183, 209, 13, 250, 197, 6, 228, 37, 91, 46, 37, 160, 128, 232, 118,
129, 66, 28, 127, 18, 158, 123, 242, 163, 37, 208, 195, 52, 136, 189, 91, 190, 24, 63, 25, 73, 49, 31, 202, 124, 85,
75, 99, 46, 29, 225, 247, 169, 254, 41, 212, 5, 41, 51, 174, 35, 32, 73, 152, 131, 27, 5, 106, 246, 186, 173, 248,
139, 83, 122, 202, 121, 217, 26, 6, 248, 245, 129, 200, 34, 204, 34, 23, 88, 111, 71, 58, 12, 50, 168, 117, 51, 50,
47, 71, 230, 114, 26, 127, 17, 186, 254, 171, 89, 7, 126, 26, 19, 62, 51, 49, 217, 192, 173, 92, 232, 96, 173, 76,
204, 178, 73, 60, 104, 173, 92, 191, 223, 70, 133, 41, 229, 13, 105, 28, 169, 157, 17, 137, 255, 33, 73, 4, 106,
186, 193, 169, 215, 224, 93, 12, 201, 137, 141, 79, 49, 188, 66, 51, 79, 221, 163, 149, 60, 4, 30, 32, 108, 187,
235, 83, 93, 242, 112, 231, 94, 171, 185, 211, 218, 97, 232, 69, 54, 160, 117, 90, 213, 53, 79, 208, 120, 25, 80,
30, 179, 95, 240, 157, 171, 173, 189, 80, 50, 252, 2, 124, 7, 76, 121, 60, 236, 17, 143, 33, 209, 169, 52, 148, 54,
59, 72, 203, 7, 250, 138, 182, 23, 255, 78, 86, 17, 106, 123, 8, 43, 181, 92, 249, 43, 96, 160, 245, 28, 239, 28,
243, 111, 28, 85, 100, 67, 37, 58, 32, 126, 130, 17, 226, 131, 3, 159, 42, 145, 162, 166, 87, 155, 22, 63, 5, 30,
212, 80, 153, 78, 27, 12, 45, 193, 187, 32, 200, 43, 1, 253, 117, 23, 136, 105, 39, 23, 51, 47, 131, 61, 182, 167,
222, 145, 155, 211, 108, 186, 149, 154, 148, 16, 180, 74, 251, 79, 251, 225, 19, 60, 237, 180, 194, 170, 161, 121,
32, 193, 81, 0, 230, 124, 30, 151, 138, 214, 182, 66, 215, 123, 10, 130, 157, 221, 52, 200, 200, 123, 28, 206, 23,
225, 233, 70, 241, 180, 127, 77, 227, 48, 249, 70, 172, 110, 223, 56, 182, 132, 36, 134, 21, 239, 237, 57, 114, 251,
7, 250, 180, 114, 27, 39, 18, 0, 136, 62, 84, 15, 197, 157, 34, 41, 173, 160, 61, 157, 231, 63, 56, 167, 113, 192,
44, 19, 28, 153, 20, 89, 25, 95, 52, 183, 153, 75, 242, 187, 57, 173, 63, 30, 209, 229, 71, 69, 171, 181, 105, 40,
99, 146, 226, 137, 49, 129, 109, 133, 27, 169, 80, 211, 140, 62, 197, 7, 149, 143, 27, 45, 52, 7, 27, 90, 28, 238,
70, 149, 179, 112, 89, 71, 136, 186, 154, 41, 67, 8, 201, 24, 119, 92, 246, 24, 51, 83, 247, 187, 177, 178, 121, 28,
17, 122, 62, 64, 111, 99, 31, 175, 94, 48, 7, 78, 164, 21, 195, 115, 70, 213, 228, 228, 254, 84, 204, 167, 177, 34,
151, 244, 133, 156, 145, 230, 131, 112, 103, 90, 41, 164, 140, 75, 195, 177, 15, 83, 134, 203, 64, 74, 156, 87, 207,
14, 101, 135, 251, 69, 18, 251, 190, 29, 32, 168, 175, 47, 92, 170, 218, 152, 222, 166, 62, 53, 10, 50, 111, 228,
86, 198, 174, 203, 179, 14, 29, 250, 79, 174, 233, 5, 109, 105, 41, 131, 159, 3, 122, 228, 203, 184, 7, 147, 39,
128, 253, 87, 147, 37, 143, 253, 2, 248, 171, 96, 216, 93, 1, 242, 86, 13, 61, 161, 88, 68, 89, 211, 251, 95, 30,
202, 160, 42, 17, 62, 207, 24, 124, 151, 214, 182, 2, 238, 120, 85, 12, 218, 132, 182, 235, 29, 28, 150, 106, 86,
147, 213, 50, 129, 42, 246, 9, 23, 233, 157, 117, 209, 32, 18, 255, 53, 135, 26, 86, 139, 118, 252, 168, 41, 200,
188, 38, 1, 53, 43, 142, 220, 37, 215, 51, 125, 194, 225, 222, 98, 63, 206, 1, 160, 253, 11, 192, 123, 139, 106,
204, 87, 250, 181, 187, 27, 200, 190, 20, 37, 236, 122, 204, 191, 102, 57, 110, 179, 98, 115, 226, 39, 27, 138, 70,
83, 118, 56, 181, 87, 81, 209, 122, 39, 130, 194, 200, 91, 112, 215, 27, 18, 29, 196, 151, 242, 182, 140, 65, 127,
115, 56, 67, 104, 154, 112, 201, 65, 139, 150, 34, 49, 25, 182, 201, 68, 50, 100, 213, 253, 36, 203, 166, 245, 154,
65, 72, 98, 95, 202, 250, 214, 55, 138, 157, 97, 155, 5, 50, 162, 3, 106, 204, 51, 105, 183, 159, 163, 102, 198,
174, 130, 95, 12, 208, 107, 136, 1, 25, 251, 247, 29, 29, 111, 216, 249, 43, 67, 73, 225, 250, 116, 222, 158, 13,
56, 15, 231, 99, 201, 3, 12, 120, 1, 30, 30, 255, 31, 212, 114, 106, 5, 88, 196, 236, 110, 108, 221, 126, 201, 32,
105, 176, 27, 204, 231, 24, 195, 65, 198, 32, 235, 106, 253, 130, 212, 162, 59, 84, 123, 90, 238, 137, 137, 40, 12,
171, 20, 126, 124, 119, 174, 163, 68, 67, 106, 102, 69, 67, 193, 2, 176, 221, 128, 255, 224, 226, 136, 33, 226, 156,
57, 71, 50, 188, 209, 110, 102, 54, 174, 78, 75, 153, 69, 92, 24, 52, 1, 102, 90, 113, 105, 120, 7, 224, 171, 93,
45, 38, 135, 223, 17, 62, 195, 197, 141, 197, 30, 93, 40, 142, 134, 74, 234, 125, 112, 232, 81, 141, 245, 95, 118,
125, 125, 79, 57, 16, 187, 113, 64, 47, 19, 189, 247, 177, 236, 201, 37, 183, 194, 201, 47, 196, 50, 174, 198, 64,
181, 244, 201, 140, 235, 134, 132, 9, 253, 161, 198, 136, 75, 198, 82, 39, 230, 167, 135, 233, 175, 70, 174, 85,
203, 42, 78, 173, 77, 249, 53, 238, 101, 76, 175, 38, 149, 102, 76, 189, 156, 37, 69, 185, 99, 80, 155, 180, 242,
211, 168, 215, 95, 107, 94, 125, 156, 58, 229, 83, 98, 118, 201, 64, 56, 24, 22, 218, 178, 146, 94, 126, 7, 251,
223, 106, 28, 93, 239, 232, 128, 199, 225, 105, 225, 25, 12, 251, 205, 36, 142, 152, 214, 163, 80, 200, 132, 140,
157, 143, 78, 142, 94, 167, 25, 61, 8, 12, 226, 29, 46, 69, 66, 243, 24, 50, 165, 5, 63, 82, 125, 231, 98, 176, 16,
47, 231, 254, 218, 119, 130, 185, 143, 229, 221, 21, 220, 214, 243, 168, 11, 230, 67, 82, 114, 39, 167, 243, 228,
128, 244, 214, 75, 64, 131, 69, 94, 185, 17, 32, 122, 226, 245, 19, 134, 50, 8, 152, 185, 25, 203, 58, 87, 178, 61,
255, 221, 168, 77, 0, 156, 154, 131, 247, 70, 181, 99, 180, 163, 220, 78, 181, 174, 40, 25, 87, 129, 122, 84, 164,
78, 43, 119, 60, 127, 24, 125, 55, 232, 130, 12, 218, 13, 104, 27, 226, 181, 12, 71, 119, 168, 185, 252, 160, 0,
183, 130, 210, 220, 193, 122, 47, 248, 174, 192, 126, 50, 18, 71, 78, 65, 223, 16, 198, 67, 101, 198, 81, 235, 164,
99, 26, 85, 21, 134, 72, 184, 131, 167, 192, 188, 215, 156, 15, 191, 22, 106, 233, 208, 91, 104, 112, 219, 178, 157,
210, 228, 140, 10, 238, 28, 238, 250, 173, 85, 69, 138, 198, 26, 176, 78, 212, 89, 132, 83, 183, 102, 58, 152, 41,
169, 46, 177, 135, 99, 105, 206, 21, 28, 66, 254, 93, 232, 144, 32, 100, 8, 160, 222, 203, 98, 115, 133, 194, 38,
76, 9, 248, 26, 77, 1, 24, 14, 147, 157, 113, 141, 237, 119, 219, 15, 98, 236, 228, 42, 8, 200, 86, 10, 139, 118,
39, 222, 145, 71, 248, 38, 201, 118, 88, 13, 16, 152, 69, 218, 115, 50, 50, 117, 20, 73, 206, 10, 14, 229, 247, 186,
134, 240, 167, 118, 230, 40, 16, 87, 113, 109, 132, 191, 109, 64, 155, 180, 110, 134, 22, 53, 51, 72, 194, 65, 221,
35, 138, 145, 6, 199, 71, 253, 129, 1, 29, 48, 23, 128, 85, 227, 3, 111, 246, 224, 81, 210, 244, 146, 17, 56, 93,
59, 188, 142, 45, 187, 121, 160, 172, 133, 133, 221, 239, 214, 138, 205, 133, 219, 105, 68, 8, 29, 46, 131, 130,
231, 117, 64, 125, 133, 41, 208, 149, 191, 231, 77, 151, 217, 179, 171, 213, 171, 101, 233, 34, 230, 77, 12, 141,
229, 251, 95, 201, 54, 124, 234, 150, 48, 250, 53, 122, 85, 237, 151, 236, 86, 31, 184, 79, 145, 5, 176, 184, 175,
163, 8, 188, 89, 158, 239, 213, 78, 23, 135, 64, 201, 134, 188, 45, 176, 160, 196, 188, 231, 208, 191, 76, 86, 58,
235, 130, 175, 8, 157, 190, 56, 253, 71, 156, 88, 163, 134, 39, 74, 180, 2, 215, 96, 138, 165, 179, 119, 90, 184,
179, 37, 47, 207, 11, 38, 133, 98, 146, 43, 171, 33, 18, 226, 56, 144, 149, 2, 135, 237, 115, 165, 232, 163, 243,
47, 209, 190, 113, 89, 127, 90, 244, 100, 40, 250, 176, 11, 175, 117, 161, 26, 167, 25, 104, 26, 247, 245, 188, 78,
200, 218, 210, 200, 16, 64, 97, 150, 135, 101, 133, 24, 92, 18, 108, 224, 9, 113, 201, 202, 100, 137, 181, 222, 5,
175, 231, 244, 126, 33, 245, 104, 222, 245, 50, 15, 163, 142, 195, 86, 49, 165, 69, 230, 5, 235, 175, 200, 191, 245,
113, 98, 138, 132, 34, 48, 0, 158, 200, 252, 236, 157, 25, 209, 90, 238, 54, 81, 205, 81, 39, 182, 170, 137, 163,
43, 239, 81, 7, 214, 4, 222, 97, 152, 84, 84, 172, 1, 117, 187, 108, 98, 216, 85, 220, 64, 18, 173, 250, 118, 76,
100, 28, 151, 18, 182, 145, 155, 164, 135, 1, 208, 195, 171, 34, 168, 189, 252, 201, 114, 194, 236, 180, 36, 80, 28,
0, 90, 147, 60, 200, 169, 173, 148, 84, 7, 96, 79, 126, 184, 33, 211, 229, 99, 190, 217, 95, 164, 175, 99, 15, 251,
52, 182, 150, 61, 203, 108, 52, 52, 116, 136, 112, 203, 33, 58, 155, 15, 201, 104, 108, 153, 52, 233, 181, 93, 77,
161, 242, 130, 192, 7, 4, 112, 12, 1, 178, 27, 10, 193, 153, 111, 209, 70, 205, 144, 106, 106, 62, 86, 186, 78, 152,
242, 33, 182, 113, 29, 221, 54, 234, 173, 130, 221, 244, 74, 101, 148, 83, 209, 140, 210, 216, 245, 148, 26, 120,
204, 189, 63, 41, 181, 119, 217, 63, 29, 23, 214, 119, 22, 164, 188, 97, 139, 168, 218, 137, 144, 255, 161, 211,
137, 208, 229, 200, 76, 252, 227, 210, 153, 154, 180, 69, 9, 28, 158, 41, 82, 79, 249, 21, 117, 247, 69, 29, 181,
96, 205, 94, 244, 244, 63, 15, 168, 247, 0, 52, 144, 5, 43, 34, 168, 101, 61, 222, 82, 193, 3, 227, 152, 59, 250,
113, 201, 200, 41, 54, 145, 168, 241, 36, 47, 175, 11, 169, 81, 168, 240, 2, 194, 109, 89, 113, 123, 77, 236, 46,
108, 23, 221, 242, 151, 28, 248, 63, 2, 108, 34, 24, 43, 224, 79, 82, 114, 63, 112, 249, 112, 83, 134, 129, 225,
131, 122, 134, 116, 141, 160, 84, 102, 139, 216, 230, 191, 71, 62, 117, 117, 160, 41, 5, 53, 194, 227, 18, 238, 72,
245, 166, 17, 176, 85, 116, 72, 63, 189, 186, 55, 150, 22, 61, 167, 191, 47, 209, 27, 99, 109, 238, 163, 132, 2,
237, 170, 94, 249, 89, 183, 73, 175, 158, 3, 132, 86, 86, 41, 189, 84, 16, 151, 229, 96, 40, 57, 231, 221, 24, 205,
183, 216, 117, 182, 202, 86, 206, 52, 87, 102, 9, 7, 249, 250, 52, 135, 143, 213, 174, 87, 86, 3, 161, 18, 228, 153,
5, 100, 76, 16, 110, 17, 194, 77, 169, 235, 69, 88, 95, 107, 108, 55, 144, 204, 107, 20, 30, 232, 80, 76, 22, 217,
140, 124, 153, 210, 227, 225, 43, 222, 161, 219, 180, 225, 126, 54, 42, 65, 214, 124, 183, 234, 38, 126, 71, 69,
108, 171, 104, 153, 111, 78, 32, 195, 25, 64, 80, 105, 12, 221, 184, 104, 218, 40, 31, 76, 91, 216, 134, 171, 196,
11, 40, 222, 65, 117, 194, 217, 46, 3, 52, 196, 45, 12, 115, 76, 185, 16, 87, 128, 231, 146, 236, 146, 247, 183,
122, 41, 23, 31, 189, 131, 74, 183, 157, 65, 153, 211, 111, 101, 153, 226, 195, 23, 141, 244, 83, 111, 170, 202,
227, 10, 164, 102, 234, 211, 6, 48, 158, 122, 250, 154, 7, 43, 220, 88, 184, 120, 73, 221, 227, 52, 158, 2, 251, 20,
62, 55, 247, 160, 203, 10, 179, 187, 145, 120, 231, 14, 86, 217, 164, 100, 188, 55, 81, 114, 154, 142, 181, 181, 83,
223, 93, 68, 246, 192, 198, 74, 14, 182, 128, 185, 230, 187, 90, 1, 100, 103, 210, 132, 167, 225, 158, 234, 230, 26,
211, 68, 138, 1, 166, 65, 201, 38, 178, 214, 249, 170, 249, 69, 9, 127, 139, 198, 118, 119, 59, 58, 250, 146, 199,
223, 247, 38, 77, 38, 29, 198, 33, 203, 44, 69, 165, 188, 193, 243, 231, 119, 244, 186, 229, 99, 215, 1, 225, 33,
98, 144, 27, 217, 102, 81, 193, 164, 19, 21, 197, 174, 179, 217, 88, 88, 169, 25, 206, 234, 205, 244, 125, 246, 217,
91, 116, 107, 55, 243, 72, 199, 185, 3, 185, 213, 41, 75, 59, 140, 185, 127, 0, 183, 181, 38, 97, 69, 244, 243, 138,
111, 190, 250, 82, 180, 55, 153, 63, 157, 92, 209, 101, 75, 0, 74, 67, 155, 205, 52, 140, 56, 29, 69, 74, 1, 207,
61, 232, 164, 83, 218, 142, 227, 61, 207, 65, 61, 30, 220, 231, 72, 175, 168, 211, 38, 16, 85, 1, 98, 225, 134, 144,
215, 251, 142, 163, 41, 21, 131, 237, 10, 127, 11, 1, 108, 2, 167, 12, 80, 5, 150, 85, 171, 183, 84, 250, 236, 157,
250, 1, 44, 239, 30, 150, 137, 50, 131, 171, 127, 133, 140, 55, 2, 23, 86, 106, 212, 50, 122, 45, 134, 251, 163, 92,
106, 186, 69, 136, 85, 121, 113, 226, 239, 212, 27, 197, 61, 103, 198, 49, 35, 5, 252, 180, 227, 205, 111, 27, 143,
55, 153, 123, 77, 209, 151, 112, 228, 45, 18, 164, 26, 27, 138, 55, 206, 107, 140, 73, 68, 4, 236, 154, 3, 40, 236,
236, 19, 189, 105, 249, 162, 128, 95, 50, 144, 108, 208, 236, 222, 211, 228, 90, 53, 120, 58, 137, 67, 96, 238, 122,
230, 110, 80, 23, 250, 42, 107, 62, 51, 145, 174, 219, 121, 11, 174, 68, 249, 241, 119, 144, 134, 133, 127, 90, 67,
152, 210, 84, 160, 182, 203, 206, 18, 174, 109, 166, 226, 146, 130, 175, 197, 241, 75, 29, 14, 133, 75, 254, 214,
92, 46, 20, 98, 188, 92, 49, 172, 137, 118, 174, 109, 212, 158, 225, 40, 186, 249, 172, 58, 44, 146, 123, 111, 75,
94, 46, 210, 16, 175, 209, 102, 14, 209, 97, 39, 174, 96, 4, 68, 255, 166, 160, 132, 141, 59, 184, 93, 124, 165,
131, 249, 163, 9, 154, 169, 114, 183, 138, 240, 121, 242, 34, 124, 253, 235, 207, 18, 185, 97, 192, 229, 211, 248,
125, 66, 151, 183, 129, 143, 86, 67, 148, 76, 95, 143, 93, 18, 178, 196, 87, 131, 248, 247, 58, 182, 251, 1, 81, 28,
188, 14, 39, 217, 164, 235, 33, 106, 77, 127, 15, 157, 66, 127, 252, 37, 25, 197, 169, 193, 1, 238, 216, 21, 150,
91, 7, 144, 140, 153, 28, 91, 197, 70, 161, 42, 117, 50, 131, 230, 225, 6, 183, 223, 105, 137, 36, 229, 18, 199, 3,
132, 11, 111, 34, 52, 225, 164, 143, 124, 105, 83, 64, 155, 73, 240, 138, 130, 203, 216, 29, 99, 244, 58, 80, 22,
199, 18, 251, 79, 105, 73, 139, 173, 247, 46, 28, 149, 217, 196, 36, 177, 75, 248, 5, 101, 60, 83, 121, 118, 14,
201, 78, 196, 107, 153, 98, 106, 188, 80, 206, 78, 55, 241, 34, 48, 131, 141, 114, 116, 40, 251, 235, 83, 181, 187,
63, 95, 167, 44, 52, 74, 103, 67, 137, 224, 184, 238, 248, 106, 167, 216, 203, 209, 192, 162, 252, 75, 138, 187,
241, 138, 126, 126, 216, 26, 200, 129, 170, 163, 130, 226, 193, 89, 18, 19, 119, 72, 98, 83, 4, 237, 95, 99, 230,
99, 19, 252, 29, 22, 76, 194, 88, 40, 199, 180, 27, 204, 110, 76, 107, 241, 137, 21, 178, 160, 214, 165, 229, 8,
102, 54, 111, 26, 30, 14, 97, 199, 135, 210, 215, 158, 132, 9, 125, 94, 19, 206, 170, 50, 243, 212, 180, 105, 65,
32, 128, 230, 74, 3, 215, 21, 129, 207, 80, 58, 105, 88, 146, 39, 88, 42, 34, 130, 5, 96, 67, 19, 76, 104, 28, 44,
163, 185, 201, 22, 222, 243, 76, 45, 197, 196, 37, 116, 255, 201, 122, 255, 224, 141, 69, 137, 63, 181, 246, 20,
249, 34, 32, 82, 39, 48, 123, 22, 164, 2, 224, 36, 191, 136, 107, 132, 36, 187, 99, 61, 115, 178, 128, 68, 25, 189,
1, 82, 125, 60, 54, 140, 125, 177, 133, 126, 229, 253, 216, 147, 235, 159, 15, 34, 93, 149, 193, 22, 181, 74, 168,
193, 29, 107, 129, 6, 59, 199, 250, 179, 193, 30, 172, 3, 198, 171, 195, 68, 75, 241, 96, 196, 69, 124, 128, 184,
233, 118, 143, 158, 57, 185, 92, 121, 210, 89, 226, 63, 170, 203, 112, 129, 114, 203, 158, 139, 174, 18, 151, 94,
96, 254, 95, 82, 8, 14, 185, 182, 185, 37, 232, 236, 247, 86, 54, 97, 38, 211, 93, 225, 201, 43, 126, 131, 206, 194,
86, 121, 45, 68, 167, 90, 143, 42, 29, 227, 242, 112, 236, 1, 85, 205, 134, 6, 204, 166, 60, 136, 95, 117, 170, 227,
242, 96, 207, 145, 43, 221, 139, 198, 77, 28, 88, 138, 117, 148, 103, 83, 241, 255, 42, 37, 0, 7, 190, 88, 2, 156,
227, 121, 229, 161, 178, 45, 120, 108, 196, 4, 210, 140, 190, 161, 46, 159, 44, 184, 144, 200, 0, 140, 165, 83, 197,
21, 72, 220, 182, 101, 48, 121, 203, 200, 216, 89, 193, 48, 158, 148, 183, 75, 234, 245, 132, 57, 131, 248, 91, 80,
241, 76, 12, 88, 202, 227, 223, 33, 249, 100, 175, 8, 250, 237, 46, 17, 180, 55, 0, 30, 51, 101, 8, 8, 202, 82, 234,
15, 53, 81, 27, 180, 11, 98, 101, 188, 138, 140, 238, 243, 90, 97, 35, 133, 155, 152, 43, 147, 163, 74, 34, 72, 130,
55, 39, 206, 32, 86, 107, 112, 106, 69, 105, 104, 39, 65, 89, 9, 246, 45, 136, 98, 39, 4, 36, 111, 249, 39, 71, 76,
232, 143, 76, 140, 161, 32, 30, 206, 94, 34, 220, 156, 128, 44, 244, 79, 226, 23, 46, 98, 123, 35, 138, 221, 1, 198,
253, 117, 197, 51, 160, 146, 177, 14, 250, 80, 81, 168, 242, 172, 143, 246, 222, 65, 141, 140, 24, 119, 68, 24, 7,
139, 72, 146, 28, 140, 158, 192, 211, 87, 147, 87, 105, 99, 33, 136, 212, 70, 62, 182, 243, 202, 140, 75, 36, 65,
148, 92, 133, 254, 191, 196, 124, 236, 108, 117, 184, 35, 56, 59, 236, 205, 55, 146, 134, 103, 115, 47, 108, 160,
124, 4, 20, 86, 75, 154, 160, 34, 131, 220, 202, 40, 133, 19, 248, 157, 141, 224, 137, 79, 77, 112, 2, 110, 112,
193, 99, 159, 211, 70, 175, 142, 166, 77, 107, 220, 74, 109, 25, 108, 152, 134, 155, 255, 78, 179, 216, 59, 158,
226, 100, 37, 83, 69, 143, 91, 96, 77, 109, 96, 205, 207, 47, 185, 206, 211, 137, 223, 211, 52, 156, 117, 179, 255,
202, 209, 37, 131, 252, 78, 36, 67, 75, 152, 229, 28, 156, 0, 18, 51, 242, 2, 211, 23, 16, 9, 242, 0, 246, 91, 173,
228, 241, 166, 0, 136, 111, 54, 45, 248, 12, 12, 53, 47, 230, 219, 97, 22, 203, 75, 43, 11, 220, 92, 114, 144, 33,
235, 185, 115, 148, 223, 20, 137, 178, 0, 164, 139, 52, 46, 5, 149, 60, 36, 180, 39, 60, 102, 177, 19, 162, 42, 61,
216, 205, 165, 156, 50, 104, 59, 18, 37, 22, 7, 111, 101, 71, 228, 100, 95, 25, 254, 241, 18, 101, 128, 75, 5, 94,
115, 216, 41, 133, 223, 15, 67, 43, 54, 210, 34, 137, 21, 232, 201, 24, 84, 129, 87, 120, 9, 15, 82, 74, 147, 140,
170, 167, 151, 74, 100, 30, 199, 225, 113, 31, 141, 83, 161, 125, 25, 238, 155, 249, 161, 234, 10, 221, 146, 98,
239, 121, 236, 150, 100, 96, 51, 142, 220, 243, 219, 52, 65, 151, 92, 105, 172, 121, 142, 11, 156, 50, 95, 95, 168,
230, 80, 44, 213, 241, 118, 128, 95, 146, 230, 200, 40, 9, 215, 78, 53, 88, 94, 200, 237, 109, 0, 85, 147, 23, 174,
218, 169, 239, 91, 130, 11, 142, 201, 104, 119, 29, 5, 75, 205, 164, 71, 49, 185, 83, 255, 60, 195, 224, 55, 30,
130, 240, 147, 227, 253, 182, 233, 249, 83, 251, 94, 15, 115, 60, 30, 250, 2, 85, 211, 60, 45, 38, 207, 4, 201, 96,
9, 105, 77, 200, 216, 23, 89, 235, 175, 220, 70, 175, 224, 3, 12, 233, 156, 39, 171, 250, 206, 69, 245, 175, 200,
222, 158, 184, 230, 241, 210, 140, 191, 67, 53, 216, 103, 138, 89, 88, 151, 37, 166, 110, 57, 120, 225, 224, 57,
223, 201, 182, 136, 23, 35, 46, 231, 23, 87, 171, 192, 11, 247, 46, 77, 196, 218, 102, 72, 142, 43, 56, 187, 115,
76, 23, 100, 163, 134, 80, 243, 1, 81, 96, 3, 67, 223, 37, 225, 188, 243, 188, 140, 139, 8, 14, 1, 254, 230, 193,
108, 91, 195, 254, 27, 197, 201, 224, 189, 220, 158, 240, 170, 177, 143, 25, 186, 8, 109, 1, 153, 45, 126, 115, 7,
23, 105, 236, 142, 52, 215, 230, 55, 107, 175, 161, 34, 95, 172, 33, 246, 166, 251, 8, 221, 119, 16, 238, 185, 206,
185, 180, 25, 76, 60, 60, 14, 79, 54, 86, 220, 115, 190, 181, 160, 125, 75, 98, 163, 179, 225, 211, 148, 246, 33,
159, 222, 48, 156, 211, 58, 39, 4, 143, 250, 224, 77, 59, 140, 238, 182, 161, 193, 171, 156, 46, 35, 105, 121, 240,
67, 93, 225, 140, 86, 211, 96, 84, 95, 240, 67, 33, 213, 226, 147, 94, 27, 183, 129, 251, 252, 167, 151, 214, 70,
186, 144, 59, 167, 63, 190, 220, 34, 28, 2, 181, 244, 139, 110, 235, 90, 150, 232, 20, 91, 136, 234, 234, 205, 18,
26, 64, 96, 76, 66, 190, 179, 17, 126, 206, 20, 84, 126, 214, 198, 128, 147, 94, 108, 142, 179, 225, 162, 52, 232,
0, 248, 174, 245, 85, 184, 176, 179, 72, 127, 98, 154, 165, 139, 181, 10, 254, 173, 208, 22, 155, 214, 203, 107,
171, 55, 188, 94, 150, 237, 105, 194, 92, 24, 174, 127, 84, 16, 75, 235, 210, 212, 50, 235, 99, 136, 99, 121, 141,
96, 216, 227, 206, 205, 254, 112, 185, 165, 54, 71, 11, 177, 125, 126, 30, 80, 247, 157, 251, 36, 252, 66, 38, 219,
32, 244, 15, 124, 26, 234, 192, 122, 234, 243, 175, 207, 77, 209, 227, 91, 51, 39, 164, 1, 171, 255, 159, 185, 255,
145, 240, 49, 165, 148, 72, 68, 109, 188, 214, 249, 190, 223, 66, 22, 20, 171, 52, 68, 148, 17, 97, 144, 11, 134,
31, 148, 69, 30, 60, 53, 193, 13, 160, 33, 221, 88, 235, 97, 132, 76, 123, 152, 76, 225, 54, 165, 8, 16, 104, 43,
87, 115, 56, 75, 201, 80, 189, 80, 175, 92, 84, 91, 146, 230, 192, 87, 50, 164, 222, 135, 150, 141, 127, 153, 206,
146, 63, 67, 11, 37, 0, 46, 222, 109, 219, 32, 161, 124, 210, 236, 141, 200, 229, 212, 202, 185, 133, 211, 101, 124,
79, 189, 24, 12, 209, 187, 125, 174, 139, 169, 204, 108, 38, 183, 163, 168, 206, 205, 200, 46, 26, 247, 187, 115,
166, 148, 196, 84, 189, 255, 82, 193, 134, 189, 172, 83, 38, 17, 73, 42, 220, 229, 13, 84, 79, 33, 18, 34, 16, 8,
165, 204, 190, 250, 197, 173, 80, 188, 123, 6, 207, 108, 106, 218, 15, 18, 2, 174, 199, 244, 117, 253, 174, 33, 61,
184, 130, 229, 106, 111, 130, 31, 112, 202, 106, 122, 92, 229, 229, 130, 25, 187, 13, 244, 130, 140, 236, 183, 72,
166, 209, 35, 32, 21, 73, 105, 148, 29, 56, 172, 237, 47, 78, 1, 171, 206, 253, 197, 153, 71, 67, 40, 206, 113, 77,
255, 8, 240, 184, 159, 87, 88, 39, 247, 202, 40, 154, 100, 48, 182, 41, 253, 219, 152, 210, 132, 247, 7, 149, 164,
132, 76, 67, 32, 253, 58, 120, 166, 194, 9, 119, 75, 139, 149, 252, 193, 139, 244, 1, 154, 77, 9, 185, 152, 246,
254, 178, 200, 212, 241, 146, 45, 121, 60, 199, 146, 97, 107, 147, 232, 17, 217, 239, 202, 146, 165, 145, 109, 152,
195, 226, 37, 29, 39, 17, 122, 247, 0, 165, 124, 102, 73, 150, 201, 87, 89, 42, 245, 224, 160, 69, 207, 250, 138,
28, 133, 152, 86, 221, 92, 202, 47, 241, 250, 122, 123, 245, 45, 47, 27, 15, 128, 229, 140, 186, 242, 52, 142, 22,
60, 192, 209, 137, 141, 150, 227, 21, 85, 178, 244, 221, 104, 0, 0, 159, 184, 135, 98, 153, 121, 173, 152, 196, 119,
204, 89, 126, 247, 64, 24, 152, 85, 91, 36, 148, 11, 153, 205, 129, 138, 204, 21, 117, 15, 50, 171, 211, 103, 165,
76, 22, 119, 181, 66, 100, 64, 254, 251, 146, 175, 11, 229, 238, 147, 83, 219, 91, 79, 175, 243, 24, 15, 180, 91,
106, 254, 43, 241, 87, 84, 19, 203, 196, 65, 188, 188, 193, 128, 68, 231, 233, 197, 177, 250, 55, 23, 251, 97, 61,
149, 115, 63, 15, 13, 101, 67, 214, 69, 89, 157, 6, 113, 19, 101, 58, 251, 42, 8, 75, 43, 95, 232, 144, 72, 27, 188,
127, 149, 154, 123, 86, 244, 104, 43, 55, 15, 124, 176, 142, 210, 3, 52, 35, 172, 12, 35, 128, 255, 129, 83, 127,
205, 59, 74, 99, 221, 128, 139, 225, 170, 131, 185, 108, 59, 165, 189, 220, 83, 132, 154, 133, 212, 146, 45, 241,
69, 118, 210, 184, 162, 6, 176, 33, 96, 251, 31, 170, 9, 68, 237, 68, 157, 141, 128, 123, 0, 236, 15, 196, 228, 210,
225, 239, 233, 35, 78, 149, 100, 171, 66, 133, 1, 6, 0, 122, 179, 214, 34, 182, 233, 69, 69, 116, 229, 205, 17, 176,
212, 19, 5, 2, 215, 132, 221, 199, 169, 82, 25, 51, 69, 122, 71, 73, 78, 20, 21, 170, 77, 68, 148, 53, 92, 29, 63,
243, 142, 182, 57, 86, 111, 253, 152, 71, 35, 166, 144, 158, 34, 30, 162, 122, 26, 191, 20, 220, 194, 175, 129, 139,
178, 95, 228, 53, 85, 68, 168, 226, 148, 74, 54, 26, 41, 85, 24, 153, 110, 186, 137, 198, 2, 202, 30, 115, 139, 197,
17, 171, 200, 13, 68, 53, 121, 97, 118, 64, 242, 158, 10, 1, 74, 121, 5, 70, 2, 238, 77, 53, 147, 21, 76, 232, 100,
123, 138, 232, 220, 74, 171, 98, 38, 181, 118, 225, 186, 165, 12, 13, 113, 94, 244, 255, 53, 120, 68, 84, 148, 10,
202, 82, 250, 14, 241, 74, 45, 226, 238, 207, 10, 41, 114, 209, 179, 113, 14, 61, 156, 86, 41, 215, 29, 228, 195,
76, 123, 190, 136, 246, 208, 104, 221, 241, 76, 123, 146, 39, 243, 42, 57, 85, 11, 139, 127, 131, 104, 211, 154,
183, 221, 238, 84, 131, 13, 101, 126, 157, 47, 13, 191, 226, 76, 226, 16, 56, 126, 209, 28, 199, 10, 128, 88, 247,
55, 82, 115, 91, 4, 104, 234, 134, 24, 175, 237, 23, 125, 80, 51, 29, 144, 144, 5, 216, 13, 9, 128, 119, 47, 113,
106, 39, 126, 69, 225, 93, 95, 36, 234, 158, 8, 168, 237, 155, 246, 183, 190, 234, 212, 149, 137, 192, 126, 126,
178, 128, 125, 34, 147, 185, 71, 166, 49, 172, 13, 223, 11, 221, 27, 47, 35, 61, 135, 52, 145, 93, 138, 128, 184,
58, 11, 151, 178, 196, 159, 90, 236, 224, 11, 153, 163, 88, 218, 189, 225, 22, 142, 177, 232, 4, 251, 38, 238, 97,
124, 3, 215, 17, 222, 132, 55, 184, 61, 238, 253, 40, 60, 26, 108, 106, 158, 86, 154, 3, 251, 162, 185, 6, 94, 96,
3, 251, 167, 242, 182, 160, 140, 195, 171, 239, 235, 187, 76, 147, 233, 253, 220, 27, 90, 103, 76, 126, 5, 252, 241,
68, 162, 202, 71, 34, 119, 69, 81, 145, 102, 83, 32, 180, 71, 142, 136, 112, 169, 41, 185, 129, 44, 121, 132, 145,
182, 251, 124, 196, 255, 177, 16, 239, 42, 103, 203, 11, 112, 218, 32, 130, 11, 164, 22, 23, 142, 150, 158, 175,
220, 78, 9, 176, 60, 89, 240, 90, 248, 23, 57, 56, 34, 169, 164, 180, 130, 95, 125, 234, 59, 59, 44, 1, 227, 88, 5,
102, 9, 35, 110, 191, 32, 37, 230, 254, 186, 114, 153, 253, 25, 204, 199, 15, 99, 196, 70, 31, 109, 31, 23, 57, 29,
59, 31, 209, 225, 198, 95, 106, 216, 18, 27, 119, 146, 107, 85, 152, 90, 142, 24, 155, 247, 79, 130, 108, 29, 117,
85, 54, 20, 22, 75, 114, 113, 184, 108, 151, 10, 210, 59, 24, 170, 238, 100, 136, 254, 124, 88, 195, 28, 251, 25,
35, 87, 186, 140, 109, 29, 85, 98, 175, 1, 0, 223, 124, 104, 75, 155, 87, 220, 168, 191, 36, 137, 47, 3, 2, 193, 53,
73, 229, 152, 48, 101, 34, 206, 124, 2, 130, 123, 151, 15, 53, 102, 57, 127, 49, 63, 36, 121, 165, 47, 241, 151,
182, 95, 141, 65, 30, 119, 234, 193, 114, 97, 52, 44, 191, 63, 66, 91, 43, 29, 130, 148, 5, 4, 21, 121, 212, 44,
218, 1, 200, 58, 77, 210, 232, 236, 23, 157, 64, 127, 141, 2, 223, 215, 226, 150, 79, 207, 117, 124, 89, 239, 243,
38, 106, 238, 118, 144, 112, 151, 7, 65, 117, 123, 20, 81, 214, 16, 57, 38, 231, 61, 15, 71, 222, 85, 178, 218, 111,
108, 21, 222, 8, 159, 76, 221, 46, 124, 17, 239, 160, 41, 138, 250, 189, 171, 178, 189, 98, 76, 115, 219, 241, 140,
170, 183, 77, 242, 90, 239, 31, 118, 232, 4, 220, 68, 125, 24, 42, 227, 115, 253, 154, 35, 62, 61, 239, 113, 152,
138, 127, 16, 217, 61, 107, 176, 9, 170, 123, 197, 10, 155, 154, 173, 225, 30, 60, 229, 216, 85, 206, 157, 214, 224,
80, 191, 20, 152, 212, 97, 63, 229, 161, 44, 159, 91, 204, 207, 45, 223, 186, 21, 153, 233, 55, 241, 188, 5, 213,
88, 53, 232, 57, 3, 70, 136, 72, 170, 37, 137, 98, 182, 145, 153, 165, 53, 156, 88, 161, 32, 88, 232, 195, 253, 229,
55, 123, 237, 232, 183, 43, 120, 126, 137, 15, 205, 202, 27, 89, 214, 236, 50, 41, 179, 161, 89, 238, 61, 174, 7,
244, 229, 126, 109, 200, 190, 94, 164, 252, 156, 114, 207, 89, 160, 168, 12, 105, 158, 78, 72, 122, 170, 241, 182,
173, 75, 34, 6, 116, 111, 179, 246, 28, 73, 103, 58, 110, 183, 149, 239, 176, 89, 98, 35, 62, 146, 122, 189, 189,
37, 34, 201, 179, 155, 175, 1, 69, 246, 4, 103, 152, 239, 77, 75, 79, 138, 27, 165, 167, 205, 50, 254, 245, 126,
219, 112, 49, 149, 34, 237, 217, 24, 224, 191, 12, 139, 192, 36, 4, 26, 9, 84, 158, 220, 216, 39, 82, 121, 114, 194,
214, 239, 136, 127, 24, 236, 11, 16, 156, 178, 155, 244, 99, 148, 140, 54, 244, 158, 102, 56, 41, 202, 4, 157, 182,
182, 71, 175, 226, 2, 3, 8, 231, 57, 242, 47, 16, 162, 78, 59, 186, 93, 138, 77, 126, 48, 202, 211, 229, 83, 227,
225, 199, 22, 212, 101, 184, 240, 134, 205, 50, 48, 244, 60, 13, 133, 114, 176, 90, 138, 231, 216, 230, 122, 148,
64, 188, 9, 238, 86, 113, 129, 240, 245, 126, 22, 64, 188, 241, 116, 160, 63, 60, 171, 137, 14, 83, 239, 225, 252,
43, 61, 57, 115, 27, 46, 98, 222, 191, 189, 80, 207, 198, 14, 87, 158, 111, 140, 228, 110, 40, 231, 33, 88, 57, 51,
3, 169, 169, 6, 34, 9, 48, 177, 185, 81, 92, 137, 197, 228, 241, 254, 75, 77, 110, 143, 118, 39, 20, 213, 158, 190,
60, 148, 105, 204, 88, 217, 240, 48, 210, 109, 136, 234, 71, 230, 86, 88, 196, 211, 38, 217, 78, 223, 226, 57, 237,
94, 217, 165, 148, 40, 110, 248, 156, 247, 241, 250, 85, 22, 72, 223, 45, 79, 2, 253, 160, 111, 241, 22, 0, 184, 26,
96, 255, 46, 248, 6, 137, 250, 122, 215, 158, 40, 247, 83, 4, 1, 166, 98, 160, 16, 92, 85, 59, 176, 251, 144, 109,
149, 121, 175, 66, 16, 35, 76, 166, 58, 242, 235, 43, 180, 165, 186, 102, 145, 95, 81, 193, 39, 222, 210, 27, 221,
56, 8, 99, 35, 97, 230, 70, 194, 165, 207, 90, 78, 191, 206, 107, 173, 95, 191, 222, 98, 141, 38, 228, 219, 10, 201,
53, 118, 200, 251, 58, 200, 119, 1, 28, 156, 42, 33, 123, 147, 84, 169, 110, 127, 245, 151, 111, 252, 182, 170, 27,
25, 102, 92, 184, 222, 183, 56, 175, 214, 10, 226, 47, 107, 219, 217, 1, 42, 178, 220, 217, 122, 98, 132, 249, 174,
249, 224, 3, 228, 181, 102, 140, 138, 187, 149, 114, 121, 53, 230, 245, 246, 156, 159, 150, 134, 174, 105, 193, 147,
18, 132, 105, 53, 198, 20, 147, 198, 57, 112, 153, 62, 182, 92, 201, 69, 246, 109, 41, 104, 202, 16, 243, 9, 34,
211, 245, 251, 172, 249, 177, 141, 116, 225, 63, 218, 40, 115, 187, 72, 13, 60, 52, 25, 241, 116, 199, 211, 110, 3,
29, 218, 202, 54, 222, 94, 238, 28, 167, 81, 157, 164, 207, 62, 221, 128, 8, 33, 42, 14, 236, 39, 161, 29, 245, 168,
58, 63, 46, 173, 158, 203, 34, 208, 100, 25, 249, 184, 17, 120, 23, 186, 50, 120, 228, 175, 14, 141, 93, 163, 19,
97, 149, 255, 184, 183, 250, 138, 28, 234, 40, 144, 214, 225, 161, 206, 188, 218, 78, 52, 127, 254, 230, 14, 26,
230, 26, 142, 140, 233, 207, 185, 104, 95, 208, 82, 249, 100, 70, 224, 130, 145, 85, 30, 65, 28, 105, 19, 66, 123,
184, 195, 55, 168, 87, 69, 73, 246, 144, 97, 156, 98, 233, 211, 20, 164, 82, 152, 205, 184, 249, 122, 53, 194, 153,
129, 11, 116, 165, 170, 116, 24, 48, 115, 151, 255, 59, 14, 167, 43, 169, 174, 85, 161, 127, 16, 35, 54, 31, 71,
209, 32, 17, 71, 138, 55, 26, 8, 198, 188, 79, 251, 40, 97, 123, 189, 7, 89, 63, 250, 214, 106, 212, 146, 130, 106,
53, 13, 87, 44, 145, 171, 112, 245, 220, 166, 129, 200, 59, 118, 171, 72, 22, 105, 163, 14, 136, 163, 38, 185, 242,
112, 196, 92, 61, 223, 118, 107, 241, 110, 126, 182, 11, 3, 192, 125, 77, 108, 182, 68, 60, 125, 32, 254, 167, 179,
57, 87, 179, 241, 73, 199, 85, 254, 133, 119, 16, 236, 129, 220, 120, 5, 243, 141, 100, 17, 228, 0, 134, 118, 120,
225, 171, 67, 236, 235, 235, 87, 75, 251, 163, 40, 100, 158, 165, 128, 70, 0, 126, 28, 184, 131, 153, 152, 99, 1,
123, 151, 85, 130, 202, 141, 65, 186, 187, 1, 18, 195, 59, 199, 219, 254, 121, 41, 161, 51, 17, 116, 178, 201, 83,
63, 94, 115, 91, 56, 25, 4, 125, 205, 253, 168, 183, 3, 49, 196, 110, 12, 101, 211, 32, 179, 16, 103, 41, 112, 184,
167, 213, 176, 26, 211, 240, 200, 180, 169, 14, 62, 103, 148, 118, 83, 136, 142, 7, 172, 43, 18, 246, 12, 103, 133,
215, 147, 63, 79, 174, 98, 78, 42, 119, 26, 234, 151, 124, 163, 126, 23, 116, 14, 160, 209, 51, 211, 24, 23, 182,
142, 57, 22, 191, 5, 189, 141, 255, 160, 39, 24, 205, 17, 221, 140, 166, 97, 237, 246, 119, 96, 117, 207, 178, 149,
136, 209, 181, 156, 30, 1, 150, 136, 22, 231, 10, 254, 133, 84, 130, 228, 11, 89, 29, 91, 63, 120, 86, 57, 161, 84,
211, 122, 123, 12, 237, 227, 237, 237, 178, 169, 127, 174, 114, 115, 208, 1, 10, 25, 197, 231, 92, 221, 143, 184,
15, 118, 145, 234, 242, 11, 132, 126, 41, 197, 208, 8, 82, 184, 83, 124, 251, 87, 24, 222, 23, 40, 236, 191, 88,
144, 40, 146, 53, 86, 193, 186, 80, 118, 174, 26, 144, 11, 48, 249, 175, 241, 160, 1, 77, 142, 250, 150, 224, 79,
130, 187, 164, 175, 27, 150, 191, 243, 196, 109, 219, 54, 227, 31, 68, 15, 62, 149, 73, 211, 124, 167, 30, 204, 215,
154, 43, 117, 41, 94, 223, 145, 130, 155, 23, 62, 217, 114, 251, 37, 94, 48, 21, 48, 46, 114, 167, 118, 185, 42,
119, 72, 128, 82, 77, 156, 167, 201, 49, 180, 149, 173, 94, 83, 160, 30, 41, 8, 148, 16, 52, 175, 177, 218, 214, 22,
83, 147, 164, 197, 130, 241, 9, 118, 91, 114, 52, 61, 69, 66, 244, 54, 99, 97, 210, 207, 242, 71, 92, 5, 21, 88,
244, 206, 163, 142, 67, 196, 36, 126, 65, 158, 211, 249, 147, 101, 234, 139, 74, 190, 13, 0, 189, 19, 233, 131, 131,
138, 121, 139, 104, 52, 204, 164, 199, 177, 87, 39, 110, 61, 54, 64, 212, 92, 47, 55, 225, 44, 192, 181, 118, 220,
74, 36, 29, 51, 173, 137, 35, 188, 233, 107, 40, 59, 102, 236, 220, 184, 60, 93, 20, 232, 125, 102, 22, 83, 25, 43,
76, 72, 189, 183, 193, 255, 109, 199, 36, 83, 148, 156, 73, 223, 195, 95, 31, 112, 120, 46, 59, 192, 103, 177, 239,
12, 118, 147, 28, 62, 139, 254, 61, 224, 105, 9, 126, 132, 229, 24, 76, 164, 28, 22, 89, 123, 163, 213, 227, 191,
132, 220, 157, 130, 128, 108, 23, 164, 110, 8, 193, 220, 184, 241, 34, 253, 227, 132, 82, 43, 14, 187, 128, 158,
240, 25, 49, 73, 245, 126, 109, 68, 93, 148, 36, 67, 147, 160, 218, 32, 180, 140, 39, 55, 144, 39, 91, 88, 192, 45,
97, 182, 208, 108, 89, 137, 12, 31, 158, 254, 221, 10, 43, 49, 200, 173, 221, 115, 22, 27, 255, 177, 5, 208, 224, 8,
155, 120, 119, 134, 218, 172, 99, 130, 160, 26, 252, 47, 193, 177, 109, 29, 232, 12, 60, 205, 217, 7, 196, 9, 38,
82, 84, 184, 233, 113, 45, 92, 109, 54, 178, 133, 23, 159, 120, 131, 125, 5, 191, 164, 203, 63, 54, 8, 252, 232,
252, 44, 156, 112, 57, 17, 202, 121, 49, 164, 127, 114, 80, 199, 237, 1, 180, 33, 147, 247, 204, 140, 214, 12, 126,
157, 248, 2, 31, 197, 183, 247, 122, 50, 231, 184, 238, 124, 162, 101, 49, 190, 216, 66, 105, 181, 215, 178, 129,
100, 167, 95, 14, 55, 235, 113, 147, 182, 141, 124, 247, 213, 213, 72, 177, 254, 25, 78, 26, 239, 253, 109, 136, 62,
238, 148, 62, 9, 227, 103, 221, 89, 25, 182, 36, 112, 130, 41, 238, 191, 121, 118, 155, 170, 60, 194, 48, 239, 173,
94, 201, 5, 62, 47, 5, 45, 244, 170, 63, 90, 91, 69, 59, 130, 225, 217, 117, 223, 190, 41, 26, 119, 170, 175, 20,
50, 174, 116, 139, 193, 123, 37, 164, 31, 14, 46, 171, 80, 114, 50, 154, 230, 126, 116, 134, 16, 9, 18, 4, 10, 213,
43, 220, 171, 130, 205, 88, 185, 179, 88, 40, 132, 226, 174, 118, 9, 240, 178, 48, 59, 4, 23, 81, 189, 35, 40, 224,
90, 193, 8, 242, 120, 234, 101, 40, 83, 162, 254, 101, 118, 93, 120, 206, 143, 171, 2, 127, 255, 56, 70, 183, 254,
114, 98, 219, 224, 159, 55, 206, 165, 214, 145, 88, 232, 122, 216, 184, 96, 113, 31, 17, 38, 37, 101, 49, 73, 136,
218, 251, 196, 255, 60, 77, 97, 54, 94, 126, 60, 51, 204, 106, 193, 40, 230, 34, 26, 84, 242, 221, 32, 188, 26, 135,
141, 210, 91, 174, 35, 117, 56, 72, 128, 170, 238, 29, 170, 92, 97, 34, 221, 17, 54, 74, 117, 84, 209, 34, 240, 190,
205, 55, 177, 99, 140, 134, 95, 252, 32, 80, 30, 31, 34, 61, 178, 206, 244, 218, 192, 2, 117, 162, 71, 87, 185, 16,
182, 102, 41, 74, 186, 160, 85, 184, 126, 47, 67, 29, 230, 145, 33, 223, 230, 5, 57, 41, 171, 47, 216, 211, 113,
184, 251, 36, 67, 213, 126, 107, 105, 104, 32, 76, 232, 201, 53, 210, 126, 226, 213, 97, 140, 47, 130, 65, 31, 127,
135, 204, 25, 6, 44, 81, 216, 27, 212, 229, 169, 87, 160, 229, 240, 231, 253, 15, 36, 40, 190, 236, 165, 146, 234,
89, 190, 19, 145, 139, 242, 42, 85, 78, 134, 40, 186, 196, 85, 133, 155, 133, 129, 48, 160, 159, 119, 104, 63, 134,
209, 17, 57, 127, 8, 148, 72, 104, 134, 108, 65, 29, 245, 252, 149, 238, 233, 148, 31, 245, 139, 40, 197, 94, 234,
27, 48, 222, 232, 89, 80, 242, 68, 45, 138, 133, 188, 220, 46, 11, 101, 79, 242, 232, 126, 152, 53, 190, 83, 2, 151,
164, 214, 57, 142, 23, 167, 239, 132, 136, 9, 80, 77, 123, 127, 70, 59, 82, 180, 131, 177, 130, 102, 98, 119, 0,
175, 187, 109, 74, 37, 33, 0, 150, 226, 203, 111, 17, 168, 37, 58, 252, 254, 15, 53, 210, 156, 128, 132, 186, 36,
248, 227, 94, 173, 90, 137, 125, 191, 129, 247, 1, 45, 159, 127, 38, 179, 206, 177, 132, 208, 4, 107, 240, 155, 104,
85, 190, 24, 225, 63, 194, 168, 137, 189, 1, 108, 239, 228, 108, 146, 77, 38, 204, 150, 155, 214, 252, 171, 84, 6,
203, 126, 107, 237, 10, 230, 112, 190, 119, 179, 5, 32, 132, 132, 198, 164, 108, 178, 63, 118, 190, 73, 48, 195,
196, 32, 178, 49, 16, 61, 169, 79, 47, 95, 200, 83, 103, 128, 197, 77, 74, 167, 16, 132, 94, 57, 198, 87, 237, 229,
109, 151, 236, 6, 3, 183, 253, 18, 44, 34, 71, 113, 119, 102, 59, 170, 242, 16, 193, 145, 1, 43, 115, 222, 33, 196,
42, 60, 75, 154, 216, 197, 27, 47, 185, 162, 2, 54, 189, 37, 44, 85, 53, 28, 82, 31, 97, 116, 121, 254, 119, 217,
76, 232, 41, 88, 250, 151, 124, 122, 68, 99, 46, 117, 47, 132, 16, 66, 148, 82, 112, 18, 248, 233, 144, 251, 108,
62, 68, 30, 156, 232, 229, 65, 127, 202, 25, 77, 213, 42, 186, 9, 215, 245, 23, 204, 213, 155, 163, 50, 122, 181,
75, 18, 79, 226, 36, 29, 58, 229, 85, 123, 90, 145, 62, 94, 137, 35, 254, 155, 15, 246, 83, 6, 8, 248, 153, 56, 64,
113, 224, 80, 91, 93, 200, 44, 252, 40, 50, 164, 83, 196, 151, 72, 30, 216, 34, 145, 85, 243, 32, 254, 143, 78, 2,
71, 62, 189, 239, 107, 92, 43, 45, 73, 212, 107, 63, 95, 172, 131, 22, 62, 227, 167, 44, 227, 84, 71, 31, 12, 222,
195, 93, 135, 211, 163, 176, 213, 155, 46, 52, 56, 70, 216, 199, 186, 33, 124, 10, 111, 95, 133, 45, 178, 181, 139,
10, 105, 235, 239, 93, 30, 160, 79, 125, 143, 81, 143, 4, 202, 84, 205, 27, 107, 248, 103, 12, 82, 180, 112, 157,
25, 33, 101, 255, 134, 48, 132, 236, 247, 222, 104, 94, 177, 179, 56, 125, 121, 18, 213, 238, 83, 4, 183, 49, 153,
70, 30, 234, 229, 201, 46, 37, 98, 130, 106, 66, 54, 79, 226, 62, 177, 158, 50, 125, 155, 44, 154, 152, 133, 1, 131,
186, 91, 49, 241, 225, 33, 150, 188, 70, 195, 160, 155, 188, 79, 67, 124, 56, 42, 235, 97, 222, 38, 230, 81, 22,
118, 125, 68, 160, 60, 136, 161, 169, 118, 131, 215, 92, 255, 16, 55, 86, 122, 159, 136, 228, 210, 85, 33, 221, 210,
50, 190, 6, 18, 182, 237, 110, 190, 15, 173, 52, 54, 189, 162, 160, 210, 183, 130, 227, 176, 203, 239, 69, 156, 225,
81, 38, 70, 203, 141, 211, 39, 119, 86, 113, 104, 116, 190, 64, 48, 121, 181, 37, 25, 2, 77, 59, 65, 113, 210, 162,
73, 122, 28, 88, 92, 162, 192, 201, 210, 197, 90, 193, 9, 107, 113, 51, 164, 205, 191, 145, 232, 118, 246, 160, 1,
192, 109, 174, 82, 86, 75, 200, 125, 37, 214, 92, 72, 146, 177, 237, 50, 177, 182, 183, 192, 158, 181, 156, 0, 25,
218, 250, 15, 179, 18, 138, 190, 161, 50, 119, 61, 58, 232, 133, 95, 39, 84, 223, 199, 142, 250, 187, 29, 87, 143,
137, 189, 95, 69, 219, 226, 106, 28, 105, 147, 131, 57, 206, 31, 63, 25, 28, 189, 185, 62, 204, 89, 63, 9, 161, 208,
136, 125, 161, 196, 92, 2, 82, 84, 165, 105, 179, 192, 43, 228, 3, 211, 134, 216, 252, 237, 73, 102, 46, 96, 207,
127, 61, 7, 159, 180, 194, 40, 17, 4, 33, 120, 89, 250, 159, 170, 193, 32, 123, 242, 170, 143, 105, 111, 151, 105,
61, 241, 75, 10, 240, 165, 75, 25, 164, 28, 92, 190, 44, 215, 118, 195, 112, 201, 239, 252, 130, 152, 45, 107, 94,
130, 153, 171, 112, 14, 190, 78, 145, 4, 93, 95, 14, 130, 3, 90, 60, 176, 91, 228, 37, 12, 128, 254, 188, 171, 234,
86, 209, 206, 189, 175, 79, 77, 2, 212, 225, 144, 74, 143, 135, 103, 91, 214, 255, 232, 171, 193, 216, 22, 63, 45,
248, 73, 132, 149, 169, 234, 131, 176, 19, 161, 211, 204, 43, 44, 204, 61, 169, 155, 55, 210, 83, 45, 238, 104, 233,
82, 227, 64, 209, 206, 197, 176, 203, 219, 74, 134, 120, 14, 76, 48, 77, 92, 133, 129, 156, 99, 76, 62, 113, 129,
24, 9, 10, 119, 233, 250, 56, 241, 37, 59, 184, 93, 33, 130, 163, 229, 199, 162, 12, 72, 207, 89, 212, 154, 56, 202,
18, 30, 76, 195, 211, 112, 165, 231, 99, 116, 62, 37, 179, 190, 93, 141, 242, 97, 147, 143, 156, 238, 136, 151, 192,
142, 214, 176, 135, 165, 73, 138, 160, 78, 95, 199, 175, 224, 168, 161, 243, 140, 62, 201, 8, 220, 6, 184, 235, 128,
229, 255, 2, 137, 185, 218, 140, 164, 110, 187, 116, 135, 148, 36, 75, 203, 153, 173, 13, 155, 183, 48, 227, 5, 250,
23, 66, 245, 69, 138, 169, 216, 121, 70, 235, 30, 155, 169, 107, 7, 211, 109, 229, 84, 240, 142, 177, 208, 222, 174,
112, 167, 43, 51, 20, 143, 174, 30, 216, 150, 153, 62, 139, 74, 13, 105, 114, 212, 92, 226, 165, 110, 144, 103, 251,
246, 208, 117, 3, 141, 94, 8, 19, 168, 95, 186, 237, 188, 254, 21, 179, 165, 140, 186, 13, 166, 43, 172, 108, 100,
154, 212, 122, 115, 11, 104, 22, 217, 98, 164, 29, 222, 31, 160, 104, 129, 111, 84, 139, 66, 252, 148, 115, 5, 124,
120, 12, 202, 35, 71, 194, 252, 22, 32, 64, 101, 38, 98, 60, 243, 89, 28, 194, 67, 248, 147, 149, 94, 135, 152, 159,
52, 62, 52, 52, 26, 34, 254, 215, 153, 122, 44, 88, 37, 245, 156, 180, 1, 14, 97, 255, 255, 92, 52, 1, 179, 89, 178,
119, 38, 56, 240, 70, 199, 68, 180, 94, 215, 255, 153, 162, 134, 215, 218, 74, 147, 84, 3, 175, 164, 156, 66, 74,
19, 174, 110, 213, 115, 8, 165, 148, 23, 78, 30, 155, 150, 128, 139, 27, 146, 36, 116, 55, 51, 183, 48, 214, 160,
215, 224, 30, 235, 181, 183, 81, 119, 193, 219, 71, 160, 193, 104, 234, 160, 207, 147, 243, 91, 174, 106, 161, 247,
131, 233, 164, 141, 173, 149, 192, 44, 143, 153, 37, 95, 166, 239, 185, 184, 166, 156, 199, 213, 10, 100, 76, 229,
157, 39, 79, 190, 140, 16, 24, 226, 191, 124, 169, 34, 190, 99, 34, 34, 34, 156, 5, 219, 248, 139, 84, 101, 29, 103,
127, 247, 247, 74, 15, 55, 44, 17, 140, 26, 208, 159, 116, 78, 238, 4, 53, 253, 209, 46, 6, 115, 207, 244, 219, 142,
64, 35, 149, 42, 171, 32, 38, 194, 155, 189, 35, 221, 166, 253, 111, 213, 195, 101, 177, 77, 86, 2, 170, 69, 11,
253, 219, 157, 142, 140, 232, 215, 146, 178, 229, 229, 147, 75, 218, 141, 121, 163, 24, 37, 60, 56, 175, 105, 155,
136, 145, 72, 201, 157, 136, 201, 109, 143, 29, 230, 78, 252, 6, 195, 88, 239, 84, 94, 177, 29, 192, 237, 195, 9,
169, 252, 6, 215, 172, 57, 150, 216, 99, 143, 232, 100, 207, 209, 2, 131, 145, 161, 65, 230, 205, 68, 64, 114, 11,
225, 162, 203, 159, 105, 76, 187, 240, 217, 143, 22, 146, 247, 247, 147, 167, 85, 214, 247, 148, 241, 189, 121, 127,
171, 203, 186, 251, 37, 216, 199, 191, 105, 188, 132, 225, 188, 119, 56, 203, 250, 59, 172, 7, 107, 17, 217, 230,
46, 147, 70, 137, 100, 153, 119, 113, 88, 6, 74, 139, 2, 13, 136, 196, 119, 250, 28, 154, 17, 152, 201, 30, 128,
148, 221, 200, 229, 138, 84, 153, 174, 235, 251, 164, 61, 230, 19, 158, 191, 90, 34, 185, 25, 196, 129, 21, 12, 78,
92, 30, 4, 251, 174, 48, 164, 139, 76, 172, 101, 245, 6, 165, 30, 150, 106, 86, 134, 197, 30, 129, 131, 182, 17, 72,
190, 101, 72, 169, 67, 160, 196, 110, 13, 93, 194, 117, 186, 79, 130, 192, 94, 30, 245, 101, 120, 99, 250, 189, 76,
66, 126, 115, 224, 17, 98, 74, 204, 231, 237, 219, 50, 93, 73, 38, 182, 188, 209, 3, 168, 5, 34, 20, 5, 205, 233,
94, 32, 45, 174, 247, 171, 188, 71, 33, 2, 193, 255, 74, 195, 125, 5, 122, 142, 113, 124, 198, 60, 60, 116, 38, 192,
68, 78, 252, 196, 226, 215, 163, 125, 166, 92, 128, 164, 132, 153, 19, 189, 16, 142, 126, 31, 83, 229, 30, 151, 174,
246, 104, 101, 159, 194, 246, 62, 166, 122, 124, 107, 105, 196, 216, 67, 110, 230, 141, 225, 208, 219, 206, 114,
101, 160, 216, 86, 63, 174, 213, 98, 98, 52, 97, 214, 183, 117, 81, 169, 245, 149, 170, 72, 175, 218, 81, 179, 22,
243, 113, 26, 186, 44, 138, 210, 131, 249, 214, 66, 181, 216, 31, 80, 43, 172, 46, 28, 178, 11, 109, 192, 212, 54,
216, 185, 196, 188, 167, 24, 226, 10, 216, 120, 3, 250, 146, 156, 67, 154, 50, 36, 74, 185, 170, 143, 218, 79, 188,
210, 219, 130, 41, 117, 12, 19, 250, 160, 227, 44, 143, 1, 186, 167, 146, 226, 131, 137, 187, 187, 88, 27, 120, 218,
82, 211, 227, 255, 226, 170, 10, 201, 38, 192, 199, 32, 218, 9, 24, 254, 87, 63, 115, 254, 124, 172, 203, 16, 211,
214, 11, 186, 113, 248, 204, 211, 47, 39, 83, 29, 107, 243, 136, 19, 36, 40, 23, 210, 136, 208, 215, 9, 29, 138,
130, 3, 221, 74, 164, 220, 237, 107, 81, 143, 94, 43, 175, 217, 148, 220, 207, 22, 194, 195, 152, 93, 47, 140, 99,
195, 51, 41, 104, 118, 66, 194, 71, 242, 54, 90, 99, 92, 110, 253, 130, 143, 175, 38, 248, 37, 86, 7, 116, 79, 251,
33, 48, 176, 89, 130, 239, 143, 180, 101, 246, 99, 31, 63, 130, 118, 192, 190, 248, 231, 241, 22, 179, 7, 152, 87,
159, 39, 200, 106, 226, 250, 150, 156, 95, 231, 87, 68, 133, 154, 4, 56, 128, 95, 108, 109, 209, 72, 122, 196, 98,
49, 107, 214, 66, 10, 138, 5, 10, 122, 210, 51, 44, 19, 173, 68, 238, 186, 164, 166, 97, 140, 162, 42, 103, 127, 16,
15, 72, 98, 14, 118, 57, 120, 82, 19, 254, 128, 169, 60, 222, 62, 211, 71, 30, 138, 48, 142, 140, 51, 224, 122, 164,
32, 111, 158, 241, 84, 84, 12, 93, 211, 107, 169, 229, 140, 17, 182, 63, 207, 232, 114, 225, 31, 207, 124, 44, 28,
148, 159, 118, 188, 163, 229, 62, 166, 190, 217, 42, 227, 156, 14, 21, 106, 10, 120, 225, 3, 223, 26, 101, 21, 46,
135, 111, 97, 144, 22, 59, 241, 59, 4, 254, 30, 178, 85, 145, 75, 212, 252, 178, 47, 231, 129, 62, 198, 156, 66,
226, 179, 37, 49, 105, 231, 197, 76, 110, 87, 3, 164, 141, 208, 190, 60, 103, 111, 127, 140, 46, 133, 185, 74, 70,
118, 176, 165, 115, 38, 6, 183, 154, 185, 26, 45, 2, 184, 130, 255, 5, 193, 49, 162, 70, 241, 36, 159, 67, 243, 38,
232, 177, 212, 118, 99, 51, 106, 74, 27, 249, 40, 17, 166, 48, 92, 201, 100, 114, 70, 190, 124, 190, 207, 251, 46,
186, 19, 249, 132, 84, 251, 30, 8, 10, 70, 221, 140, 156, 143, 34, 90, 56, 216, 234, 64, 148, 168, 98, 144, 128,
226, 165, 126, 136, 19, 145, 112, 199, 222, 84, 18, 87, 215, 110, 241, 95, 161, 91, 94, 37, 193, 38, 106, 255, 237,
235, 146, 42, 69, 5, 91, 49, 212, 94, 72, 46, 191, 202, 140, 50, 28, 25, 118, 133, 37, 132, 101, 146, 78, 177, 190,
196, 34, 40, 26, 229, 215, 141, 147, 173, 57, 221, 99, 57, 121, 34, 73, 121, 231, 173, 175, 205, 124, 60, 217, 255,
215, 237, 144, 11, 21, 73, 198, 139, 71, 65, 196, 142, 76, 144, 226, 92, 226, 194, 188, 197, 2, 211, 80, 58, 207,
157, 144, 21, 191, 198, 196, 197, 94, 163, 130, 187, 128, 226, 141, 80, 5, 115, 58, 25, 238, 220, 49, 66, 13, 127,
221, 149, 170, 136, 104, 238, 98, 34, 185, 195, 206, 144, 240, 179, 58, 39, 21, 20, 143, 121, 54, 50, 245, 36, 248,
134, 113, 88, 102, 86, 184, 8, 13, 86, 118, 223, 249, 106, 2, 247, 213, 35, 28, 255, 23, 202, 244, 8, 249, 229, 184,
37, 15, 133, 83, 233, 117, 220, 153, 10, 218, 67, 115, 107, 160, 233, 167, 126, 47, 17, 119, 180, 34, 229, 97, 143,
182, 7, 80, 159, 25, 7, 133, 92, 244, 19, 24, 224, 155, 130, 150, 118, 188, 160, 147, 9, 6, 63, 151, 137, 50, 241,
158, 117, 191, 169, 201, 116, 167, 109, 42, 105, 55, 165, 254, 221, 175, 215, 61, 147, 10, 236, 11, 16, 213, 4, 236,
107, 57, 48, 134, 175, 215, 240, 112, 29, 234, 143, 119, 251, 237, 188, 133, 160, 8, 25, 67, 121, 140, 85, 209, 137,
57, 111, 203, 109, 111, 230, 236, 239, 224, 185, 144, 176, 199, 70, 5, 55, 111, 81, 10, 91, 60, 0, 83, 11, 202, 20,
222, 167, 5, 180, 13, 55, 49, 40, 193, 188, 62, 198, 136, 201, 33, 220, 115, 75, 14, 128, 26, 228, 27, 89, 195, 225,
145, 210, 242, 34, 169, 146, 253, 222, 144, 194, 106, 71, 206, 60, 98, 36, 106, 201, 210, 113, 56, 247, 112, 42,
163, 106, 75, 8, 43, 102, 5, 141, 19, 107, 21, 52, 1, 70, 83, 137, 66, 151, 156, 189, 50, 216, 122, 135, 14, 161,
175, 151, 9, 72, 163, 248, 177, 183, 221, 122, 42, 86, 151, 25, 187, 110, 35, 100, 162, 186, 47, 250, 197, 30, 84,
110, 43, 121, 34, 97, 27, 213, 69, 134, 165, 196, 22, 181, 72, 22, 24, 10, 22, 174, 213, 186, 254, 101, 77, 161, 84,
63, 85, 114, 152, 4, 167, 154, 56, 33, 242, 177, 184, 7, 103, 64, 151, 179, 181, 201, 91, 111, 58, 106, 146, 234,
36, 99, 12, 74, 125, 38, 80, 202, 105, 73, 239, 190, 228, 181, 222, 91, 88, 235, 81, 177, 171, 192, 179, 21, 221,
97, 35, 165, 35, 160, 11, 144, 87, 13, 32, 23, 193, 149, 77, 224, 130, 104, 110, 113, 75, 102, 120, 3, 218, 192, 45,
3, 49, 233, 43, 115, 165, 94, 221, 3, 163, 157, 168, 103, 221, 9, 191, 125, 246, 139, 11, 162, 157, 234, 13, 20,
246, 175, 40, 71, 56, 74, 223, 88, 77, 106, 138, 164, 56, 120, 173, 20, 64, 193, 179, 212, 161, 66, 166, 2, 46, 51,
171, 7, 247, 86, 1, 20, 126, 1, 136, 86, 76, 216, 237, 185, 99, 54, 160, 219, 58, 16, 88, 228, 62, 92, 20, 37, 26,
186, 52, 226, 27, 243, 78, 89, 180, 94, 189, 18, 139, 140, 157, 15, 53, 66, 248, 70, 52, 58, 184, 16, 139, 65, 111,
162, 69, 141, 230, 221, 136, 154, 3, 98, 119, 55, 89, 79, 166, 244, 217, 149, 227, 102, 250, 17, 207, 46, 38, 195,
124, 222, 163, 53, 102, 68, 198, 160, 32, 63, 51, 247, 109, 227, 96, 104, 244, 241, 3, 254, 122, 148, 154, 112, 96,
129, 215, 88, 0, 232, 162, 120, 98, 195, 174, 174, 11, 39, 182, 27, 116, 141, 46, 6, 133, 33, 72, 50, 207, 157, 22,
74, 149, 203, 179, 189, 114, 209, 67, 209, 58, 221, 119, 40, 191, 89, 223, 55, 216, 78, 88, 236, 201, 10, 218, 85,
54, 95, 78, 85, 65, 229, 112, 37, 10, 193, 204, 88, 194, 31, 97, 19, 130, 177, 240, 139, 246, 53, 76, 89, 232, 86,
219, 206, 97, 58, 37, 28, 186, 219, 110, 143, 229, 228, 221, 94, 244, 209, 248, 137, 62, 159, 196, 237, 48, 15, 250,
127, 220, 233, 163, 234, 71, 26, 175, 12, 189, 234, 54, 230, 164, 31, 251, 244, 132, 42, 7, 68, 134, 16, 133, 45,
238, 102, 54, 168, 242, 193, 217, 120, 0, 135, 141, 25, 235, 99, 22, 38, 155, 5, 161, 68, 183, 62, 241, 115, 47, 34,
187, 164, 146, 156, 46, 26, 200, 221, 168, 166, 195, 240, 95, 154, 86, 173, 191, 22, 129, 237, 65, 85, 255, 236,
173, 205, 14, 7, 85, 92, 22, 161, 229, 108, 122, 12, 168, 43, 135, 145, 25, 174, 10, 248, 160, 110, 77, 71, 86, 209,
38, 42, 53, 175, 123, 227, 61, 191, 171, 135, 230, 221, 250, 113, 86, 75, 191, 112, 45, 229, 142, 172, 36, 157, 183,
21, 15, 137, 231, 27, 218, 188, 105, 41, 27, 128, 41, 218, 89, 116, 156, 251, 59, 126, 75, 59, 101, 78, 38, 51, 187,
141, 84, 39, 15, 125, 10, 167, 65, 2, 53, 237, 160, 109, 230, 189, 152, 122, 150, 243, 109, 215, 250, 181, 55, 77,
141, 253, 17, 128, 23, 35, 186, 220, 39, 119, 146, 33, 3, 6, 122, 181, 37, 242, 118, 87, 195, 180, 171, 24, 206,
223, 70, 218, 110, 74, 50, 7, 64, 59, 86, 169, 32, 120, 20, 169, 153, 72, 49, 178, 234, 138, 203, 84, 90, 104, 154,
89, 17, 130, 72, 186, 207, 18, 139, 154, 240, 54, 67, 95, 138, 108, 50, 154, 125, 149, 100, 28, 72, 205, 180, 203,
217, 61, 82, 185, 65, 239, 113, 164, 57, 23, 16, 135, 199, 235, 228, 253, 9, 65, 252, 88, 196, 169, 246, 71, 121,
187, 92, 228, 12, 40, 27, 183, 62, 72, 151, 108, 142, 140, 215, 44, 66, 112, 202, 119, 158, 51, 105, 205, 38, 48,
89, 230, 76, 106, 192, 25, 245, 56, 182, 84, 99, 120, 125, 192, 53, 212, 255, 254, 139, 248, 69, 21, 174, 11, 137,
18, 7, 89, 43, 230, 237, 162, 70, 214, 19, 164, 51, 205, 15, 14, 44, 215, 105, 188, 249, 149, 118, 150, 176, 253,
200, 130, 174, 120, 183, 243, 88, 217, 18, 113, 22, 40, 205, 187, 87, 218, 79, 251, 157, 216, 43, 215, 114, 41, 213,
191, 137, 159, 135, 255, 58, 54, 80, 26, 252, 149, 102, 246, 154, 54, 101, 183, 248, 74, 245, 38, 78, 55, 45, 70,
183, 154, 74, 55, 35, 155, 126, 193, 118, 129, 70, 177, 3, 4, 210, 209, 48, 61, 122, 17, 2, 76, 28, 113, 49, 15, 58,
68, 184, 168, 157, 75, 154, 53, 233, 12, 109, 40, 100, 205, 157, 71, 171, 81, 77, 36, 53, 165, 234, 209, 69, 214,
70, 75, 47, 97, 242, 33, 215, 194, 41, 254, 234, 23, 61, 236, 11, 250, 179, 144, 199, 95, 213, 233, 247, 94, 38,
230, 245, 102, 62, 210, 217, 73, 85, 149, 4, 233, 16, 88, 222, 115, 87, 255, 69, 204, 57, 210, 55, 3, 33, 225, 251,
193, 28, 130, 20, 27, 140, 239, 13, 138, 203, 202, 229, 161, 27, 82, 168, 246, 10, 204, 151, 204, 110, 223, 188,
216, 211, 39, 248, 235, 177, 88, 71, 231, 15, 97, 61, 115, 194, 6, 119, 148, 224, 6, 75, 26, 241, 218, 126, 255, 15,
87, 253, 161, 88, 214, 37, 187, 227, 101, 26, 159, 91, 183, 67, 241, 47, 30, 188, 222, 90, 98, 159, 177, 70, 122,
221, 198, 115, 35, 220, 199, 187, 121, 43, 71, 197, 148, 136, 212, 23, 138, 255, 140, 122, 50, 30, 38, 220, 44, 197,
194, 145, 188, 173, 146, 99, 143, 75, 199, 126, 77, 71, 85, 156, 178, 175, 222, 236, 145, 197, 71, 93, 123, 4, 218,
165, 208, 55, 114, 226, 92, 49, 204, 212, 116, 46, 117, 157, 28, 10, 184, 237, 127, 88, 56, 5, 153, 7, 48, 194, 53,
32, 105, 5, 68, 49, 249, 71, 219, 131, 193, 202, 101, 236, 207, 40, 137, 56, 243, 67, 134, 81, 159, 12, 226, 114,
168, 16, 153, 201, 228, 67, 63, 141, 4, 150, 86, 150, 164, 241, 25, 102, 125, 101, 70, 232, 70, 164, 228, 120, 214,
140, 198, 236, 47, 170, 53, 55, 144, 248, 150, 192, 21, 145, 106, 53, 123, 76, 235, 124, 243, 61, 43, 192, 26, 63,
81, 141, 214, 73, 74, 44, 95, 196, 44, 113, 190, 152, 170, 162, 195, 192, 98, 161, 63, 140, 90, 116, 198, 28, 225,
109, 85, 121, 126, 118, 250, 65, 176, 120, 22, 213, 119, 212, 178, 30, 64, 27, 203, 194, 186, 241, 220, 11, 26, 129,
185, 199, 80, 201, 75, 54, 26, 50, 43, 173, 77, 213, 207, 247, 22, 150, 92, 29, 91, 120, 7, 162, 81, 200, 89, 92,
69, 11, 216, 177, 187, 49, 140, 183, 228, 203, 210, 66, 76, 223, 214, 46, 186, 91, 28, 67, 174, 201, 61, 109, 149,
178, 34, 11, 204, 190, 150, 47, 155, 184, 128, 91, 204, 211, 211, 194, 59, 204, 148, 219, 251, 1, 105, 196, 194,
246, 139, 247, 195, 105, 23, 101, 208, 107, 128, 189, 231, 137, 205, 253, 172, 106, 145, 14, 157, 208, 96, 47, 129,
112, 135, 64, 184, 167, 244, 228, 249, 41, 98, 228, 102, 131, 213, 133, 178, 231, 181, 213, 52, 104, 113, 61, 16,
90, 90, 148, 7, 202, 13, 146, 27, 132, 147, 196, 47, 206, 153, 130, 26, 131, 121, 29, 240, 162, 199, 99, 178, 117,
132, 90, 18, 196, 183, 13, 121, 63, 75, 213, 98, 189, 126, 204, 54, 92, 195, 59, 143, 252, 89, 128, 158, 182, 226,
167, 26, 52, 68, 12, 39, 121, 103, 222, 222, 162, 137, 28, 37, 146, 38, 78, 196, 65, 103, 54, 243, 20, 20, 102, 184,
75, 183, 151, 239, 176, 2, 221, 139, 82, 23, 160, 29, 78, 183, 100, 161, 47, 70, 250, 236, 51, 216, 226, 55, 70, 60,
220, 222, 67, 70, 249, 221, 176, 213, 51, 33, 187, 208, 119, 228, 202, 132, 232, 115, 30, 72, 208, 217, 37, 238,
181, 185, 115, 138, 154, 13, 35, 55, 121, 84, 129, 209, 254, 170, 85, 26, 167, 61, 38, 195, 185, 156, 253, 178, 10,
206, 5, 152, 68, 144, 249, 222, 55, 36, 184, 66, 254, 187, 202, 109, 148, 220, 148, 63, 101, 243, 179, 65, 21, 7,
48, 134, 100, 225, 165, 84, 124, 240, 7, 211, 200, 126, 41, 251, 134, 43, 176, 85, 252, 3, 240, 7, 215, 64, 36, 92,
55, 48, 121, 21, 170, 15, 84, 186, 30, 165, 197, 11, 229, 60, 94, 183, 37, 165, 255, 30, 118, 202, 43, 194, 47, 60,
243, 225, 201, 182, 42, 10, 26, 232, 164, 183, 25, 166, 177, 90, 50, 80, 186, 203, 122, 47, 44, 200, 63, 86, 47,
128, 5, 176, 102, 220, 245, 220, 121, 215, 191, 12, 148, 229, 1, 238, 117, 226, 50, 181, 9, 79, 156, 136, 223, 123,
243, 7, 62, 88, 175, 118, 152, 215, 222, 79, 142, 176, 239, 244, 236, 21, 158, 209, 219, 35, 172, 28, 214, 234, 1,
142, 67, 148, 86, 58, 64, 200, 102, 24, 144, 118, 203, 192, 214, 96, 235, 142, 141, 196, 211, 72, 245, 142, 21, 226,
41, 233, 154, 50, 110, 80, 125, 143, 24, 101, 252, 151, 192, 158, 91, 211, 24, 18, 228, 134, 122, 220, 146, 103,
236, 247, 209, 239, 34, 163, 105, 83, 180, 157, 38, 181, 195, 66, 253, 10, 79, 162, 71, 217, 13, 225, 92, 43, 50,
128, 241, 7, 58, 208, 79, 111, 153, 126, 90, 80, 14, 24, 84, 43, 26, 23, 43, 148, 209, 68, 19, 49, 136, 133, 75,
162, 84, 125, 115, 156, 98, 48, 208, 120, 150, 100, 164, 103, 231, 170, 168, 103, 196, 138, 202, 168, 160, 239, 137,
14, 3, 176, 243, 39, 25, 7, 158, 6, 134, 7, 27, 223, 238, 29, 196, 111, 219, 6, 59, 81, 148, 234, 150, 190, 20, 28,
102, 20, 220, 211, 11, 221, 140, 122, 213, 164, 98, 98, 35, 158, 161, 43, 238, 222, 132, 204, 231, 126, 103, 162,
65, 191, 96, 224, 225, 18, 93, 125, 81, 71, 27, 226, 70, 38, 255, 20, 168, 105, 44, 94, 122, 160, 121, 16, 83, 232,
138, 179, 90, 122, 165, 92, 40, 99, 117, 243, 14, 186, 137, 223, 65, 14, 83, 237, 240, 86, 141, 85, 135, 237, 161,
150, 167, 33, 242, 113, 238, 235, 15, 217, 216, 91, 121, 147, 239, 171, 70, 29, 247, 113, 111, 134, 181, 93, 185,
84, 55, 241, 238, 30, 148, 119, 159, 189, 199, 61, 23, 167, 91, 217, 60, 203, 221, 127, 82, 248, 208, 172, 148, 84,
92, 191, 172, 85, 201, 118, 130, 220, 68, 46, 174, 136, 107, 100, 165, 76, 197, 250, 236, 60, 7, 17, 211, 224, 67,
177, 184, 199, 58, 108, 190, 207, 133, 87, 153, 68, 255, 205, 168, 61, 40, 117, 95, 245, 130, 85, 202, 26, 178, 78,
53, 73, 55, 221, 245, 218, 87, 195, 59, 246, 127, 54, 35, 151, 46, 178, 162, 80, 212, 156, 149, 138, 194, 53, 2, 88,
56, 223, 22, 115, 118, 70, 251, 137, 185, 90, 255, 253, 190, 111, 88, 80, 247, 64, 101, 45, 154, 153, 240, 129, 199,
180, 159, 86, 36, 247, 88, 109, 162, 141, 193, 158, 210, 231, 221, 29, 9, 189, 212, 36, 49, 52, 174, 56, 219, 203,
241, 225, 36, 39, 30, 0, 61, 119, 162, 61, 41, 75, 38, 40, 157, 86, 66, 231, 50, 148, 215, 62, 220, 161, 245, 136,
246, 158, 170, 178, 184, 57, 30, 98, 227, 124, 32, 212, 64, 246, 206, 209, 206, 52, 4, 133, 106, 42, 85, 7, 182,
244, 107, 109, 239, 17, 107, 231, 168, 66, 10, 103, 134, 116, 64, 31, 50, 249, 147, 130, 248, 195, 232, 240, 33,
238, 145, 106, 119, 107, 122, 25, 124, 249, 94, 224, 28, 127, 220, 225, 116, 238, 2, 241, 115, 182, 107, 54, 16, 52,
86, 200, 58, 188, 136, 23, 164, 188, 181, 108, 161, 167, 122, 76, 122, 218, 16, 111, 87, 189, 51, 132, 179, 95, 99,
228, 172, 22, 244, 137, 144, 89, 147, 96, 108, 43, 189, 55, 54, 67, 6, 149, 146, 184, 23, 190, 31, 119, 34, 70, 17,
162, 60, 244, 37, 200, 198, 31, 88, 29, 49, 67, 77, 131, 123, 40, 197, 113, 222, 136, 118, 96, 198, 245, 57, 83,
136, 200, 80, 156, 250, 254, 86, 63, 172, 212, 46, 22, 136, 121, 163, 117, 207, 52, 48, 13, 193, 198, 158, 161, 238,
160, 62, 132, 70, 130, 18, 50, 70, 251, 98, 50, 187, 97, 111, 199, 123, 4, 31, 99, 67, 130, 180, 76, 60, 156, 172,
22, 176, 173, 187, 224, 26, 43, 138, 41, 55, 63, 64, 200, 240, 194, 188, 26, 37, 41, 90, 8, 214, 52, 127, 193, 205,
66, 101, 77, 53, 50, 93, 199, 9, 94, 154, 207, 14, 162, 189, 49, 31, 195, 41, 226, 7, 139, 20, 129, 27, 127, 137,
171, 78, 191, 173, 42, 155, 206, 167, 80, 63, 169, 211, 175, 45, 122, 240, 12, 52, 82, 103, 237, 161, 73, 181, 56,
135, 207, 183, 163, 50, 251, 76, 179, 52, 51, 130, 10, 233, 246, 10, 105, 146, 58, 16, 74, 207, 204, 119, 247, 215,
168, 100, 74, 180, 218, 235, 151, 117, 161, 185, 149, 113, 193, 224, 146, 82, 114, 63, 156, 251, 10, 139, 2, 18, 29,
240, 63, 50, 219, 114, 176, 58, 87, 255, 124, 59, 4, 115, 186, 104, 37, 177, 14, 31, 62, 229, 92, 242, 210, 88, 3,
186, 100, 170, 110, 198, 192, 2, 25, 108, 66, 160, 208, 59, 194, 199, 42, 110, 201, 232, 154, 158, 145, 66, 56, 140,
20, 42, 25, 175, 113, 150, 114, 123, 228, 17, 57, 114, 106, 219, 139, 150, 60, 8, 48, 35, 112, 241, 212, 183, 190,
203, 144, 66, 252, 214, 109, 0, 126, 75, 21, 168, 204, 63, 208, 123, 52, 85, 59, 166, 248, 88, 232, 147, 163, 55,
225, 198, 193, 163, 151, 195, 243, 170, 180, 73, 97, 95, 9, 20, 33, 149, 128, 23, 219, 226, 80, 250, 235, 244, 106,
147, 61, 10, 136, 156, 99, 65, 96, 127, 134, 218, 2, 123, 227, 109, 155, 155, 2, 128, 233, 111, 104, 33, 72, 210,
228, 112, 214, 182, 141, 114, 147, 162, 103, 19, 80, 168, 125, 146, 100, 104, 180, 130, 223, 16, 254, 197, 101, 182,
173, 15, 245, 74, 63, 241, 52, 216, 135, 137, 173, 6, 139, 46, 210, 191, 38, 240, 46, 146, 99, 214, 107, 140, 84,
253, 33, 119, 110, 154, 57, 214, 134, 49, 126, 184, 35, 79, 82, 71, 192, 164, 162, 238, 63, 141, 223, 48, 65, 205,
112, 246, 103, 84, 163, 148, 167, 45, 13, 72, 125, 75, 196, 80, 128, 51, 24, 159, 126, 59, 208, 132, 68, 253, 30,
234, 78, 51, 123, 242, 230, 29, 133, 186, 17, 173, 190, 41, 35, 190, 233, 144, 216, 131, 61, 114, 51, 174, 49, 118,
124, 71, 72, 205, 211, 128, 33, 60, 217, 9, 78, 25, 185, 75, 16, 112, 171, 107, 237, 214, 135, 130, 178, 3, 46, 15,
67, 23, 107, 2, 238, 74, 130, 81, 211, 181, 37, 69, 188, 237, 182, 14, 18, 37, 223, 227, 181, 79, 246, 81, 229, 77,
220, 13, 41, 131, 167, 13, 202, 7, 165, 246, 12, 74, 47, 50, 242, 220, 22, 206, 192, 60, 253, 175, 38, 246, 49, 220,
88, 151, 102, 245, 181, 65, 227, 9, 35, 136, 44, 53, 15, 252, 105, 41, 211, 13, 192, 38, 219, 35, 1, 226, 120, 43,
112, 140, 106, 61, 224, 24, 207, 182, 31, 101, 184, 131, 178, 93, 113, 183, 12, 248, 92, 153, 238, 127, 220, 189,
40, 120, 73, 12, 240, 110, 166, 233, 55, 70, 107, 111, 221, 139, 244, 127, 244, 43, 193, 212, 148, 100, 35, 109, 97,
178, 142, 15, 235, 9, 240, 154, 119, 94, 52, 93, 167, 56, 174, 108, 244, 41, 233, 113, 72, 200, 253, 126, 51, 188,
14, 234, 162, 53, 251, 138, 111, 7, 161, 127, 45, 254, 77, 83, 254, 83, 68, 173, 251, 200, 253, 142, 68, 132, 23, 2,
32, 252, 113, 219, 36, 242, 25, 2, 0, 204, 82, 3, 23, 170, 192, 124, 60, 245, 155, 213, 151, 203, 28, 26, 24, 218,
45, 145, 229, 174, 223, 226, 255, 148, 123, 183, 85, 197, 213, 232, 249, 117, 228, 20, 101, 189, 226, 52, 167, 213,
157, 83, 182, 127, 44, 135, 129, 244, 239, 254, 0, 170, 255, 140, 78, 229, 44, 30, 6, 38, 216, 171, 117, 75, 48,
165, 190, 253, 72, 131, 144, 126, 114, 204, 229, 245, 79, 54, 20, 146, 48, 217, 74, 196, 92, 229, 67, 71, 72, 17,
86, 132, 100, 247, 109, 56, 233, 148, 160, 241, 78, 241, 64, 63, 114, 101, 74, 131, 83, 45, 195, 65, 255, 237, 15,
233, 50, 221, 254, 58, 84, 149, 168, 187, 49, 57, 10, 82, 107, 186, 219, 46, 154, 190, 82, 237, 26, 70, 87, 178, 45,
165, 107, 112, 237, 40, 32, 9, 5, 104, 160, 67, 3, 161, 71, 232, 61, 151, 121, 78, 250, 57, 228, 8, 109, 74, 103,
240, 45, 105, 54, 187, 190, 23, 78, 178, 253, 14, 158, 235, 19, 126, 190, 116, 190, 45, 147, 195, 30, 253, 160, 0,
213, 250, 39, 162, 32, 61, 108, 244, 77, 184, 247, 58, 224, 67, 225, 130, 222, 252, 13, 0, 68, 19, 228, 124, 21,
114, 231, 15, 201, 8, 36, 135, 235, 2, 62, 33, 159, 123, 105, 143, 109, 196, 175, 122, 28, 145, 13, 113, 18, 222,
204, 183, 96, 216, 160, 159, 178, 128, 153, 99, 141, 78, 128, 48, 129, 202, 45, 14, 207, 5, 233, 146, 43, 2, 62,
216, 143, 183, 11, 91, 52, 62, 199, 115, 201, 55, 89, 134, 182, 84, 138, 207, 220, 83, 196, 230, 139, 171, 57, 16,
2, 36, 135, 154, 170, 107, 85, 241, 102, 2, 192, 131, 90, 105, 67, 137, 140, 34, 234, 254, 209, 94, 166, 178, 88,
129, 66, 215, 232, 7, 126, 237, 40, 253, 128, 251, 94, 26, 220, 24, 145, 116, 85, 37, 44, 134, 131, 170, 190, 129,
137, 49, 250, 92, 205, 255, 140, 181, 173, 75, 127, 81, 112, 237, 42, 188, 82, 58, 124, 63, 20, 74, 235, 69, 154,
106, 197, 55, 66, 11, 147, 53, 94, 177, 0, 13, 169, 201, 25, 25, 239, 94, 29, 209, 194, 167, 249, 246, 3, 1, 237,
198, 222, 185, 211, 237, 159, 218, 84, 69, 10, 66, 171, 208, 36, 7, 178, 1, 168, 8, 73, 27, 138, 236, 70, 115, 148,
182, 79, 101, 23, 162, 181, 64, 60, 3, 29, 157, 107, 104, 116, 167, 92, 156, 253, 32, 248, 101, 132, 180, 95, 218,
177, 108, 82, 149, 109, 82, 56, 80, 29, 65, 210, 60, 110, 29, 203, 212, 172, 213, 58, 38, 10, 231, 97, 239, 127, 29,
39, 179, 237, 14, 74, 1, 55, 86, 127, 174, 106, 154, 143, 158, 12, 54, 23, 66, 147, 183, 228, 44, 227, 7, 213, 64,
208, 16, 199, 158, 33, 135, 161, 42, 205, 147, 57, 16, 229, 150, 6, 93, 78, 72, 155, 254, 113, 62, 102, 191, 237,
251, 177, 171, 79, 37, 37, 3, 68, 110, 55, 184, 200, 250, 61, 167, 169, 179, 37, 127, 65, 182, 146, 42, 119, 147,
134, 41, 154, 103, 71, 196, 66, 81, 0, 5, 19, 108, 194, 163, 73, 206, 134, 241, 18, 94, 9, 91, 28, 149, 97, 249,
183, 72, 182, 188, 183, 184, 177, 120, 165, 239, 146, 163, 198, 169, 161, 255, 204, 213, 154, 182, 27, 33, 23, 69,
102, 181, 157, 87, 224, 19, 89, 77, 40, 12, 223, 60, 16, 206, 31, 176, 195, 107, 96, 85, 133, 31, 113, 60, 157, 180,
141, 68, 16, 191, 123, 137, 229, 80, 18, 195, 87, 180, 58, 159, 122, 35, 167, 125, 13, 248, 234, 197, 120, 167, 91,
210, 144, 139, 95, 112, 161, 122, 29, 58, 59, 180, 249, 202, 113, 209, 27, 221, 133, 4, 23, 195, 54, 81, 180, 146,
247, 165, 242, 141, 76, 53, 193, 20, 80, 227, 255, 11, 31, 102, 226, 198, 76, 93, 248, 72, 106, 179, 212, 232, 3,
64, 40, 18, 199, 149, 159, 120, 243, 136, 211, 58, 124, 129, 177, 220, 156, 57, 130, 214, 160, 112, 170, 50, 24,
221, 247, 133, 186, 104, 141, 251, 206, 177, 150, 26, 233, 175, 62, 235, 170, 84, 202, 154, 142, 168, 79, 65, 194,
95, 151, 28, 121, 234, 0, 210, 55, 118, 106, 190, 212, 113, 147, 247, 87, 106, 216, 6, 63, 109, 37, 30, 12, 93, 137,
209, 24, 42, 13, 156, 238, 161, 215, 17, 183, 245, 249, 102, 190, 31, 50, 6, 162, 12, 42, 253, 247, 195, 180, 146,
88, 160, 192, 63, 139, 221, 151, 28, 240, 163, 129, 208, 76, 26, 216, 108, 225, 175, 4, 3, 70, 170, 24, 222, 217, 8,
72, 123, 30, 215, 131, 5, 219, 246, 118, 105, 151, 26, 179, 130, 13, 67, 76, 221, 82, 18, 173, 102, 159, 4, 215,
157, 29, 19, 88, 34, 155, 58, 12, 78, 160, 112, 7, 152, 20, 138, 185, 105, 72, 113, 160, 236, 71, 81, 56, 157, 8,
69, 25, 114, 201, 123, 134, 213, 171, 35, 145, 208, 188, 53, 36, 224, 22, 21, 42, 125, 51, 85, 80, 62, 212, 37, 225,
149, 40, 76, 67, 163, 255, 169, 94, 53, 97, 127, 150, 246, 134, 96, 249, 70, 215, 38, 145, 8, 119, 9, 163, 134, 166,
62, 167, 224, 160, 92, 190, 240, 197, 166, 38, 173, 39, 30, 8, 243, 98, 212, 251, 147, 67, 201, 64, 115, 58, 129,
33, 57, 91, 233, 72, 2, 98, 114, 226, 127, 51, 78, 193, 193, 210, 217, 152, 156, 10, 94, 236, 205, 219, 147, 213,
161, 70, 167, 125, 144, 47, 54, 185, 91, 142, 242, 56, 117, 75, 237, 56, 30, 239, 133, 96, 199, 164, 201, 63, 134,
190, 95, 146, 10, 113, 51, 201, 166, 171, 74, 243, 166, 248, 101, 189, 102, 232, 248, 190, 22, 29, 106, 152, 220,
250, 210, 156, 52, 76, 216, 154, 11, 42, 206, 190, 118, 138, 134, 52, 196, 76, 88, 171, 182, 205, 81, 79, 133, 181,
138, 164, 33, 134, 37, 171, 234, 126, 223, 126, 248, 1, 151, 239, 83, 33, 251, 55, 192, 153, 160, 25, 115, 246, 242,
138, 214, 167, 79, 52, 234, 233, 134, 151, 139, 229, 254, 247, 18, 55, 112, 75, 204, 166, 87, 248, 151, 54, 67, 225,
204, 216, 194, 27, 113, 17, 139, 84, 69, 220, 19, 55, 233, 80, 149, 91, 34, 114, 250, 91, 166, 247, 75, 212, 191,
10, 254, 183, 173, 232, 62, 197, 105, 63, 227, 195, 140, 175, 250, 67, 200, 255, 189, 177, 71, 178, 100, 215, 131,
29, 202, 246, 241, 154, 218, 161, 71, 239, 123, 213, 214, 135, 131, 247, 7, 231, 232, 174, 89, 50, 149, 128, 183, 1,
51, 112, 62, 242, 228, 23, 145, 132, 112, 54, 219, 69, 235, 83, 128, 21, 214, 189, 36, 208, 145, 123, 197, 26, 137,
210, 217, 97, 232, 223, 129, 7, 244, 201, 111, 77, 41, 193, 42, 17, 75, 47, 26, 118, 102, 106, 204, 202, 229, 0, 65,
253, 4, 81, 215, 215, 210, 41, 178, 141, 38, 230, 234, 156, 171, 40, 145, 8, 4, 44, 146, 224, 120, 61, 71, 208, 196,
129, 102, 239, 92, 128, 7, 254, 233, 184, 196, 173, 13, 116, 154, 160, 220, 161, 70, 234, 15, 150, 190, 117, 15, 59,
23, 49, 149, 53, 25, 230, 219, 24, 92, 122, 63, 147, 182, 251, 46, 125, 14, 33, 227, 61, 52, 99, 202, 242, 125, 204,
202, 159, 128, 255, 26, 17, 47, 15, 74, 190, 26, 95, 98, 224, 48, 87, 166, 48, 235, 11, 174, 48, 46, 6, 14, 165,
202, 94, 186, 101, 205, 93, 153, 114, 59, 253, 103, 142, 165, 157, 186, 100, 2, 46, 88, 165, 7, 244, 74, 246, 89,
69, 174, 44, 248, 219, 124, 103, 228, 182, 134, 168, 113, 121, 13, 82, 179, 7, 141, 236, 74, 69, 56, 228, 221, 168,
254, 34, 247, 117, 120, 117, 196, 170, 244, 190, 126, 25, 150, 16, 217, 42, 24, 99, 146, 173, 61, 158, 127, 93, 46,
252, 68, 33, 143, 91, 174, 53, 117, 98, 169, 94, 195, 123, 110, 245, 117, 206, 187, 196, 229, 148, 92, 251, 96, 130,
8, 163, 25, 212, 130, 116, 121, 187, 52, 103, 229, 23, 176, 220, 85, 217, 231, 199, 135, 25, 214, 27, 229, 192, 30,
108, 221, 202, 58, 227, 166, 88, 112, 181, 164, 218, 231, 133, 50, 170, 153, 249, 101, 44, 132, 48, 86, 159, 66,
218, 57, 204, 16, 50, 37, 17, 38, 192, 114, 41, 42, 226, 36, 169, 197, 95, 158, 134, 54, 117, 214, 183, 226, 196,
183, 202, 75, 138, 230, 173, 31, 143, 189, 161, 39, 25, 1, 242, 41, 135, 255, 197, 49, 235, 144, 56, 47, 184, 57,
75, 190, 249, 78, 236, 69, 193, 242, 186, 192, 38, 21, 88, 163, 49, 186, 88, 91, 165, 175, 144, 96, 43, 99, 204,
185, 139, 205, 207, 223, 3, 205, 18, 42, 222, 39, 75, 227, 209, 82, 137, 233, 35, 28, 207, 232, 128, 230, 244, 156,
26, 17, 131, 174, 60, 62, 161, 86, 70, 83, 38, 228, 114, 100, 197, 12, 3, 101, 190, 237, 197, 166, 235, 226, 21, 48,
125, 176, 66, 193, 64, 254, 55, 240, 202, 138, 77, 9, 70, 168, 117, 236, 0, 6, 117, 79, 162, 37, 54, 64, 31, 188,
81, 166, 236, 233, 184, 198, 27, 18, 233, 59, 181, 72, 34, 168, 138, 62, 133, 72, 238, 209, 95, 126, 117, 74, 99,
63, 1, 203, 123, 23, 211, 137, 176, 247, 240, 30, 71, 71, 84, 9, 194, 164, 7, 222, 113, 250, 243, 66, 165, 175, 86,
113, 108, 78, 19, 67, 8, 153, 36, 81, 60, 151, 47, 116, 42, 62, 210, 156, 133, 24, 41, 183, 212, 14, 44, 59, 0, 197,
17, 88, 37, 149, 96, 57, 11, 57, 123, 169, 196, 206, 63, 240, 84, 226, 56, 181, 53, 118, 246, 61, 130, 127, 117,
194, 27, 74, 201, 60, 196, 171, 223, 225, 10, 143, 253, 104, 235, 142, 170, 104, 219, 185, 103, 91, 216, 199, 148,
129, 160, 241, 190, 210, 186, 164, 117, 100, 18, 174, 112, 141, 97, 35, 46, 196, 129, 194, 171, 203, 183, 5, 75,
148, 37, 170, 115, 186, 115, 79, 95, 51, 196, 234, 208, 233, 93, 75, 103, 7, 38, 177, 113, 235, 169, 99, 130, 21,
162, 18, 217, 88, 187, 4, 251, 6, 243, 130, 104, 98, 171, 40, 37, 96, 94, 75, 24, 140, 127, 67, 100, 61, 212, 128,
39, 180, 8, 241, 237, 226, 35, 69, 80, 132, 41, 206, 200, 75, 179, 140, 137, 94, 122, 226, 50, 58, 205, 26, 62, 56,
0, 152, 180, 145, 99, 180, 215, 9, 17, 22, 23, 24, 42, 185, 145, 204, 64, 185, 35, 175, 206, 187, 170, 86, 11, 206,
17, 17, 172, 196, 102, 216, 42, 225, 181, 10, 145, 13, 110, 162, 48, 91, 120, 133, 65, 248, 199, 156, 212, 0, 139,
5, 160, 37, 62, 92, 128, 66, 163, 211, 83, 236, 164, 249, 139, 184, 154, 26, 252, 154, 176, 30, 150, 42, 39, 18, 84,
11, 219, 150, 53, 156, 242, 137, 156, 237, 144, 189, 76, 180, 205, 183, 222, 160, 198, 141, 92, 217, 17, 52, 170,
175, 108, 107, 81, 36, 95, 142, 61, 254, 106, 95, 29, 208, 170, 249, 131, 231, 126, 37, 3, 85, 23, 165, 110, 110,
212, 238, 57, 203, 127, 207, 140, 102, 159, 27, 161, 163, 198, 7, 167, 76, 22, 100, 199, 179, 232, 57, 109, 229,
118, 5, 211, 58, 185, 83, 73, 199, 234, 236, 250, 244, 78, 122, 173, 46, 210, 22, 15, 181, 195, 8, 84, 81, 212, 225,
226, 61, 168, 63, 174, 62, 103, 6, 162, 62, 67, 110, 228, 197, 215, 43, 112, 37, 190, 158, 230, 254, 18, 140, 241,
229, 81, 115, 78, 240, 177, 226, 95, 254, 74, 106, 240, 171, 33, 254, 133, 159, 212, 98, 97, 65, 171, 181, 47, 250,
58, 172, 177, 110, 108, 172, 9, 74, 248, 244, 72, 4, 87, 44, 119, 86, 210, 92, 133, 229, 233, 138, 74, 234, 140, 52,
42, 115, 80, 26, 109, 170, 200, 201, 52, 94, 60, 112, 63, 187, 128, 254, 158, 17, 110, 211, 247, 128, 107, 128, 42,
226, 173, 88, 6, 25, 148, 204, 197, 187, 2, 126, 230, 148, 244, 86, 115, 42, 132, 42, 198, 92, 88, 79, 182, 250,
154, 127, 131, 173, 18, 196, 43, 9, 174, 161, 243, 45, 224, 51, 217, 177, 168, 109, 39, 88, 15, 50, 231, 252, 108,
62, 127, 54, 138, 209, 81, 208, 92, 222, 7, 134, 228, 79, 91, 180, 169, 23, 108, 230, 8, 220, 197, 79, 19, 68, 91,
206, 34, 137, 115, 88, 60, 230, 159, 118, 153, 74, 78, 79, 34, 207, 108, 110, 113, 25, 240, 93, 248, 176, 179, 188,
118, 181, 17, 87, 45, 131, 90, 25, 98, 185, 139, 114, 49, 164, 23, 180, 125, 227, 199, 203, 150, 191, 3, 130, 197,
43, 81, 86, 190, 191, 25, 114, 145, 231, 203, 46, 122, 18, 20, 209, 186, 77, 92, 18, 86, 85, 190, 79, 182, 126, 121,
187, 232, 102, 183, 225, 115, 247, 34, 183, 137, 4, 113, 135, 90, 213, 34, 126, 231, 20, 134, 146, 236, 44, 81, 105,
76, 89, 202, 116, 226, 16, 229, 153, 176, 225, 237, 34, 244, 231, 231, 91, 198, 92, 110, 99, 87, 209, 66, 106, 242,
234, 69, 218, 33, 29, 88, 10, 183, 31, 176, 5, 26, 10, 235, 160, 61, 8, 103, 243, 40, 108, 17, 153, 52, 238, 88,
190, 32, 89, 182, 118, 198, 173, 250, 146, 44, 113, 231, 139, 113, 191, 187, 193, 80, 147, 50, 177, 182, 89, 107,
76, 188, 136, 178, 23, 172, 101, 215, 224, 41, 63, 104, 143, 202, 53, 81, 117, 225, 239, 89, 232, 49, 85, 24, 62,
233, 208, 69, 122, 97, 186, 240, 231, 189, 190, 90, 1, 239, 39, 157, 215, 129, 2, 23, 41, 203, 189, 192, 79, 253,
128, 0, 127, 154, 2, 168, 130, 133, 13, 55, 47, 68, 116, 141, 205, 68, 171, 56, 167, 153, 22, 54, 176, 80, 86, 37,
8, 6, 245, 154, 250, 242, 183, 136, 48, 167, 161, 0, 252, 199, 219, 155, 133, 216, 159, 28, 228, 190, 194, 90, 216,
150, 74, 205, 47, 246, 235, 22, 240, 200, 46, 119, 57, 176, 107, 59, 52, 12, 54, 26, 23, 205, 16, 153, 194, 134, 57,
22, 77, 164, 101, 195, 163, 104, 235, 181, 132, 207, 28, 76, 106, 248, 8, 188, 115, 149, 167, 237, 148, 131, 130,
225, 91, 111, 187, 46, 238, 27, 239, 102, 1, 183, 41, 80, 133, 229, 148, 44, 32, 145, 156, 24, 154, 30, 202, 86,
249, 144, 225, 178, 158, 18, 249, 141, 27, 244, 241, 87, 106, 66, 108, 19, 40, 38, 221, 136, 108, 11, 26, 148, 63,
133, 189, 80, 167, 134, 5, 67, 213, 233, 140, 179, 203, 200, 9, 205, 140, 192, 153, 252, 242, 87, 38, 102, 133, 233,
223, 229, 178, 25, 171, 126, 142, 231, 156, 152, 200, 151, 193, 142, 30, 129, 199, 178, 180, 105, 83, 57, 92, 162,
137, 69, 16, 105, 16, 62, 116, 123, 219, 64, 65, 177, 49, 46, 251, 71, 167, 176, 213, 15, 214, 190, 146, 170, 233,
245, 71, 42, 205, 197, 29, 163, 167, 235, 89, 161, 232, 142, 135, 187, 130, 184, 61, 97, 36, 115, 182, 183, 146,
193, 24, 212, 236, 171, 1, 34, 140, 42, 156, 60, 120, 152, 243, 172, 203, 15, 41, 72, 158, 239, 14, 10, 113, 118,
152, 207, 181, 22, 18, 154, 147, 112, 37, 100, 140, 127, 47, 77, 85, 171, 49, 176, 166, 125, 10, 228, 92, 152, 38,
176, 187, 188, 229, 28, 61, 124, 48, 27, 90, 31, 21, 164, 42, 35, 59, 35, 174, 153, 21, 69, 43, 246, 128, 112, 43,
244, 211, 45, 226, 122, 190, 255, 98, 131, 252, 61, 34, 226, 172, 207, 213, 180, 47, 18, 108, 166, 5, 69, 143, 96,
55, 160, 190, 60, 26, 116, 2, 29, 106, 54, 58, 75, 167, 173, 186, 31, 19, 20, 193, 68, 133, 56, 32, 252, 112, 43,
71, 101, 33, 181, 188, 154, 127, 20, 140, 28, 194, 9, 134, 205, 178, 97, 103, 142, 232, 113, 43, 35, 45, 95, 5, 197,
88, 183, 87, 205, 154, 66, 145, 41, 179, 176, 184, 216, 193, 26, 164, 46, 227, 75, 249, 13, 180, 75, 171, 129, 0,
20, 215, 175, 209, 138, 167, 160, 163, 156, 92, 107, 4, 243, 238, 116, 24, 215, 199, 205, 81, 161, 73, 72, 241, 161,
115, 230, 242, 61, 71, 182, 1, 153, 81, 144, 251, 103, 41, 124, 144, 41, 250, 229, 222, 179, 84, 6, 5, 82, 3, 95,
235, 174, 72, 251, 147, 71, 74, 156, 142, 67, 9, 50, 0, 13, 238, 1, 47, 237, 87, 178, 244, 16, 115, 27, 198, 28,
199, 58, 48, 198, 135, 114, 150, 99, 220, 126, 189, 115, 35, 122, 2, 185, 135, 164, 30, 157, 105, 84, 197, 237, 237,
72, 72, 187, 204, 149, 26, 217, 16, 169, 88, 172, 35, 210, 146, 169, 1, 120, 126, 255, 84, 114, 8, 106, 230, 145,
229, 116, 57, 222, 98, 224, 175, 123, 130, 42, 208, 224, 196, 138, 111, 188, 63, 227, 46, 211, 53, 196, 137, 232,
154, 26, 7, 247, 142, 110, 218, 169, 3, 66, 248, 27, 157, 77, 91, 32, 103, 45, 89, 217, 167, 160, 26, 184, 122, 202,
144, 134, 40, 204, 203, 196, 230, 210, 167, 3, 146, 251, 176, 63, 239, 25, 74, 129, 39, 183, 165, 87, 30, 68, 102,
31, 162, 83, 111, 174, 41, 100, 223, 237, 43, 237, 130, 169, 241, 32, 44, 187, 206, 104, 176, 22, 77, 16, 32, 133,
153, 130, 212, 201, 3, 229, 224, 117, 212, 20, 218, 135, 231, 188, 51, 210, 93, 34, 180, 221, 183, 110, 213, 139,
70, 57, 113, 112, 107, 212, 138, 178, 34, 8, 250, 12, 114, 91, 255, 81, 250, 4, 38, 199, 198, 166, 211, 151, 251,
197, 229, 71, 74, 13, 164, 32, 185, 219, 161, 79, 254, 252, 223, 154, 113, 249, 139, 116, 214, 68, 194, 192, 170,
146, 209, 231, 164, 168, 108, 103, 91, 13, 198, 49, 112, 65, 207, 77, 249, 118, 72, 132, 73, 1, 68, 108, 236, 232,
172, 180, 203, 118, 108, 58, 19, 216, 165, 187, 80, 80, 163, 228, 27, 100, 61, 197, 56, 63, 144, 48, 84, 136, 48,
192, 253, 19, 233, 75, 72, 127, 128, 171, 233, 119, 3, 205, 136, 126, 185, 78, 8, 187, 137, 30, 53, 25, 21, 111,
178, 93, 26, 232, 239, 194, 187, 72, 28, 107, 249, 70, 188, 77, 137, 120, 50, 241, 228, 157, 73, 62, 165, 219, 191,
43, 213, 45, 12, 26, 4, 49, 14, 118, 196, 184, 175, 94, 13, 143, 210, 89, 173, 83, 251, 36, 248, 242, 176, 166, 97,
210, 33, 238, 165, 52, 194, 96, 155, 54, 252, 4, 198, 166, 227, 219, 150, 119, 160, 68, 223, 131, 8, 215, 143, 108,
157, 28, 227, 242, 92, 231, 8, 249, 174, 56, 19, 229, 107, 104, 119, 254, 8, 183, 225, 132, 102, 115, 253, 254, 128,
87, 81, 128, 76, 102, 107, 197, 150, 148, 3, 175, 142, 221, 190, 7, 149, 18, 109, 171, 78, 167, 146, 230, 40, 181,
178, 141, 204, 191, 196, 112, 219, 211, 156, 42, 44, 206, 15, 195, 197, 124, 203, 29, 129, 126, 90, 226, 15, 205,
67, 172, 231, 102, 225, 227, 121, 75, 209, 108, 38, 153, 13, 108, 230, 31, 46, 30, 124, 247, 179, 151, 144, 204,
247, 191, 216, 9, 68, 100, 221, 8, 194, 167, 85, 32, 149, 67, 10, 10, 205, 42, 244, 180, 99, 236, 108, 221, 192, 65,
156, 92, 40, 250, 171, 58, 147, 104, 241, 219, 132, 1, 88, 4, 64, 206, 134, 157, 149, 125, 194, 138, 0, 244, 12, 17,
13, 205, 144, 201, 72, 235, 169, 218, 170, 166, 114, 132, 87, 84, 195, 41, 86, 151, 213, 233, 23, 91, 67, 36, 17,
117, 220, 227, 73, 190, 59, 38, 212, 159, 105, 143, 94, 22, 179, 162, 191, 157, 111, 48, 80, 178, 114, 35, 235, 79,
55, 18, 223, 140, 81, 100, 158, 180, 82, 188, 175, 124, 105, 221, 15, 43, 193, 97, 34, 194, 184, 153, 19, 40, 231,
201, 0, 52, 5, 208, 61, 248, 112, 11, 204, 134, 138, 223, 25, 12, 119, 27, 9, 43, 54, 28, 185, 74, 59, 67, 214, 5,
23, 246, 28, 80, 176, 104, 89, 142, 93, 156, 115, 68, 25, 117, 30, 2, 29, 163, 81, 213, 126, 139, 198, 9, 125, 89,
35, 131, 153, 93, 214, 138, 178, 151, 151, 146, 100, 57, 232, 98, 22, 159, 177, 38, 133, 152, 191, 110, 137, 133,
177, 65, 57, 131, 77, 56, 76, 233, 192, 4, 126, 210, 137, 205, 86, 89, 85, 169, 110, 221, 138, 132, 148, 13, 189,
81, 250, 11, 187, 9, 160, 206, 179, 129, 10, 191, 8, 132, 11, 193, 85, 102, 182, 246, 80, 135, 144, 170, 65, 77, 84,
151, 102, 59, 216, 24, 112, 236, 138, 245, 131, 98, 45, 159, 132, 245, 132, 115, 69, 23, 242, 68, 67, 190, 195, 25,
140, 66, 3, 7, 88, 144, 40, 1, 35, 47, 178, 89, 248, 162, 158, 89, 5, 107, 156, 15, 222, 69, 172, 188, 76, 4, 182,
23, 85, 239, 36, 222, 44, 100, 203, 165, 138, 240, 3, 244, 138, 174, 86, 236, 172, 27, 134, 207, 205, 248, 155, 253,
37, 168, 218, 210, 205, 238, 21, 36, 237, 251, 128, 211, 235, 184, 77, 148, 57, 168, 127, 57, 109, 58, 188, 248,
164, 83, 67, 11, 133, 198, 105, 98, 233, 199, 163, 249, 131, 218, 80, 48, 43, 135, 56, 8, 23, 104, 234, 8, 119, 141,
48, 182, 170, 125, 222, 255, 119, 101, 11, 34, 206, 76, 243, 190, 89, 41, 170, 192, 104, 30, 35, 17, 206, 242, 37,
109, 116, 188, 163, 50, 247, 39, 204, 221, 8, 85, 121, 75, 129, 255, 207, 27, 202, 219, 14, 128, 207, 212, 13, 106,
162, 170, 35, 163, 113, 252, 106, 95, 12, 245, 105, 165, 22, 105, 206, 202, 170, 92, 49, 158, 147, 107, 169, 137,
72, 92, 61, 54, 223, 29, 51, 90, 200, 136, 109, 92, 236, 133, 182, 249, 193, 138, 131, 113, 218, 133, 131, 248, 2,
25, 63, 172, 121, 194, 41, 155, 212, 225, 37, 28, 117, 123, 194, 231, 93, 154, 201, 181, 19, 191, 141, 59, 201, 62,
189, 210, 251, 89, 177, 105, 93, 121, 68, 20, 111, 91, 9, 158, 4, 85, 174, 217, 35, 145, 4, 39, 191, 204, 113, 40,
215, 215, 192, 191, 49, 130, 165, 112, 171, 99, 85, 168, 95, 52, 12, 233, 93, 152, 61, 167, 155, 149, 152, 83, 250,
72, 8, 126, 166, 230, 23, 97, 6, 112, 171, 69, 238, 191, 198, 146, 11, 119, 114, 168, 237, 83, 89, 136, 148, 36,
225, 70, 134, 68, 70, 62, 236, 75, 220, 186, 227, 91, 253, 244, 25, 241, 126, 223, 94, 188, 124, 99, 1, 221, 255,
101, 152, 238, 185, 187, 130, 66, 57, 105, 105, 112, 190, 181, 242, 26, 210, 212, 25, 19, 230, 45, 32, 46, 37, 230,
0, 180, 22, 203, 171, 225, 242, 176, 154, 132, 235, 55, 84, 104, 77, 133, 206, 62, 16, 255, 141, 89, 77, 65, 117,
127, 221, 86, 44, 117, 253, 72, 154, 121, 150, 186, 136, 142, 175, 145, 137, 79, 43, 31, 46, 229, 236, 223, 101, 17,
229, 179, 238, 235, 46, 99, 253, 58, 116, 162, 97, 23, 65, 233, 69, 66, 118, 54, 39, 122, 9, 190, 88, 91, 221, 214,
125, 233, 118, 178, 71, 26, 126, 80, 119, 63, 158, 87, 67, 4, 34, 248, 241, 112, 158, 3, 118, 156, 78, 3, 142, 30,
114, 246, 38, 211, 194, 143, 227, 165, 54, 83, 26, 26, 85, 128, 180, 124, 205, 51, 60, 127, 251, 131, 135, 99, 128,
0, 149, 12, 6, 133, 172, 231, 97, 68, 202, 78, 6, 124, 179, 219, 144, 193, 210, 117, 89, 243, 35, 208, 230, 245, 21,
218, 95, 197, 208, 84, 209, 49, 248, 235, 176, 137, 157, 80, 158, 227, 18, 156, 160, 140, 123, 86, 162, 57, 64, 126,
202, 255, 152, 127, 61, 89, 188, 34, 11, 171, 200, 9, 17, 10, 72, 212, 108, 39, 8, 127, 17, 208, 152, 33, 231, 53,
172, 29, 117, 222, 166, 156, 180, 1, 139, 165, 148, 47, 211, 204, 179, 154, 42, 171, 53, 231, 214, 235, 113, 179,
50, 131, 153, 252, 219, 22, 219, 240, 178, 144, 133, 220, 140, 77, 49, 35, 227, 153, 114, 234, 12, 171, 200, 20,
114, 220, 239, 142, 6, 229, 251, 49, 47, 157, 244, 84, 143, 153, 39, 29, 101, 159, 74, 171, 62, 121, 214, 165, 39,
254, 43, 70, 162, 106, 254, 125, 52, 7, 215, 159, 206, 105, 147, 179, 92, 101, 49, 33, 221, 64, 61, 166, 187, 42,
100, 226, 167, 178, 174, 12, 90, 103, 227, 19, 192, 95, 110, 62, 208, 137, 210, 157, 28, 101, 145, 216, 152, 85,
167, 121, 251, 0, 31, 244, 142, 151, 105, 63, 52, 252, 59, 253, 217, 230, 83, 211, 208, 227, 90, 246, 232, 47, 83,
108, 140, 213, 169, 48, 227, 5, 35, 1, 202, 126, 27, 69, 12, 73, 82, 26, 246, 125, 132, 124, 252, 96, 37, 121, 46,
177, 108, 1, 121, 74, 15, 239, 211, 98, 185, 72, 129, 24, 82, 33, 242, 42, 197, 234, 29, 228, 221, 71, 84, 55, 57,
45, 20, 83, 243, 250, 137, 8, 24, 86, 148, 249, 4, 99, 37, 133, 72, 158, 162, 21, 41, 73, 251, 27, 207, 64, 6, 18,
87, 193, 185, 96, 221, 121, 10, 248, 42, 161, 107, 81, 57, 218, 129, 103, 142, 97, 227, 8, 166, 57, 252, 101, 102,
18, 64, 234, 101, 114, 219, 235, 96, 80, 136, 59, 118, 166, 177, 151, 160, 79, 158, 244, 95, 195, 223, 58, 45, 215,
115, 109, 110, 252, 236, 35, 202, 137, 163, 206, 217, 129, 50, 43, 145, 95, 7, 54, 201, 202, 134, 161, 128, 159,
252, 187, 246, 176, 47, 169, 109, 119, 52, 42, 149, 227, 50, 172, 196, 172, 249, 129, 62, 31, 50, 254, 191, 204, 7,
194, 176, 45, 153, 173, 18, 251, 63, 216, 117, 57, 193, 149, 4, 49, 220, 0, 66, 162, 145, 57, 23, 17, 99, 2, 39,
243, 124, 122, 217, 77, 42, 78, 132, 144, 149, 177, 139, 201, 39, 16, 21, 81, 84, 199, 147, 228, 73, 83, 236, 13,
36, 215, 117, 219, 214, 79, 88, 238, 79, 141, 90, 157, 152, 15, 53, 226, 55, 198, 41, 81, 6, 255, 190, 85, 176, 74,
237, 134, 16, 14, 128, 183, 200, 207, 67, 154, 33, 60, 218, 241, 205, 218, 72, 115, 162, 15, 129, 44, 148, 245, 250,
58, 84, 180, 39, 243, 195, 90, 47, 250, 82, 252, 120, 61, 59, 164, 141, 98, 241, 68, 160, 217, 5, 222, 238, 255,
161, 94, 37, 76, 188, 69, 49, 122, 207, 7, 109, 19, 72, 33, 254, 175, 201, 205, 185, 115, 37, 81, 11, 186, 93, 23,
48, 176, 182, 192, 234, 127, 52, 251, 148, 60, 200, 28, 164, 92, 56, 13, 27, 144, 120, 215, 154, 78, 76, 26, 232,
35, 124, 36, 37, 168, 205, 54, 140, 47, 123, 218, 64, 24, 214, 78, 63, 111, 115, 124, 44, 185, 105, 92, 242, 37,
128, 24, 177, 246, 178, 106, 98, 119, 72, 122, 125, 1, 78, 75, 143, 71, 111, 113, 93, 118, 75, 31, 84, 182, 113, 54,
198, 45, 87, 191, 105, 30, 119, 242, 205, 36, 39, 172, 207, 180, 113, 12, 84, 181, 6, 50, 123, 204, 28, 108, 127,
12, 206, 72, 199, 106, 126, 168, 96, 49, 54, 192, 252, 62, 182, 156, 28, 216, 101, 98, 24, 86, 205, 195, 170, 121,
204, 134, 41, 200, 226, 158, 56, 102, 75, 65, 27, 249, 118, 186, 112, 160, 245, 237, 208, 56, 78, 59, 139, 226, 249,
80, 148, 24, 96, 150, 101, 54, 133, 39, 248, 248, 253, 46, 232, 152, 89, 253, 231, 145, 133, 82, 15, 114, 177, 12,
147, 137, 150, 30, 69, 217, 182, 245, 132, 254, 0, 242, 182, 131, 63, 211, 209, 6, 170, 13, 24, 79, 229, 242, 233,
182, 226, 163, 91, 96, 117, 19, 213, 237, 181, 157, 4, 126, 143, 245, 92, 213, 208, 194, 145, 187, 101, 172, 20,
252, 241, 11, 122, 50, 36, 213, 237, 234, 120, 33, 98, 45, 96, 14, 152, 134, 253, 223, 120, 68, 168, 83, 238, 54,
181, 26, 129, 24, 23, 104, 153, 58, 9, 185, 204, 251, 214, 134, 92, 203, 66, 69, 208, 32, 97, 12, 52, 193, 136, 177,
176, 215, 249, 203, 247, 246, 151, 113, 38, 197, 209, 94, 245, 127, 35, 48, 216, 106, 47, 77, 222, 254, 2, 17, 61,
222, 137, 56, 183, 225, 177, 148, 74, 127, 149, 147, 54, 8, 187, 218, 246, 130, 102, 121, 212, 144, 41, 32, 252, 64,
190, 108, 180, 213, 136, 17, 84, 73, 12, 226, 134, 202, 200, 235, 244, 254, 115, 18, 43, 7, 162, 193, 75, 222, 208,
40, 119, 212, 108, 203, 26, 225, 28, 63, 89, 6, 221, 203, 43, 19, 0, 113, 238, 21, 51, 79, 226, 230, 76, 21, 94, 78,
24, 194, 85, 87, 1, 51, 208, 212, 22, 52, 91, 132, 156, 214, 143, 212, 100, 32, 230, 230, 96, 229, 208, 91, 1, 22,
253, 104, 202, 69, 113, 24, 17, 151, 82, 207, 237, 144, 248, 80, 208, 98, 101, 209, 95, 115, 92, 222, 199, 18, 8,
127, 134, 53, 213, 54, 68, 190, 234, 118, 44, 235, 90, 251, 82, 126, 54, 209, 243, 131, 0, 212, 133, 24, 59, 180,
246, 5, 184, 37, 43, 149, 108, 127, 90, 209, 43, 89, 77, 120, 238, 54, 64, 10, 89, 144, 137, 139, 253, 36, 244, 55,
0, 183, 93, 90, 120, 62, 222, 250, 171, 4, 153, 32, 88, 87, 229, 74, 44, 19, 91, 190, 43, 171, 184, 60, 173, 128,
154, 133, 163, 175, 100, 187, 223, 244, 16, 115, 182, 165, 105, 53, 190, 56, 182, 217, 203, 155, 215, 42, 113, 28,
186, 116, 92, 191, 34, 167, 104, 248, 12, 50, 151, 1, 79, 43, 81, 166, 16, 129, 34, 148, 105, 112, 90, 190, 182, 70,
142, 217, 206, 29, 154, 47, 158, 173, 107, 57, 72, 229, 196, 15, 43, 157, 192, 31, 170, 138, 149, 134, 54, 74, 139,
125, 150, 75, 218, 121, 250, 31, 117, 47, 162, 157, 194, 69, 186, 133, 115, 242, 162, 176, 118, 37, 36, 199, 204,
48, 188, 32, 222, 47, 8, 50, 255, 65, 242, 217, 98, 117, 222, 231, 163, 249, 39, 242, 171, 198, 178, 215, 152, 183,
244, 100, 252, 241, 20, 41, 1, 172, 217, 134, 134, 28, 196, 27, 54, 131, 241, 102, 61, 128, 95, 176, 96, 9, 4, 166,
73, 223, 155, 168, 218, 138, 200, 82, 62, 58, 218, 194, 197, 206, 168, 26, 240, 137, 215, 129, 178, 249, 151, 64,
229, 134, 139, 114, 96, 16, 12, 107, 8, 73, 41, 169, 155, 119, 93, 227, 242, 168, 205, 51, 150, 46, 108, 208, 124,
250, 78, 128, 41, 206, 193, 25, 175, 120, 237, 234, 49, 201, 18, 24, 252, 37, 86, 158, 41, 41, 235, 242, 213, 28,
103, 133, 160, 120, 55, 15, 179, 14, 31, 31, 139, 222, 12, 128, 132, 59, 158, 234, 6, 179, 1, 201, 185, 220, 190,
223, 209, 106, 82, 62, 94, 247, 244, 77, 192, 69, 164, 111, 230, 121, 84, 177, 182, 71, 178, 45, 126, 15, 137, 94,
177, 114, 108, 221, 175, 222, 54, 146, 108, 153, 79, 37, 215, 228, 161, 188, 26, 92, 3, 172, 47, 80, 212, 208, 162,
233, 152, 103, 26, 215, 2, 163, 177, 45, 242, 210, 207, 104, 177, 99, 200, 172, 176, 121, 16, 197, 66, 87, 87, 35,
94, 29, 64, 241, 124, 160, 197, 36, 230, 248, 97, 7, 27, 232, 92, 191, 99, 165, 147, 154, 245, 13, 75, 250, 39, 66,
24, 244, 144, 220, 255, 149, 61, 87, 31, 71, 49, 209, 144, 242, 148, 86, 56, 119, 158, 177, 225, 222, 76, 193, 30,
142, 150, 19, 97, 83, 204, 84, 140, 174, 197, 89, 83, 31, 233, 211, 228, 81, 232, 235, 212, 142, 99, 228, 62, 71,
106, 166, 196, 71, 230, 139, 235, 232, 241, 248, 246, 38, 205, 9, 91, 79, 227, 174, 200, 60, 130, 3, 24, 24, 155,
15, 25, 45, 83, 116, 3, 181, 140, 206, 129, 192, 214, 77, 141, 33, 145, 121, 57, 217, 159, 232, 165, 116, 168, 96,
206, 219, 15, 11, 250, 30, 248, 184, 176, 71, 150, 65, 15, 98, 197, 125, 154, 14, 45, 211, 195, 122, 41, 85, 94,
207, 163, 163, 105, 192, 35, 127, 115, 61, 224, 48, 183, 174, 64, 32, 186, 191, 60, 124, 37, 198, 156, 118, 248,
153, 132, 119, 5, 209, 111, 194, 147, 115, 224, 54, 208, 87, 20, 254, 85, 188, 83, 254, 224, 67, 225, 4, 38, 213,
119, 170, 146, 106, 119, 88, 145, 242, 216, 69, 196, 31, 136, 1, 221, 218, 84, 223, 66, 250, 192, 221, 140, 172,
164, 64, 19, 176, 30, 10, 83, 49, 255, 132, 108, 151, 85, 143, 115, 37, 161, 71, 175, 78, 52, 35, 141, 157, 55, 163,
0, 123, 81, 176, 214, 183, 126, 88, 84, 132, 36, 91, 50, 193, 144, 188, 236, 229, 2, 26, 246, 238, 234, 103, 138,
237, 88, 91, 194, 39, 25, 211, 56, 208, 225, 172, 220, 89, 129, 242, 209, 3, 7, 47, 130, 139, 153, 197, 130, 151,
36, 117, 124, 251, 121, 115, 42, 57, 49, 108, 240, 100, 125, 209, 234, 176, 212, 13, 9, 105, 180, 23, 175, 95, 93,
7, 39, 146, 116, 47, 45, 190, 67, 82, 241, 202, 21, 149, 144, 212, 148, 59, 222, 171, 136, 230, 101, 13, 89, 201,
133, 211, 215, 235, 121, 9, 8, 148, 232, 195, 91, 2, 142, 108, 68, 100, 48, 44, 169, 84, 22, 35, 34, 255, 250, 164,
169, 28, 127, 60, 188, 135, 192, 210, 89, 108, 16, 74, 29, 41, 2, 248, 86, 134, 41, 109, 234, 112, 221, 17, 112, 55,
125, 100, 76, 12, 171, 153, 168, 210, 129, 255, 90, 108, 49, 26, 166, 250, 249, 101, 10, 16, 146, 197, 187, 179,
208, 97, 116, 254, 68, 162, 119, 191, 169, 251, 43, 175, 187, 225, 248, 142, 41, 117, 59, 123, 90, 167, 16, 66, 136,
43, 219, 222, 26, 111, 84, 173, 246, 1, 23, 7, 196, 41, 188, 135, 185, 220, 27, 160, 95, 196, 218, 42, 139, 58, 16,
249, 40, 200, 40, 133, 251, 121, 83, 194, 115, 49, 75, 194, 10, 158, 73, 135, 114, 156, 180, 172, 150, 189, 87, 203,
80, 32, 94, 89, 30, 222, 171, 23, 141, 11, 20, 205, 73, 140, 105, 10, 241, 15, 61, 171, 176, 217, 127, 220, 224, 99,
98, 47, 13, 148, 208, 101, 47, 82, 255, 52, 28, 174, 91, 49, 94, 93, 73, 124, 210, 161, 143, 62, 26, 0, 193, 188,
139, 159, 18, 22, 234, 141, 66, 141, 207, 142, 176, 215, 155, 14, 137, 156, 203, 76, 17, 68, 130, 10, 30, 31, 155,
119
}; // g_palPlatformJsonData[]
} // Pal
|
52337fecd3334c83c72a4f8ed195035cc306141f | 471f7992e0d610137dcc3addbec15fec1269d22e | /AshaEngine/AppSysClass.cpp | 084aff8b19eb6bb14e979f63eb1fce5480a01943 | [] | no_license | lazyrohan/Asha | 12bf4d9dff56e062239efb6a7ea7730e0b59151d | d0cba37dccca9ddde9de73cc864855c6a0deb9fd | refs/heads/master | 2021-01-10T19:00:30.565889 | 2014-03-30T14:21:05 | 2014-03-30T14:21:05 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 2,445 | cpp | AppSysClass.cpp | //AppSysClas.cpp
#include "AppSysClass.h"
AppSysClass::AppSysClass():
m_hInstance(NULL),
m_hWnd(NULL),
m_msg(NULL),
m_pAppGraph(NULL)
{
//Initialize globe variations
}
AppSysClass::~AppSysClass()
{
}
bool AppSysClass::Initialize(HINSTANCE hInstance,int nCmdShow,LPCSTR AppName,HCURSOR hCursor,HICON hIcon,RECT rc)
{
bool hr=true;
//Initialize windows
m_AppName=AppName;
m_hCursor=hCursor;
m_hIcon=hIcon;
m_rc=rc;
hr=InitializeWindows(hInstance,nCmdShow);
if(!hr)
{
return false;
}
//Initialize App graphic class
m_pAppGraph=new AshaGraphClass;
m_pAppGraph->Initialize(m_hWnd);
if (!hr)
{
return false;
}
return true;
}
bool AppSysClass::InitializeWindows(HINSTANCE hInstance,int nCmdShow)
{
//Initialize wnd class structure
WNDCLASSEX wcex;
wcex.cbSize=sizeof(WNDCLASSEX);
wcex.style=CS_HREDRAW|CS_VREDRAW;
wcex.lpfnWndProc=WndProc;
wcex.cbClsExtra=NULL;
wcex.cbWndExtra=NULL;
wcex.hInstance=m_hInstance=hInstance;
wcex.hIcon=m_hIcon;
wcex.hCursor=m_hCursor;
wcex.hbrBackground=(HBRUSH)(COLOR_WINDOW+1);
wcex.lpszMenuName=NULL;
wcex.lpszClassName=m_AppName;
wcex.hIconSm=NULL;
//Registe wnd class
if(!RegisterClassEx(&wcex))
return false;
//Create window
AdjustWindowRect(&m_rc,WS_OVERLAPPEDWINDOW,false);
m_hWnd=CreateWindow(m_AppName,m_AppName,WS_TILEDWINDOW,CW_USEDEFAULT,CW_USEDEFAULT,m_rc.right-m_rc.left,
m_rc.bottom-m_rc.top,NULL,NULL,hInstance,NULL);
if(!m_hWnd)
return false;
//show window
ShowWindow(m_hWnd,nCmdShow);
return true;
}
void AppSysClass::Run()
{
bool done=true;
//Main message loop
m_msg=new MSG;
while(done)
{
if(PeekMessageA(m_msg,NULL,0,0,PM_REMOVE))
{
TranslateMessage(m_msg);
DispatchMessage(m_msg);
}
if(m_msg->message==WM_QUIT)
done=false;
else
{
done=true;
m_pAppGraph->Render();
}
}
return;
}
int AppSysClass::Exit()
{
//Release app graphic class
m_pAppGraph->Release();
delete m_pAppGraph;
m_pAppGraph=NULL;
//Destroy window
DestroyWindow(m_hWnd);
return ( int )m_msg->wParam;
}
LRESULT CALLBACK WndProc(HWND hWnd,UINT message,WPARAM wParam,LPARAM lParam)
{
/*
PAINTSTRUCT ps;
HDC hdc;
*/
switch(message)
{
/*
case WM_PAINT:
{
hdc=BeginPaint(hWnd,&ps);
TextOutW(hdc,0,0,L"Test",4);
EndPaint(hWnd,&ps);
break;
}
*/
case WM_DESTROY:
PostQuitMessage(0);
break;
default:
return DefWindowProc(hWnd,message,wParam,lParam);
}
return 0;
} |
3bc6eb234f1c9b0e3afcde29a606803917c32f31 | d5d3559b8a31bc571f79e108fe7420c508c45998 | /valid_anagram.cpp | d6ff7e6955e2ce957df940dc42969afaa439fa84 | [] | no_license | drkarthi/algo | d9584f084c4057a1d24f0a395c05464a33da51d4 | 74f205bcd5e4865354dccbe82b824685189d4ab1 | refs/heads/master | 2021-01-22T11:11:02.124512 | 2017-06-12T19:53:13 | 2017-06-12T19:53:13 | 50,313,288 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 609 | cpp | valid_anagram.cpp | class Solution {
public:
vector<int>& updateHashTable(string a, vector<int>& hash){
int i=0, index;
while(a[i]!='\0'){
index = int(a[i]) - 97;
hash[index] += 1;
i++;
}
return hash;
}
bool isAnagram(string s, string t) {
vector<int> hash_s (26,0);
vector<int> hash_t (26,0);
hash_s = updateHashTable(s, hash_s);
hash_t = updateHashTable(t, hash_t);
int i;
for(i=0;i<26;i++){
if(hash_s[i]!=hash_t[i])
return false;
}
return true;
}
}; |
853b05bf1ee029bbd2c2bc86fcd422b658d8ce35 | cf39355caa609c0f33405126beee2739aa3cb77e | /src/library/vm/vm_int.h | 3d8566db8aa7850637f83a1928b528a235f16751 | [
"Apache-2.0"
] | permissive | leanprover-community/lean | 12b87f69d92e614daea8bcc9d4de9a9ace089d0e | cce7990ea86a78bdb383e38ed7f9b5ba93c60ce0 | refs/heads/master | 2023-06-23T08:15:56.644949 | 2023-05-24T17:58:24 | 2023-05-24T17:58:24 | 169,960,991 | 457 | 107 | Apache-2.0 | 2023-06-14T12:06:12 | 2019-02-10T09:17:48 | C++ | UTF-8 | C++ | false | false | 647 | h | vm_int.h | /*
Copyright (c) 2016 Microsoft Corporation. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Author: Leonardo de Moura
*/
#pragma once
#include "library/vm/vm.h"
namespace lean {
int to_int(vm_obj const & o);
optional<int> try_to_int(vm_obj const & o);
int force_to_int(vm_obj const & o, int def);
vm_obj mk_vm_int(int n);
vm_obj mk_vm_int(unsigned int n);
vm_obj mk_vm_int(long n);
vm_obj mk_vm_int(unsigned long n);
vm_obj mk_vm_int(long long n);
vm_obj mk_vm_int(unsigned long long n);
vm_obj mk_vm_int(double n);
vm_obj mk_vm_int(mpz const & n);
void initialize_vm_int();
void finalize_vm_int();
}
|
81190e73aa48889d1af38f636b540e9b2014638a | 04124ba853c034ee69875f21a04131f41bbe139f | /workspace/ns-allinone-3.28/ns-3.28/scratch/new_adhoc_test.cc | 88d14e325efff20621b7742911debd8e70dbc639 | [] | no_license | h-d/Senior-Research | 5c16d47a814a96e55255eff78d009ca9cca26200 | a3e9343afc99a3e6b1325eda1890354ecd468f7c | refs/heads/master | 2020-04-24T01:38:51.498264 | 2019-04-17T07:36:54 | 2019-04-17T07:36:54 | 171,606,676 | 0 | 1 | null | null | null | null | UTF-8 | C++ | false | false | 8,859 | cc | new_adhoc_test.cc | #include "ns3/core-module.h"
#include "ns3/network-module.h"
#include "ns3/mobility-module.h"
#include "ns3/config-store-module.h"
#include "ns3/wifi-module.h"
#include "ns3/internet-module.h"
#include "ns3/aodv-module.h"
#include "ns3/dsr-module.h"
#include "ns3/olsr-module.h"
#include "ns3/dsdv-module.h"
#include "ns3/ipv4-static-routing-helper.h"
#include "ns3/ipv4-list-routing-helper.h"
#include "ns3/applications-module.h"
#include "ns3/netanim-module.h"
#include "ns3/constant-velocity-mobility-model.h"
#include "ns3/flow-monitor-module.h"
#include "ns3/stats-module.h"
#include <iostream>
#include <fstream>
#include <vector>
#include <string>
NS_LOG_COMPONENT_DEFINE ("scenario");
using namespace ns3;
using namespace dsr;
Ptr<ConstantVelocityMobilityModel> cvmm;
double position_interval = 1.0;
std::string tracebase = "scratch/scenario";
//std::string protocol;
Ptr < Node> mover= CreateObject < Node>();
// two callbacks
void printPosition()
{
Vector thePos = cvmm->GetPosition();
Simulator::Schedule(Seconds(position_interval), &printPosition);
std::cout << "position: " << thePos << std::endl;
}
void stopMover()
{
cvmm -> SetVelocity(Vector(0,0,0));
}
void PrintRoutingTable (Ptr<Node> node)
{
/* Ptr<ns3::aodv::RoutingProtocol> routing = node->GetObject<ns3::aodv::RoutingProtocol>();
// Print routing table entries for OLSR routing
std::vector<ns3::aodv::RoutingTableEntry> entry = routing->m_routingTable;
std::cout << "Routing table for device: " << Names::FindName(node) << std::endl;
std::cout << "Routing table for device: " << node->GetId() << std::endl;
std::cout << "DestinyAddress\t\tNextAddress\t\tInterface\t\tDistance\n";
for (std::vector<ns3::aodv::RoutingTableEntry, std::allocator<ns3::aodv::RoutingTableEntry>>::iterator i =entry.begin(); i!=entry.end(); i++)
{
std::cout << i->destAddr << "\t\t"<< i->nextAddr << "\t\t"<< i->interface << "\t\t"<< i->distance << std::endl;
}
*/
}
int main (int argc, char *argv[])
{
// Dsss options: DsssRate1Mbps, DsssRate2Mbps, DsssRate5_5Mbps, DsssRate11Mbps
// also ErpOfdmRate to 54 Mbps and OfdmRate to 150Mbps w 40MHz band-width
std::string phyMode = "DsssRate1Mbps";
//phyMode = "DsssRate11Mbps";
int bottomrow = 100; // number of bottom-row nodes
int spacing = 100; // between bottom-row nodes
int mheight = 150; // height of mover above bottom row
int brheight = 50; // height of bottom row
int X = (5-1)*spacing+1; // X and Y are the dimensions of the field
int packetsize = 500;
double factor = 1.0; // allows slowing down rate and extending runtime; same total # of packets
int endtime = (int)100*factor;
double speed = (X-1.0)/endtime;
double bitrate = 80*1000.0/factor; // bits/sec
uint32_t interval = 1000*packetsize*8/bitrate*1000; // in microsec, computed from packetsize and bitrate
uint32_t packetcount = 1000000*endtime/ interval;
std::cout << "interval = " << interval <<", rate=" << bitrate << ", packetcount=" << packetcount << std::endl;
CommandLine cmd; // no options, actually
cmd.Parse (argc, argv);
// disable fragmentation for frames below 2200 bytes
Config::SetDefault ("ns3::WifiRemoteStationManager::FragmentationThreshold", StringValue ("2200"));
// turn off RTS/CTS for frames below 2200 bytes
Config::SetDefault ("ns3::WifiRemoteStationManager::RtsCtsThreshold", StringValue ("2200"));
// Set non-unicast data rate to be the same as that of unicast
Config::SetDefault ("ns3::WifiRemoteStationManager::NonUnicastMode", StringValue (phyMode));
// Create nodes
NodeContainer fixedpos;
fixedpos.Create(bottomrow);
Ptr<Node> lowerleft = fixedpos.Get(0);
// The below set of helpers will help us to put together the desired Wi-Fi behavior
WifiHelper wifi;
wifi.SetStandard (WIFI_PHY_STANDARD_80211b);
wifi.SetRemoteStationManager ("ns3::AarfWifiManager"); // Use AARF rate control
// to view AARF rate changes, set in the shell NS_LOG=AarfWifiManager=level_debug
// The PHY layer here is "yans"
YansWifiPhyHelper wifiPhyHelper = YansWifiPhyHelper::Default ();
// for .pcap tracing
wifiPhyHelper.SetPcapDataLinkType (YansWifiPhyHelper::DLT_IEEE802_11_RADIO);
YansWifiChannelHelper wifiChannelHelper; // *not* ::Default() !
wifiChannelHelper.SetPropagationDelay ("ns3::ConstantSpeedPropagationDelayModel"); // pld: default?
// the following has an absolute cutoff at distance > 250
wifiChannelHelper.AddPropagationLoss ("ns3::RangePropagationLossModel", "MaxRange", DoubleValue(250));
Ptr<YansWifiChannel> pchan = wifiChannelHelper.Create ();
wifiPhyHelper.SetChannel (pchan);
// Add a non-QoS upper-MAC layer "AdhocWifiMac", and set rate control
WifiMacHelper wifiMacHelper;
wifiMacHelper.SetType ("ns3::AdhocWifiMac");
NetDeviceContainer devices = wifi.Install (wifiPhyHelper, wifiMacHelper, fixedpos);
//devices.Add (wifi.Install (wifiPhyHelper, wifiMacHelper, mover));
// set positions.
MobilityHelper sessile; // for fixed nodes
Ptr<ListPositionAllocator> positionAlloc = CreateObject<ListPositionAllocator> ();
int Ypos = 0;
for (int t = 0; t < 10; t++)
{
int Xpos = 0;
for (int i=0; i<10; i++) {
positionAlloc->Add(Vector(Xpos, Ypos, 0.0));
Xpos += spacing;
}
Ypos+=spacing*2;
}
sessile.SetPositionAllocator (positionAlloc);
sessile.SetMobilityModel ("ns3::ConstantPositionMobilityModel");
sessile.Install (fixedpos);
// ConstantVelocityMobilityModel is a subclass of MobilityModel
Vector pos (0, mheight+brheight, 0);
Vector vel (speed, 0, 0);
MobilityHelper mobile;
mobile.SetMobilityModel("ns3::ConstantVelocityMobilityModel"); // no Attributes
mobile.Install(mover);
cvmm = mover->GetObject<ConstantVelocityMobilityModel> ();
cvmm->SetPosition(pos);
cvmm->SetVelocity(vel);
AodvHelper aodv;
OlsrHelper olsr;
DsrHelper dsr;
DsrMainHelper dsrMain;
Ipv4ListRoutingHelper listrouting;
listrouting.Add(olsr, 100); // generates less traffic
//listrouting.Add(dsr,100);
//listrouting.Add(aodv, 900); // fastest to find new routes
InternetStackHelper internet;
internet.SetRoutingHelper(listrouting);
internet.Install (fixedpos);
//dsrMain.Install(dsr,fixedpos);
//internet.Install (mover);
Ipv4AddressHelper ipv4;
NS_LOG_INFO ("Assign IP Addresses.");
ipv4.SetBase ("10.1.0.0", "255.255.0.0"); // there is only one subnet
Ipv4InterfaceContainer i = ipv4.Assign (devices);
uint16_t port = 80;
// create a receiving application (UdpServer) on node mover
Address sinkaddr(InetSocketAddress (Ipv4Address::GetAny(), port));
Config::SetDefault("ns3::UdpServer::Port", UintegerValue(port));
//-----sample
Ptr<UdpServer> UdpRecvApp = CreateObject<UdpServer>();
UdpRecvApp->SetStartTime(Seconds(0.0));
UdpRecvApp->SetStopTime(Seconds(endtime));
// mover->AddApplication(UdpRecvApp);
// mover definition needed
// Tracing
wifiPhyHelper.EnablePcap (tracebase, devices);
AsciiTraceHelper ascii;
wifiPhyHelper.EnableAsciiAll (ascii.CreateFileStream (tracebase + ".tr"));
// create animation file, to be run with 'netanim'
AnimationInterface anim (tracebase + ".xml");
anim.SetMobilityPollInterval(Seconds(0.1));
// uncomment the next line to verify that node 'mover' is actually moving
//Simulator::Schedule(Seconds(position_interval), &printPosition);
//Simulator::Schedule(Seconds(endtime), &stopMover);
anim.UpdateNodeDescription (fixedpos.Get(0), "AP");
Simulator::Stop(Seconds (30));
FlowMonitorHelper flowmon;
Ptr<FlowMonitor> monitor = flowmon.Install(fixedpos);
monitor = flowmon.GetMonitor();
Simulator::Run ();
for (uint32_t i = 0; i < fixedpos.GetN(); i++)
{
PrintRoutingTable(fixedpos.Get(i));
}
monitor->CheckForLostPackets();
Ptr<Ipv4FlowClassifier> classifier = DynamicCast<Ipv4FlowClassifier> (flowmon.GetClassifier ());
std::map<FlowId, FlowMonitor::FlowStats> stats = monitor->GetFlowStats();
for(std::map<FlowId, FlowMonitor::FlowStats>::const_iterator i = stats.begin (); i != stats.end (); ++i)
{
Ipv4FlowClassifier::FiveTuple t = classifier->FindFlow (i->first);
std::cout << " Flow " << i->first << " (" << t.sourceAddress << " -> " << t.destinationAddress << ")\n";
std::cout << " Tx Bytes: " << i->second.txBytes << "\n";
std::cout << " Rx Bytes: " << i->second.rxBytes << "\n";
std::cout << " Throughput: " << i->second.rxBytes * 8.0 / 10.0 / 1024 / 1024 << " Mbps\n";
}
monitor->SerializeToXmlFile("FlowStats.xml",true,true);
Simulator::Destroy ();
return 0;
}
|
e5e3afbee8094a33a92c1ba390e4ec6ffd1dac0e | f1ac5501fd36e4e420dfbc912890b4c848e4acc3 | /src/crypto/haraka_portable.cpp | 78daf6ce9efb6f129e4267011fbfded0cba20b0e | [] | no_license | whojan/KomodoOcean | 20ca84ea11ed791c407bed17b155134b640796e8 | f604a95d848222af07db0005c33dc4852b5203a3 | refs/heads/master | 2022-08-07T13:10:15.341628 | 2019-06-14T17:27:57 | 2019-06-14T17:27:57 | 274,690,003 | 1 | 0 | null | 2020-06-24T14:28:50 | 2020-06-24T14:28:49 | null | UTF-8 | C++ | false | false | 13,218 | cpp | haraka_portable.cpp | /*
Plain C implementation of the Haraka256 and Haraka512 permutations.
*/
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
#include "haraka_portable.h"
#define HARAKAS_RATE 32
static const unsigned char haraka_rc[40][16] = {
{0x9d, 0x7b, 0x81, 0x75, 0xf0, 0xfe, 0xc5, 0xb2, 0x0a, 0xc0, 0x20, 0xe6, 0x4c, 0x70, 0x84, 0x06},
{0x17, 0xf7, 0x08, 0x2f, 0xa4, 0x6b, 0x0f, 0x64, 0x6b, 0xa0, 0xf3, 0x88, 0xe1, 0xb4, 0x66, 0x8b},
{0x14, 0x91, 0x02, 0x9f, 0x60, 0x9d, 0x02, 0xcf, 0x98, 0x84, 0xf2, 0x53, 0x2d, 0xde, 0x02, 0x34},
{0x79, 0x4f, 0x5b, 0xfd, 0xaf, 0xbc, 0xf3, 0xbb, 0x08, 0x4f, 0x7b, 0x2e, 0xe6, 0xea, 0xd6, 0x0e},
{0x44, 0x70, 0x39, 0xbe, 0x1c, 0xcd, 0xee, 0x79, 0x8b, 0x44, 0x72, 0x48, 0xcb, 0xb0, 0xcf, 0xcb},
{0x7b, 0x05, 0x8a, 0x2b, 0xed, 0x35, 0x53, 0x8d, 0xb7, 0x32, 0x90, 0x6e, 0xee, 0xcd, 0xea, 0x7e},
{0x1b, 0xef, 0x4f, 0xda, 0x61, 0x27, 0x41, 0xe2, 0xd0, 0x7c, 0x2e, 0x5e, 0x43, 0x8f, 0xc2, 0x67},
{0x3b, 0x0b, 0xc7, 0x1f, 0xe2, 0xfd, 0x5f, 0x67, 0x07, 0xcc, 0xca, 0xaf, 0xb0, 0xd9, 0x24, 0x29},
{0xee, 0x65, 0xd4, 0xb9, 0xca, 0x8f, 0xdb, 0xec, 0xe9, 0x7f, 0x86, 0xe6, 0xf1, 0x63, 0x4d, 0xab},
{0x33, 0x7e, 0x03, 0xad, 0x4f, 0x40, 0x2a, 0x5b, 0x64, 0xcd, 0xb7, 0xd4, 0x84, 0xbf, 0x30, 0x1c},
{0x00, 0x98, 0xf6, 0x8d, 0x2e, 0x8b, 0x02, 0x69, 0xbf, 0x23, 0x17, 0x94, 0xb9, 0x0b, 0xcc, 0xb2},
{0x8a, 0x2d, 0x9d, 0x5c, 0xc8, 0x9e, 0xaa, 0x4a, 0x72, 0x55, 0x6f, 0xde, 0xa6, 0x78, 0x04, 0xfa},
{0xd4, 0x9f, 0x12, 0x29, 0x2e, 0x4f, 0xfa, 0x0e, 0x12, 0x2a, 0x77, 0x6b, 0x2b, 0x9f, 0xb4, 0xdf},
{0xee, 0x12, 0x6a, 0xbb, 0xae, 0x11, 0xd6, 0x32, 0x36, 0xa2, 0x49, 0xf4, 0x44, 0x03, 0xa1, 0x1e},
{0xa6, 0xec, 0xa8, 0x9c, 0xc9, 0x00, 0x96, 0x5f, 0x84, 0x00, 0x05, 0x4b, 0x88, 0x49, 0x04, 0xaf},
{0xec, 0x93, 0xe5, 0x27, 0xe3, 0xc7, 0xa2, 0x78, 0x4f, 0x9c, 0x19, 0x9d, 0xd8, 0x5e, 0x02, 0x21},
{0x73, 0x01, 0xd4, 0x82, 0xcd, 0x2e, 0x28, 0xb9, 0xb7, 0xc9, 0x59, 0xa7, 0xf8, 0xaa, 0x3a, 0xbf},
{0x6b, 0x7d, 0x30, 0x10, 0xd9, 0xef, 0xf2, 0x37, 0x17, 0xb0, 0x86, 0x61, 0x0d, 0x70, 0x60, 0x62},
{0xc6, 0x9a, 0xfc, 0xf6, 0x53, 0x91, 0xc2, 0x81, 0x43, 0x04, 0x30, 0x21, 0xc2, 0x45, 0xca, 0x5a},
{0x3a, 0x94, 0xd1, 0x36, 0xe8, 0x92, 0xaf, 0x2c, 0xbb, 0x68, 0x6b, 0x22, 0x3c, 0x97, 0x23, 0x92},
{0xb4, 0x71, 0x10, 0xe5, 0x58, 0xb9, 0xba, 0x6c, 0xeb, 0x86, 0x58, 0x22, 0x38, 0x92, 0xbf, 0xd3},
{0x8d, 0x12, 0xe1, 0x24, 0xdd, 0xfd, 0x3d, 0x93, 0x77, 0xc6, 0xf0, 0xae, 0xe5, 0x3c, 0x86, 0xdb},
{0xb1, 0x12, 0x22, 0xcb, 0xe3, 0x8d, 0xe4, 0x83, 0x9c, 0xa0, 0xeb, 0xff, 0x68, 0x62, 0x60, 0xbb},
{0x7d, 0xf7, 0x2b, 0xc7, 0x4e, 0x1a, 0xb9, 0x2d, 0x9c, 0xd1, 0xe4, 0xe2, 0xdc, 0xd3, 0x4b, 0x73},
{0x4e, 0x92, 0xb3, 0x2c, 0xc4, 0x15, 0x14, 0x4b, 0x43, 0x1b, 0x30, 0x61, 0xc3, 0x47, 0xbb, 0x43},
{0x99, 0x68, 0xeb, 0x16, 0xdd, 0x31, 0xb2, 0x03, 0xf6, 0xef, 0x07, 0xe7, 0xa8, 0x75, 0xa7, 0xdb},
{0x2c, 0x47, 0xca, 0x7e, 0x02, 0x23, 0x5e, 0x8e, 0x77, 0x59, 0x75, 0x3c, 0x4b, 0x61, 0xf3, 0x6d},
{0xf9, 0x17, 0x86, 0xb8, 0xb9, 0xe5, 0x1b, 0x6d, 0x77, 0x7d, 0xde, 0xd6, 0x17, 0x5a, 0xa7, 0xcd},
{0x5d, 0xee, 0x46, 0xa9, 0x9d, 0x06, 0x6c, 0x9d, 0xaa, 0xe9, 0xa8, 0x6b, 0xf0, 0x43, 0x6b, 0xec},
{0xc1, 0x27, 0xf3, 0x3b, 0x59, 0x11, 0x53, 0xa2, 0x2b, 0x33, 0x57, 0xf9, 0x50, 0x69, 0x1e, 0xcb},
{0xd9, 0xd0, 0x0e, 0x60, 0x53, 0x03, 0xed, 0xe4, 0x9c, 0x61, 0xda, 0x00, 0x75, 0x0c, 0xee, 0x2c},
{0x50, 0xa3, 0xa4, 0x63, 0xbc, 0xba, 0xbb, 0x80, 0xab, 0x0c, 0xe9, 0x96, 0xa1, 0xa5, 0xb1, 0xf0},
{0x39, 0xca, 0x8d, 0x93, 0x30, 0xde, 0x0d, 0xab, 0x88, 0x29, 0x96, 0x5e, 0x02, 0xb1, 0x3d, 0xae},
{0x42, 0xb4, 0x75, 0x2e, 0xa8, 0xf3, 0x14, 0x88, 0x0b, 0xa4, 0x54, 0xd5, 0x38, 0x8f, 0xbb, 0x17},
{0xf6, 0x16, 0x0a, 0x36, 0x79, 0xb7, 0xb6, 0xae, 0xd7, 0x7f, 0x42, 0x5f, 0x5b, 0x8a, 0xbb, 0x34},
{0xde, 0xaf, 0xba, 0xff, 0x18, 0x59, 0xce, 0x43, 0x38, 0x54, 0xe5, 0xcb, 0x41, 0x52, 0xf6, 0x26},
{0x78, 0xc9, 0x9e, 0x83, 0xf7, 0x9c, 0xca, 0xa2, 0x6a, 0x02, 0xf3, 0xb9, 0x54, 0x9a, 0xe9, 0x4c},
{0x35, 0x12, 0x90, 0x22, 0x28, 0x6e, 0xc0, 0x40, 0xbe, 0xf7, 0xdf, 0x1b, 0x1a, 0xa5, 0x51, 0xae},
{0xcf, 0x59, 0xa6, 0x48, 0x0f, 0xbc, 0x73, 0xc1, 0x2b, 0xd2, 0x7e, 0xba, 0x3c, 0x61, 0xc1, 0xa0},
{0xa1, 0x9d, 0xc5, 0xe9, 0xfd, 0xbd, 0xd6, 0x4a, 0x88, 0x82, 0x28, 0x02, 0x03, 0xcc, 0x6a, 0x75}
};
static unsigned char rc[40][16];
static unsigned char rc0[40][16];
static unsigned char rc_sseed[40][16];
static const unsigned char sbox[256] =
{ 0x63, 0x7c, 0x77, 0x7b, 0xf2, 0x6b, 0x6f, 0xc5, 0x30, 0x01, 0x67, 0x2b, 0xfe,
0xd7, 0xab, 0x76, 0xca, 0x82, 0xc9, 0x7d, 0xfa, 0x59, 0x47, 0xf0, 0xad, 0xd4,
0xa2, 0xaf, 0x9c, 0xa4, 0x72, 0xc0, 0xb7, 0xfd, 0x93, 0x26, 0x36, 0x3f, 0xf7,
0xcc, 0x34, 0xa5, 0xe5, 0xf1, 0x71, 0xd8, 0x31, 0x15, 0x04, 0xc7, 0x23, 0xc3,
0x18, 0x96, 0x05, 0x9a, 0x07, 0x12, 0x80, 0xe2, 0xeb, 0x27, 0xb2, 0x75, 0x09,
0x83, 0x2c, 0x1a, 0x1b, 0x6e, 0x5a, 0xa0, 0x52, 0x3b, 0xd6, 0xb3, 0x29, 0xe3,
0x2f, 0x84, 0x53, 0xd1, 0x00, 0xed, 0x20, 0xfc, 0xb1, 0x5b, 0x6a, 0xcb, 0xbe,
0x39, 0x4a, 0x4c, 0x58, 0xcf, 0xd0, 0xef, 0xaa, 0xfb, 0x43, 0x4d, 0x33, 0x85,
0x45, 0xf9, 0x02, 0x7f, 0x50, 0x3c, 0x9f, 0xa8, 0x51, 0xa3, 0x40, 0x8f, 0x92,
0x9d, 0x38, 0xf5, 0xbc, 0xb6, 0xda, 0x21, 0x10, 0xff, 0xf3, 0xd2, 0xcd, 0x0c,
0x13, 0xec, 0x5f, 0x97, 0x44, 0x17, 0xc4, 0xa7, 0x7e, 0x3d, 0x64, 0x5d, 0x19,
0x73, 0x60, 0x81, 0x4f, 0xdc, 0x22, 0x2a, 0x90, 0x88, 0x46, 0xee, 0xb8, 0x14,
0xde, 0x5e, 0x0b, 0xdb, 0xe0, 0x32, 0x3a, 0x0a, 0x49, 0x06, 0x24, 0x5c, 0xc2,
0xd3, 0xac, 0x62, 0x91, 0x95, 0xe4, 0x79, 0xe7, 0xc8, 0x37, 0x6d, 0x8d, 0xd5,
0x4e, 0xa9, 0x6c, 0x56, 0xf4, 0xea, 0x65, 0x7a, 0xae, 0x08, 0xba, 0x78, 0x25,
0x2e, 0x1c, 0xa6, 0xb4, 0xc6, 0xe8, 0xdd, 0x74, 0x1f, 0x4b, 0xbd, 0x8b, 0x8a,
0x70, 0x3e, 0xb5, 0x66, 0x48, 0x03, 0xf6, 0x0e, 0x61, 0x35, 0x57, 0xb9, 0x86,
0xc1, 0x1d, 0x9e, 0xe1, 0xf8, 0x98, 0x11, 0x69, 0xd9, 0x8e, 0x94, 0x9b, 0x1e,
0x87, 0xe9, 0xce, 0x55, 0x28, 0xdf, 0x8c, 0xa1, 0x89, 0x0d, 0xbf, 0xe6, 0x42,
0x68, 0x41, 0x99, 0x2d, 0x0f, 0xb0, 0x54, 0xbb, 0x16 };
#define XT(x) (((x) << 1) ^ ((((x) >> 7) & 1) * 0x1b))
// Simulate _mm_aesenc_si128 instructions from AESNI
void aesenc(unsigned char *s, const unsigned char *rk)
{
unsigned char i, t, u, v[4][4];
for (i = 0; i < 16; ++i) {
v[((i / 4) + 4 - (i%4) ) % 4][i % 4] = sbox[s[i]];
}
for (i = 0; i < 4; ++i) {
t = v[i][0];
u = v[i][0] ^ v[i][1] ^ v[i][2] ^ v[i][3];
v[i][0] ^= u ^ XT(v[i][0] ^ v[i][1]);
v[i][1] ^= u ^ XT(v[i][1] ^ v[i][2]);
v[i][2] ^= u ^ XT(v[i][2] ^ v[i][3]);
v[i][3] ^= u ^ XT(v[i][3] ^ t);
}
for (i = 0; i < 16; ++i) {
s[i] = v[i / 4][i % 4] ^ rk[i];
}
}
// Simulate _mm_unpacklo_epi32
void unpacklo32(unsigned char *t, unsigned char *a, unsigned char *b)
{
unsigned char tmp[16];
memcpy(tmp, a, 4);
memcpy(tmp + 4, b, 4);
memcpy(tmp + 8, a + 4, 4);
memcpy(tmp + 12, b + 4, 4);
memcpy(t, tmp, 16);
}
// Simulate _mm_unpackhi_epi32
void unpackhi32(unsigned char *t, unsigned char *a, unsigned char *b)
{
unsigned char tmp[16];
memcpy(tmp, a + 8, 4);
memcpy(tmp + 4, b + 8, 4);
memcpy(tmp + 8, a + 12, 4);
memcpy(tmp + 12, b + 12, 4);
memcpy(t, tmp, 16);
}
void load_constants_port()
{
/* Use the standard constants to generate tweaked ones. */
memcpy(rc, haraka_rc, 40*16);
}
//void tweak_constants(const unsigned char *pk_seed, const unsigned char *sk_seed,
// unsigned long long seed_length)
//{
// unsigned char buf[40*16];
//
// /* Use the standard constants to generate tweaked ones. */
// memcpy(rc, haraka_rc, 40*16);
//
// /* Constants for sk.seed */
// if (sk_seed != NULL) {
// haraka_S(buf, 40*16, sk_seed, seed_length);
// memcpy(rc_sseed, buf, 40*16);
// }
//
// /* Constants for pk.seed */
// haraka_S(buf, 40*16, pk_seed, seed_length);
// memcpy(rc, buf, 40*16);
//}
/*
static void haraka_S_absorb(unsigned char *s, unsigned int r,
const unsigned char *m, unsigned long long mlen,
unsigned char p)
{
unsigned long long i;
unsigned char t[r];
while (mlen >= r) {
// XOR block to state
for (i = 0; i < r; ++i) {
s[i] ^= m[i];
}
haraka512_perm(s, s);
mlen -= r;
m += r;
}
for (i = 0; i < r; ++i) {
t[i] = 0;
}
for (i = 0; i < mlen; ++i) {
t[i] = m[i];
}
t[i] = p;
t[r - 1] |= 128;
for (i = 0; i < r; ++i) {
s[i] ^= t[i];
}
}
*/
static void haraka_S_squeezeblocks(unsigned char *h, unsigned long long nblocks,
unsigned char *s, unsigned int r)
{
while (nblocks > 0) {
haraka512_perm(s, s);
memcpy(h, s, HARAKAS_RATE);
h += r;
nblocks--;
}
}
/*
void haraka_S(unsigned char *out, unsigned long long outlen,
const unsigned char *in, unsigned long long inlen)
{
unsigned long long i;
unsigned char s[64];
unsigned char d[32];
for (i = 0; i < 64; i++) {
s[i] = 0;
}
haraka_S_absorb(s, 32, in, inlen, 0x1F);
haraka_S_squeezeblocks(out, outlen / 32, s, 32);
out += (outlen / 32) * 32;
if (outlen % 32) {
haraka_S_squeezeblocks(d, 1, s, 32);
for (i = 0; i < outlen % 32; i++) {
out[i] = d[i];
}
}
}
*/
void haraka512_perm(unsigned char *out, const unsigned char *in)
{
int i, j;
unsigned char s[64], tmp[16];
memcpy(s, in, 16);
memcpy(s + 16, in + 16, 16);
memcpy(s + 32, in + 32, 16);
memcpy(s + 48, in + 48, 16);
for (i = 0; i < 5; ++i) {
// aes round(s)
for (j = 0; j < 2; ++j) {
aesenc(s, rc[4*2*i + 4*j]);
aesenc(s + 16, rc[4*2*i + 4*j + 1]);
aesenc(s + 32, rc[4*2*i + 4*j + 2]);
aesenc(s + 48, rc[4*2*i + 4*j + 3]);
}
// mixing
unpacklo32(tmp, s, s + 16);
unpackhi32(s, s, s + 16);
unpacklo32(s + 16, s + 32, s + 48);
unpackhi32(s + 32, s + 32, s + 48);
unpacklo32(s + 48, s, s + 32);
unpackhi32(s, s, s + 32);
unpackhi32(s + 32, s + 16, tmp);
unpacklo32(s + 16, s + 16, tmp);
}
memcpy(out, s, 64);
}
void haraka512_port(unsigned char *out, const unsigned char *in)
{
int i;
unsigned char buf[64];
haraka512_perm(buf, in);
/* Feed-forward */
for (i = 0; i < 64; i++) {
buf[i] = buf[i] ^ in[i];
}
/* Truncated */
memcpy(out, buf + 8, 8);
memcpy(out + 8, buf + 24, 8);
memcpy(out + 16, buf + 32, 8);
memcpy(out + 24, buf + 48, 8);
}
void haraka512_perm_zero(unsigned char *out, const unsigned char *in)
{
int i, j;
unsigned char s[64], tmp[16];
memcpy(s, in, 16);
memcpy(s + 16, in + 16, 16);
memcpy(s + 32, in + 32, 16);
memcpy(s + 48, in + 48, 16);
for (i = 0; i < 5; ++i) {
// aes round(s)
for (j = 0; j < 2; ++j) {
aesenc(s, rc0[4*2*i + 4*j]);
aesenc(s + 16, rc0[4*2*i + 4*j + 1]);
aesenc(s + 32, rc0[4*2*i + 4*j + 2]);
aesenc(s + 48, rc0[4*2*i + 4*j + 3]);
}
// mixing
unpacklo32(tmp, s, s + 16);
unpackhi32(s, s, s + 16);
unpacklo32(s + 16, s + 32, s + 48);
unpackhi32(s + 32, s + 32, s + 48);
unpacklo32(s + 48, s, s + 32);
unpackhi32(s, s, s + 32);
unpackhi32(s + 32, s + 16, tmp);
unpacklo32(s + 16, s + 16, tmp);
}
memcpy(out, s, 64);
}
void haraka512_port_zero(unsigned char *out, const unsigned char *in)
{
int i;
unsigned char buf[64];
haraka512_perm_zero(buf, in);
/* Feed-forward */
for (i = 0; i < 64; i++) {
buf[i] = buf[i] ^ in[i];
}
/* Truncated */
memcpy(out, buf + 8, 8);
memcpy(out + 8, buf + 24, 8);
memcpy(out + 16, buf + 32, 8);
memcpy(out + 24, buf + 48, 8);
}
void haraka256_port(unsigned char *out, const unsigned char *in)
{
int i, j;
unsigned char s[32], tmp[16];
memcpy(s, in, 16);
memcpy(s + 16, in + 16, 16);
for (i = 0; i < 5; ++i) {
// aes round(s)
for (j = 0; j < 2; ++j) {
aesenc(s, rc[2*2*i + 2*j]);
aesenc(s + 16, rc[2*2*i + 2*j + 1]);
}
// mixing
unpacklo32(tmp, s, s + 16);
unpackhi32(s + 16, s, s + 16);
memcpy(s, tmp, 16);
}
/* Feed-forward */
for (i = 0; i < 32; i++) {
out[i] = in[i] ^ s[i];
}
}
void haraka256_sk(unsigned char *out, const unsigned char *in)
{
int i, j;
unsigned char s[32], tmp[16];
memcpy(s, in, 16);
memcpy(s + 16, in + 16, 16);
for (i = 0; i < 5; ++i) {
// aes round(s)
for (j = 0; j < 2; ++j) {
aesenc(s, rc_sseed[2*2*i + 2*j]);
aesenc(s + 16, rc_sseed[2*2*i + 2*j + 1]);
}
// mixing
unpacklo32(tmp, s, s + 16);
unpackhi32(s + 16, s, s + 16);
memcpy(s, tmp, 16);
}
/* Feed-forward */
for (i = 0; i < 32; i++) {
out[i] = in[i] ^ s[i];
}
}
|
1edd923698fc920ed8e5b7d7c1beb4fe1415a848 | ece3aab795ce33ce3e2b4c281c99d54cc465b5c1 | /Cifera.cpp | 7a788081ca1312560c0261279acaf6470797beca | [] | no_license | Rakib-Ahasan/Codeforces-Solutions | d6180f4f15cfb7ebd463d5f0b50a63d4c859ca4f | c3532b552c268117b0f8ec995343106a33130d15 | refs/heads/master | 2023-04-26T04:52:52.537194 | 2021-05-24T13:54:31 | 2021-05-24T13:54:31 | 370,369,378 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 219 | cpp | Cifera.cpp | #include<iostream>
using namespace std;
int main()
{
int a,b,c =-1;
cin>>a>>b;
while(b%a==0)
{
b/=a;
c++;
}
if(b==1)
cout<<"YES"<<endl<<c;
else
cout<<"NO";
}
|
c5a114f38a227f8d2ccc0d63f2a15b4d18b5ccca | d7a1079c29c96423494f9c4181ca9544235c0162 | /encryption/src/asymetrical/localpeeroperations.cpp | e1d5c1e0e735ba44238f31743830446661b3eae2 | [
"MIT"
] | permissive | sqglobe/SecureDialogues | ede0431b916a7e30d221edd3994b88c5d6afd6d0 | bde56c7a62fb72b1cdfba8cebc0a770157b5f751 | refs/heads/dev | 2020-05-15T01:50:18.416099 | 2020-05-01T08:36:24 | 2020-05-01T08:36:24 | 182,036,134 | 3 | 3 | MIT | 2020-04-15T19:46:54 | 2019-04-18T07:14:51 | C++ | UTF-8 | C++ | false | false | 3,132 | cpp | localpeeroperations.cpp | #include "localpeeroperations.h"
#include <cryptopp/base64.h>
#include <cryptopp/filters.h>
#include <cryptopp/osrng.h>
#include <cryptopp/pssr.h>
LocalPeerOperations::LocalPeerOperations(const CryptoPP::RSA::PrivateKey& key) :
mKey(key) {}
std::string LocalPeerOperations::decrypt(const std::string& data) const {
std::shared_lock<std::shared_mutex> guard(mMutex);
using namespace CryptoPP;
AutoSeededRandomPool rng;
std::string recover;
RSAES_OAEP_SHA_Decryptor d(mKey);
StringSource(data, true,
new Base64Decoder(new PK_DecryptorFilter(
rng, d, new StringSink(recover))) // PK_EncryptorFilter
); // StringSource
return recover;
}
std::string LocalPeerOperations::decrypt(std::string_view data) const {
std::shared_lock<std::shared_mutex> guard(mMutex);
using namespace CryptoPP;
AutoSeededRandomPool rng;
std::string recover;
RSAES_OAEP_SHA_Decryptor d(mKey);
StringSource(reinterpret_cast<const unsigned char*>(data.data()), data.size(),
true,
new Base64Decoder(new PK_DecryptorFilter(
rng, d, new StringSink(recover))) // PK_EncryptorFilter
); // StringSource
return recover;
}
std::string LocalPeerOperations::createSign(const std::string& message) const {
std::shared_lock<std::shared_mutex> guard(mMutex);
CryptoPP::AutoSeededRandomPool rng;
CryptoPP::RSASS<CryptoPP::PSS, CryptoPP::SHA256>::Signer signer(mKey);
size_t length = signer.MaxSignatureLength();
CryptoPP::SecByteBlock signature(length);
// Sign message
length = signer.SignMessage(
rng, reinterpret_cast<const unsigned char*>(message.data()),
message.length(), signature);
// Resize now we know the true size of the signature
signature.resize(length);
std::string str, out;
str.resize(length); // Make room for elements
std::memcpy(&str[0], &signature[0], str.size());
CryptoPP::StringSource ss(
str, true /*pumpAll*/,
new CryptoPP::Base64Encoder(new CryptoPP::StringSink(out)));
return out;
}
std::string LocalPeerOperations::createSign(std::string_view message) const {
std::shared_lock<std::shared_mutex> guard(mMutex);
CryptoPP::AutoSeededRandomPool rng;
CryptoPP::RSASS<CryptoPP::PSS, CryptoPP::SHA256>::Signer signer(mKey);
size_t length = signer.MaxSignatureLength();
CryptoPP::SecByteBlock signature(length);
// Sign message
length = signer.SignMessage(
rng, reinterpret_cast<const unsigned char*>(message.data()),
message.length(), signature);
// Resize now we know the true size of the signature
signature.resize(length);
std::string str, out;
str.resize(length); // Make room for elements
std::memcpy(&str[0], &signature[0], str.size());
CryptoPP::StringSource ss(
str, true /*pumpAll*/,
new CryptoPP::Base64Encoder(new CryptoPP::StringSink(out)));
return out;
}
void LocalPeerOperations::updateKey(const CryptoPP::RSA::PrivateKey& key) {
std::unique_lock<std::shared_mutex> guard(mMutex);
mKey = key;
}
|
ee8d62eea5f3beaa5cde9c14ab001bfe626f7423 | 2fa0062a3b47111487da3dbe4f216248df0a2999 | /test/SPI_unittest.cc | 50a6758e7bb0095c131cd4ff2f743248f928919f | [
"ISC"
] | permissive | bt-trx/arduino-mock | 49240cf237c0c0cc37da326176b8e62e6d39bb8c | e59117bd75d4e3f05f86249f70e8cea356b527ef | refs/heads/master | 2021-07-25T01:13:23.482001 | 2017-05-06T21:47:01 | 2017-05-06T21:47:01 | 186,861,237 | 1 | 1 | ISC | 2020-06-11T10:27:52 | 2019-05-15T16:07:39 | C++ | UTF-8 | C++ | false | false | 1,350 | cc | SPI_unittest.cc | #include "gtest/gtest.h"
#include "arduino-mock/SPI.h"
#include "arduino-mock/Arduino.h"
using ::testing::Return;
TEST(SPITest, access) {
uint8_t value1 = 10;
uint8_t value2 = 12;
uint16_t value = 3;
char text[] = "Mock test";
uint8_t* callback_func = NULL;
void* voidTest = NULL;
SPISettings settings(1, 2, 3);
SPIMock* mock = SPIMockInstance();
EXPECT_CALL(*mock, begin());
EXPECT_CALL(*mock, usingInterrupt(value1));
EXPECT_CALL(*mock, notUsingInterrupt(value1));
EXPECT_CALL(*mock, beginTransaction(settings));
EXPECT_CALL(*mock, transfer(value1));
EXPECT_CALL(*mock, transfer16(value));
EXPECT_CALL(*mock, transfer(voidTest, value1));
EXPECT_CALL(*mock, endTransaction());
EXPECT_CALL(*mock, end());
EXPECT_CALL(*mock, setBitOrder(value1));
EXPECT_CALL(*mock, setDataMode(value1));
EXPECT_CALL(*mock, setClockDivider(value1));
EXPECT_CALL(*mock, attachInterrupt());
EXPECT_CALL(*mock, detachInterrupt());
SPI.begin();
SPI.usingInterrupt(value1);
SPI.notUsingInterrupt(value1);
SPI.beginTransaction(settings);
SPI.transfer(value1);
SPI.transfer16(value);
SPI.transfer(voidTest, value1);
SPI.endTransaction();
SPI.end();
SPI.setBitOrder(value1);
SPI.setDataMode(value1);
SPI.setClockDivider(value1);
SPI.attachInterrupt();
SPI.detachInterrupt();
releaseSPIMock();
}
|
185c1a2f4d373fb6e8d53a94c92361ded031f0c4 | 3a5a374584cb33df5c732881a908098bd497f0e9 | /magicSquare.cpp | 3e259192615b02c9f55f6ccecea004e37b73e942 | [] | no_license | maieutiquer/fmi-hw-2014 | edef864f2c8babc77df3a29d5f69d7e0e02449af | 53c9b6a8dcf938ac991f4120657701f75680191b | refs/heads/master | 2016-09-10T20:13:33.279624 | 2014-12-24T01:45:41 | 2014-12-24T01:45:41 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 2,725 | cpp | magicSquare.cpp | #include <iostream>
using namespace std;
int takeInput(string varName) {
int input;
cout << "Enter " << varName << ":\n";
cin >> input;
return input;
}
void fillSquareMatrix(int matrixSize, void *matrixArg) {
int (*matrix)[matrixSize] = (int (*)[matrixSize]) matrixArg;
for (int i = 0; i < matrixSize; i++) {
for (int j = 0; j < matrixSize; j++) {
matrix[i][j] = takeInput("matrix[" + to_string(i) + "][" + to_string(j) + "]");
}
}
}
void printSquareMatrix(int matrixSize, void *matrixArg) {
int (*matrix)[matrixSize] = (int (*)[matrixSize]) matrixArg;
for (int i = 0; i < matrixSize; i++) {
cout << "[ ";
for (int j = 0; j < matrixSize; j++) {
cout << matrix[i][j] << " ";
}
cout << "]\n";
}
}
int getSumOfArrayElements(int array[], int arraySize) {
int sum = 0;
for (int i = 0; i < arraySize; i++) {
sum += array[i];
}
return sum;
}
int getSumOfMatrixColElements(int matrixSize, void *matrixArg, int column) {
int (*matrix)[matrixSize] = (int (*)[matrixSize]) matrixArg;
int sum = 0;
for (int i = 0; i < matrixSize; i++) {
sum += matrix[i][column];
}
return sum;
}
bool isMagicSquare(int matrixSize, void *matrixArg) {
int (*matrix)[matrixSize] = (int (*)[matrixSize]) matrixArg;
// get the sum of all elements from the first row
int sumOfFirstRowElements = getSumOfArrayElements(matrix[0], matrixSize);
// and from the first column
int sumOfFirstColElements = getSumOfMatrixColElements(matrixSize, matrix, 0);
// then compare them
if (sumOfFirstRowElements != sumOfFirstColElements) {
return false;
}
// start iterating from second row and column
for (int i = 1; i < matrixSize; i++) {
int sumOfRowElements = getSumOfArrayElements(matrix[i], matrixSize);
if (sumOfRowElements != sumOfFirstRowElements) {
return false;
}
// if row i is OK, then compare column i
int sumOfColElements = getSumOfMatrixColElements(matrixSize, matrix, i);
if (sumOfColElements != sumOfFirstColElements) {
return false;
}
}
return true;
}
int main() {
int matrixSize;
do {
matrixSize = takeInput("1 <= n <= 20");
} while (matrixSize < 1 || matrixSize > 20);
int squareMatrix[matrixSize][matrixSize];
fillSquareMatrix(matrixSize, squareMatrix);
cout << "Your matrix is:" << endl;
printSquareMatrix(matrixSize, squareMatrix);
if (isMagicSquare(matrixSize, squareMatrix)) {
cout << "You're a wizard, User.\n";
} else {
cout << "No, it's not a magic square.\n";
}
}
|
b84cfa8cf952a6ee5f65e8deda2e8e9286b3785a | 690b5a3a48ad1448e8aa9b693be9938a8c695e5c | /knRapid/src/rapidExtArcDds/generated/DlpSampleSupport.cxx | f3d10592ce9a2bcef5ab6ee07877621b5683877e | [
"Apache-2.0"
] | permissive | bcoltin/soraCore | f5e37901d3a975b7086cceab8bc393b9c4d442a4 | cd0624774b7a3b1aac17e0ce3338b8914387f3fc | refs/heads/master | 2021-01-19T04:10:40.940887 | 2017-04-21T20:38:46 | 2017-04-21T20:38:46 | 87,354,301 | 0 | 0 | null | 2017-04-05T20:37:45 | 2017-04-05T20:37:44 | null | UTF-8 | C++ | false | false | 7,777 | cxx | DlpSampleSupport.cxx |
/*
WARNING: THIS FILE IS AUTO-GENERATED. DO NOT MODIFY.
This file was generated from DlpSample.idl using "rtiddsgen".
The rtiddsgen tool is part of the RTI Connext distribution.
For more information, type 'rtiddsgen -help' at a command shell
or consult the RTI Connext manual.
*/
#include "DlpSampleSupport.h"
#include "DlpSamplePlugin.h"
#ifdef __cplusplus
#ifndef dds_c_log_impl_h
#include "dds_c/dds_c_log_impl.h"
#endif
#endif
namespace rapid{
namespace ext{
namespace arc{
/* ========================================================================= */
/**
<<IMPLEMENTATION>>
Defines: TData,
TDataWriter,
TDataReader,
TTypeSupport
Configure and implement 'DlpChannelSample' support classes.
Note: Only the #defined classes get defined
*/
/* ----------------------------------------------------------------- */
/* DDSDataWriter
*/
/**
<<IMPLEMENTATION >>
Defines: TDataWriter, TData
*/
/* Requires */
#define TTYPENAME DlpChannelSampleTYPENAME
/* Defines */
#define TDataWriter DlpChannelSampleDataWriter
#define TData ::rapid::ext::arc::DlpChannelSample
#ifdef __cplusplus
#include "dds_cpp/generic/dds_cpp_data_TDataWriter.gen"
#else
#include "dds_c/generic/dds_c_data_TDataWriter.gen"
#endif
#undef TDataWriter
#undef TData
#undef TTYPENAME
/* ----------------------------------------------------------------- */
/* DDSDataReader
*/
/**
<<IMPLEMENTATION >>
Defines: TDataReader, TDataSeq, TData
*/
/* Requires */
#define TTYPENAME DlpChannelSampleTYPENAME
/* Defines */
#define TDataReader DlpChannelSampleDataReader
#define TDataSeq DlpChannelSampleSeq
#define TData ::rapid::ext::arc::DlpChannelSample
#ifdef __cplusplus
#include "dds_cpp/generic/dds_cpp_data_TDataReader.gen"
#else
#include "dds_c/generic/dds_c_data_TDataReader.gen"
#endif
#undef TDataReader
#undef TDataSeq
#undef TData
#undef TTYPENAME
/* ----------------------------------------------------------------- */
/* TypeSupport
<<IMPLEMENTATION >>
Requires: TTYPENAME,
TPlugin_new
TPlugin_delete
Defines: TTypeSupport, TData, TDataReader, TDataWriter
*/
/* Requires */
#define TTYPENAME DlpChannelSampleTYPENAME
#define TPlugin_new ::rapid::ext::arc::DlpChannelSamplePlugin_new
#define TPlugin_delete ::rapid::ext::arc::DlpChannelSamplePlugin_delete
/* Defines */
#define TTypeSupport DlpChannelSampleTypeSupport
#define TData ::rapid::ext::arc::DlpChannelSample
#define TDataReader DlpChannelSampleDataReader
#define TDataWriter DlpChannelSampleDataWriter
#ifdef __cplusplus
#include "dds_cpp/generic/dds_cpp_data_TTypeSupport.gen"
#else
#include "dds_c/generic/dds_c_data_TTypeSupport.gen"
#endif
#undef TTypeSupport
#undef TData
#undef TDataReader
#undef TDataWriter
#undef TTYPENAME
#undef TPlugin_new
#undef TPlugin_delete
/* ========================================================================= */
/**
<<IMPLEMENTATION>>
Defines: TData,
TDataWriter,
TDataReader,
TTypeSupport
Configure and implement 'DlpBoardSample' support classes.
Note: Only the #defined classes get defined
*/
/* ----------------------------------------------------------------- */
/* DDSDataWriter
*/
/**
<<IMPLEMENTATION >>
Defines: TDataWriter, TData
*/
/* Requires */
#define TTYPENAME DlpBoardSampleTYPENAME
/* Defines */
#define TDataWriter DlpBoardSampleDataWriter
#define TData ::rapid::ext::arc::DlpBoardSample
#ifdef __cplusplus
#include "dds_cpp/generic/dds_cpp_data_TDataWriter.gen"
#else
#include "dds_c/generic/dds_c_data_TDataWriter.gen"
#endif
#undef TDataWriter
#undef TData
#undef TTYPENAME
/* ----------------------------------------------------------------- */
/* DDSDataReader
*/
/**
<<IMPLEMENTATION >>
Defines: TDataReader, TDataSeq, TData
*/
/* Requires */
#define TTYPENAME DlpBoardSampleTYPENAME
/* Defines */
#define TDataReader DlpBoardSampleDataReader
#define TDataSeq DlpBoardSampleSeq
#define TData ::rapid::ext::arc::DlpBoardSample
#ifdef __cplusplus
#include "dds_cpp/generic/dds_cpp_data_TDataReader.gen"
#else
#include "dds_c/generic/dds_c_data_TDataReader.gen"
#endif
#undef TDataReader
#undef TDataSeq
#undef TData
#undef TTYPENAME
/* ----------------------------------------------------------------- */
/* TypeSupport
<<IMPLEMENTATION >>
Requires: TTYPENAME,
TPlugin_new
TPlugin_delete
Defines: TTypeSupport, TData, TDataReader, TDataWriter
*/
/* Requires */
#define TTYPENAME DlpBoardSampleTYPENAME
#define TPlugin_new ::rapid::ext::arc::DlpBoardSamplePlugin_new
#define TPlugin_delete ::rapid::ext::arc::DlpBoardSamplePlugin_delete
/* Defines */
#define TTypeSupport DlpBoardSampleTypeSupport
#define TData ::rapid::ext::arc::DlpBoardSample
#define TDataReader DlpBoardSampleDataReader
#define TDataWriter DlpBoardSampleDataWriter
#ifdef __cplusplus
#include "dds_cpp/generic/dds_cpp_data_TTypeSupport.gen"
#else
#include "dds_c/generic/dds_c_data_TTypeSupport.gen"
#endif
#undef TTypeSupport
#undef TData
#undef TDataReader
#undef TDataWriter
#undef TTYPENAME
#undef TPlugin_new
#undef TPlugin_delete
/* ========================================================================= */
/**
<<IMPLEMENTATION>>
Defines: TData,
TDataWriter,
TDataReader,
TTypeSupport
Configure and implement 'DlpSample' support classes.
Note: Only the #defined classes get defined
*/
/* ----------------------------------------------------------------- */
/* DDSDataWriter
*/
/**
<<IMPLEMENTATION >>
Defines: TDataWriter, TData
*/
/* Requires */
#define TTYPENAME DlpSampleTYPENAME
/* Defines */
#define TDataWriter DlpSampleDataWriter
#define TData ::rapid::ext::arc::DlpSample
#ifdef __cplusplus
#include "dds_cpp/generic/dds_cpp_data_TDataWriter.gen"
#else
#include "dds_c/generic/dds_c_data_TDataWriter.gen"
#endif
#undef TDataWriter
#undef TData
#undef TTYPENAME
/* ----------------------------------------------------------------- */
/* DDSDataReader
*/
/**
<<IMPLEMENTATION >>
Defines: TDataReader, TDataSeq, TData
*/
/* Requires */
#define TTYPENAME DlpSampleTYPENAME
/* Defines */
#define TDataReader DlpSampleDataReader
#define TDataSeq DlpSampleSeq
#define TData ::rapid::ext::arc::DlpSample
#ifdef __cplusplus
#include "dds_cpp/generic/dds_cpp_data_TDataReader.gen"
#else
#include "dds_c/generic/dds_c_data_TDataReader.gen"
#endif
#undef TDataReader
#undef TDataSeq
#undef TData
#undef TTYPENAME
/* ----------------------------------------------------------------- */
/* TypeSupport
<<IMPLEMENTATION >>
Requires: TTYPENAME,
TPlugin_new
TPlugin_delete
Defines: TTypeSupport, TData, TDataReader, TDataWriter
*/
/* Requires */
#define TTYPENAME DlpSampleTYPENAME
#define TPlugin_new ::rapid::ext::arc::DlpSamplePlugin_new
#define TPlugin_delete ::rapid::ext::arc::DlpSamplePlugin_delete
/* Defines */
#define TTypeSupport DlpSampleTypeSupport
#define TData ::rapid::ext::arc::DlpSample
#define TDataReader DlpSampleDataReader
#define TDataWriter DlpSampleDataWriter
#ifdef __cplusplus
#define RTI_VALUETYPE
#include "dds_cpp/generic/dds_cpp_data_TTypeSupport.gen"
#undef RTI_VALUETYPE
#else
#include "dds_c/generic/dds_c_data_TTypeSupport.gen"
#endif
#undef TTypeSupport
#undef TData
#undef TDataReader
#undef TDataWriter
#undef TTYPENAME
#undef TPlugin_new
#undef TPlugin_delete
} /* namespace arc */
} /* namespace ext */
} /* namespace rapid */
|
0f0787a700eb4f6755a64728c0094db56bb2e494 | 13f78c34e80a52442d72e0aa609666163233e7e0 | /POI/2017/Round 2/zam.cpp | 4cc3593314642296a0ce1fab4d4a8263f23394c1 | [] | no_license | Giantpizzahead/comp-programming | 0d16babe49064aee525d78a70641ca154927af20 | 232a19fdd06ecef7be845c92db38772240a33e41 | refs/heads/master | 2023-08-17T20:23:28.693280 | 2023-08-11T22:18:26 | 2023-08-11T22:18:26 | 252,904,746 | 2 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 3,792 | cpp | zam.cpp | /*
Solution: When representing each chamber as a node and adjacent chambers as edges, it can be shown that the # of edges
is bounded by a small constant of N (maybe 4?). Think about the number of full sides for each chamber (not touching
other chambers), along with the number of contiguous, partially occupied sides. Messing around with these, along with
some intuition, reveals this property.
To efficiently find these edges, use a sorted vector to "sweep" through the chambers that are adjacent. See code for
more details.
Runtime: O(N * log(N) * C) where C is a small constant
*/
#include <bits/stdc++.h>
using namespace std;
#define rep(i, a, b) for (int i = (a); i < (b); i++)
#define sz(x) ((int) x.size())
#define all(x) x.begin(), x.end()
#define debug if (true) cerr
using ll = long long;
const int MAXN = 1e6+5;
const int INF = 1e9;
int W, H, N, M, A, B;
int X1[MAXN], Y1[MAXN], X2[MAXN], Y2[MAXN];
bool marked[MAXN];
struct Point {
int x, y, i;
bool operator<(const Point& o) const {
return make_pair(x, y) < make_pair(o.x, o.y);
}
};
struct Pair {
int x, i;
bool operator<(const Pair& o) const {
return x < o.x;
}
};
unordered_map<int, vector<Pair>> adjT, adjR, adjB, adjL;
int dist[MAXN];
queue<int> q;
void addAdj(int d, int l, int r, vector<Pair>& v) {
auto ptr = upper_bound(all(v), Pair{l, -1});
if (ptr != v.begin()) ptr = prev(ptr);
while (ptr != v.end() && ptr->x < r) {
int n = ptr->i;
if (!marked[n] && dist[n] == INF) {
dist[n] = d+1;
q.push(n);
}
ptr = next(ptr);
}
}
int bfs() {
rep(i, 0, N) {
adjT[Y1[i]].push_back({X1[i], i});
adjB[Y2[i]].push_back({X1[i], i});
adjR[X1[i]].push_back({Y1[i], i});
adjL[X2[i]].push_back({Y1[i], i});
dist[i] = INF;
}
for (auto& v : adjT) sort(all(v.second));
for (auto& v : adjR) sort(all(v.second));
for (auto& v : adjB) sort(all(v.second));
for (auto& v : adjL) sort(all(v.second));
q.push(A);
dist[A] = 1;
while (!q.empty()) {
int n = q.front(); q.pop();
if (n == B) return dist[n];
addAdj(dist[n], X1[n], X2[n], adjT[Y2[n]]);
addAdj(dist[n], X1[n], X2[n], adjB[Y1[n]]);
addAdj(dist[n], Y1[n], Y2[n], adjR[X2[n]]);
addAdj(dist[n], Y1[n], Y2[n], adjL[X1[n]]);
}
return -1;
}
void solve() {
cin >> W >> H >> N >> M;
int xp, yp, xs, ys;
cin >> xp >> yp >> xs >> ys;
rep(i, 0, N) {
int x1, y1, x2, y2;
cin >> x1 >> y1 >> x2 >> y2;
X1[i] = min(x1, x2);
Y1[i] = min(y1, y2);
X2[i] = max(x1, x2);
Y2[i] = max(y1, y2);
}
// Process marks
vector<Point> events;
events.push_back({xp, yp, 2*N});
events.push_back({xs, ys, 2*N+1});
rep(i, 0, N) {
events.push_back({X1[i], Y1[i], i});
events.push_back({X2[i], Y1[i], N+i});
}
rep(i, 0, M) {
int x, y;
cin >> x >> y;
events.push_back({x, y, -1});
}
sort(all(events));
set<pair<int, int>> activeRects;
for (Point& p : events) {
// debug << p.x << " " << p.y << " " << p.i << endl;
if (p.i == -1 || p.i >= 2*N) {
// Point
int n = prev(activeRects.lower_bound({p.y, -1}))->second;
if (p.i == -1) marked[n] = true;
else if (p.i == 2*N) A = n;
else B = n;
} else if (p.i < N) {
// Rectangle start
activeRects.insert({p.y, p.i});
} else {
// Rectangle end
activeRects.erase({p.y, p.i-N});
}
}
// BFS
int ans = bfs();
cout << ans << '\n';
}
int main() {
ios::sync_with_stdio(0);
cin.tie(0);
solve();
return 0;
} |
7919452a410645dbf0c9bbf57e1b962554586468 | c058462235a37cf50d8308c6de80b3253d39d375 | /3Elevator-scheduling/Elevator.h | fab0862e5d40201a49bd45399ec4766349a6e9c0 | [] | no_license | DreamFeather/3Elevators-scheduling | e4b788d4f0efc10ef323cd21c64bf1968d7cd757 | c5ce321136c8da139e98f95e3a82b76aa27bf00d | refs/heads/master | 2020-03-17T01:15:47.408313 | 2018-05-26T13:30:44 | 2018-05-26T13:30:44 | 133,143,901 | 0 | 0 | null | null | null | null | GB18030 | C++ | false | false | 1,750 | h | Elevator.h | #include"NewQue.h"
using namespace std;
class Elevator
{
private:
int Type; //1odd 2even 3normal
int CurrentFloor; //当前楼层1~10;
int CurrentTime; //当前时间;
que TargetFloor; //目标楼层
que AskFloor; //请求楼层
int Door; //-1关闭,1开启
int Arrival[11]; //能到的楼层
public:
int Diretion; //方向 -1下,0等待,1上
int Load; //(载重)乘客数量
int NextFloor; //下一目的地
static int Finish; //完成任务总次数;
void Set_Type(const int); //设置类型
Elevator(); //无参构造
void Add_TargetFloor(const int); //增加目标
void DE_TargetFloor(const int); //删除目标
void Add_AskFloor(const int); //增加请求
int Get_CurrentTime(); //查看当前时间
int Get_CurrentFloor(); //查看当前楼层
int Get_Diretion(); //查看当前方向
void Wait(); //电梯空闲
void Up_stair(); //上升1
void Down_stair(); //下降1
int Door_status(); //门状态
int status(); //电梯状态
int Get_Arrival(const int n); //到达许可
int Order(const int n); //查看是否有该层
void SortWay(); //在当前方向上排序
int Get_Asksize(); //请求队列情况
int Get_NextAsk(); //返回请求层
int Get_NextTarget(); //返回目标层
void DE_NextAsk(); //删除该请求
void DE_NextTarget(); //删除该目标
int Find_Target(const int); //寻找指定层
void DE_Target(const int); //删除指定层
int Find_Ask(const int); //寻找指定层
void DE_Ask(const int); //删除指定层
};
#include"Elevator.cpp"
|
f6d646f68d2dff603c311c0c244b638f53284e3e | b62e7796632f74cd9faef22dca2b8c52c4ff2466 | /LeetCodeInVSCode/34.find-first-and-last-position-of-element-in-sorted-array.cpp | 25acaf4127ddc94a4c7c108a9b1cff94f2c2640a | [] | no_license | vgvgvvv/My-Algorithm-Training | b78913b9d8a0a44613c241b4b7322f3a4b96a13a | 02f5104e0e81d075373fc96e5331f055d0c1cea2 | refs/heads/master | 2021-08-27T21:38:51.350155 | 2021-08-26T09:42:04 | 2021-08-26T09:42:04 | 183,287,830 | 1 | 1 | null | null | null | null | UTF-8 | C++ | false | false | 1,926 | cpp | 34.find-first-and-last-position-of-element-in-sorted-array.cpp | /*
* @lc app=leetcode id=34 lang=cpp
*
* [34] Find First and Last Position of Element in Sorted Array
*
* https://leetcode.com/problems/find-first-and-last-position-of-element-in-sorted-array/description/
*
* algorithms
* Medium (33.34%)
* Total Accepted: 289.8K
* Total Submissions: 868.3K
* Testcase Example: '[5,7,7,8,8,10]\n8'
*
* Given an array of integers nums sorted in ascending order, find the starting
* and ending position of a given target value.
*
* Your algorithm's runtime complexity must be in the order of O(log n).
*
* If the target is not found in the array, return [-1, -1].
*
* Example 1:
*
*
* Input: nums = [5,7,7,8,8,10], target = 8
* Output: [3,4]
*
* Example 2:
*
*
* Input: nums = [5,7,7,8,8,10], target = 6
* Output: [-1,-1]
*
*/
#include<vector>
using namespace std;
class Solution {
public:
//二分查找
void bs(vector<int>& nums, vector<int>& result, int target, int head, int tail){
if(head > tail){
return;
}
int mid = (head + tail) / 2;
//找到目标,更新开始以及结束位置
if(target == nums[mid]){
if(result[0] == -1 || result[0] > mid){
result[0] = mid;
}
if(result[1] == -1 || result[1] < mid){
result[1] = mid;
}
//两边搜索
bs(nums, result, target, mid+1, tail);
bs(nums, result, target, head, mid-1);
}
//未找到,缩小搜索范围
else if(target > nums[mid]){
bs(nums, result, target, mid+1, tail);
}
//未找到,缩小搜索范围
else{
bs(nums, result, target, head, mid-1);
}
}
vector<int> searchRange(vector<int>& nums, int target) {
vector<int> res{-1, -1};
bs(nums, res, target, 0, nums.size()-1);
return res;
}
};
|
1e5cf307aa1b1ab7ada347206011e5cd7b05923f | 4e3300ebbbc59e9e8528670ff1499c9df4fe21b9 | /source/render/SSView/SSViewAbstract.cpp | 8a3ac65a654ddaf8624a894f985e366108fda273 | [] | no_license | droggen/Labeller | 6966da0649c131beea9721b60c34d41700295750 | 1120345a17f51940772d0dd8ec1fa2b3a2b1e3dc | refs/heads/master | 2022-11-29T20:07:23.446813 | 2020-08-13T16:14:56 | 2020-08-13T16:14:56 | 280,924,085 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 4,177 | cpp | SSViewAbstract.cpp | /*
SynScopeV
Copyright (C) 2008,2009,2010,2011:
Daniel Roggen, droggen@gmail.com
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License
as published by the Free Software Foundation; either version 2
of the License, or (at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
*/
#include <QPainter>
#include <QPaintEvent>
#include <assert.h>
#include "SSViewAbstract.h"
//SSViewAbstract::SSViewAbstract(QWidget *parent) : QFrame(parent)
SSViewAbstract::SSViewAbstract(QWidget *parent) : QWidget(parent)
{
NoSliderEvents = false;
// Frame
//setFrameStyle(QFrame::Panel);
//setFrameShadow(QFrame::Raised);
setAutoFillBackground(true);
setMouseTracking(true); // To follow mouse over widget and send signals
//setFocusPolicy(Qt::StrongFocus); // To accept focus, and thus receive keyboard events
setFocusPolicy(Qt::WheelFocus); // To accept focus, and thus receive keyboard events, when: click, tab, mouse wheel.
bgcolors = {QColor(0,0,0),QColor(64,64,64),
QColor(0,0,127),QColor(0,0,223),
QColor(127,0,127),QColor(223,0,223)
};
setBackground(SSVIEWBACKGROUNDNONE);
//installEventFilter(this);
}
SSViewAbstract::~SSViewAbstract()
{
}
//void SSViewAbstract::setBackground(QColor color)
void SSViewAbstract::setBackground(unsigned colorid)
{
assert(colorid<bgcolors.size());
backgroundcolortype = colorid;
setBackgroundPalette();
}
void SSViewAbstract::setBackgroundPalette()
{
QColor c;
if(hasFocus())
c = bgcolors[backgroundcolortype+1];
else
c = bgcolors[backgroundcolortype];
QPalette p = palette();
p.setColor(backgroundRole(), c);
setPalette(p);
}
bool SSViewAbstract::hasFocus() const
{
return QWidget::hasFocus();
}
/*
void SSViewAbstract::focusInEvent ( QFocusEvent * event )
{
QWidget::focusInEvent(event);
printf("SSViewAbstract::focusInEvent %p\n",this);
repaint();
}
void SSViewAbstract::focusOutEvent ( QFocusEvent * event )
{
QWidget::focusInEvent(event);
printf("SSViewAbstract::focusOutEvent %p\n",this);
repaint();
}*/
void SSViewAbstract::paintEvent(QPaintEvent *event)
{
static int i=0;
i++;
//printf("SSViewAbstract::paintEvent %p %d\n",this,i);
QColor b; // Adapted background color: lighter if focused
setBackgroundPalette();
//QWidget::paintEvent(event);
// Draw a frame if we have the focus
QPainter p(this);
p.setPen(Qt::white);
p.drawRect(0,0,width()-1,height()-1);
if(hasFocus())
{
QPen pen;
pen.setColor(Qt::black);
pen.setStyle(Qt::DotLine);
p.setPen(pen);
p.drawRect(0,0,width()-1,height()-1);
}
else
{
}
}
// This event handler must be applied to child widgets to capture their focus change.
// Use this to trigger a repaint of the owner widget
bool SSViewAbstract::eventFilter(QObject* obj, QEvent* evt)
{
//printf("SSViewAbstract::eventFilter obj %p type %d\n",obj,evt->type());
if(evt->type()==QEvent::FocusIn)
{
//printf("+++++++ FOCUS IN\n");
//printf("Focus widget: %p\n",focusWidget());
update();
//return true;
}
if(evt->type()==QEvent::FocusOut)
{
//printf("------- FOCUS OUT\n");
//printf("Focus widget: %p\n",focusWidget());
update();
//return true;
}
return false;
}
void SSViewAbstract::enterEvent(QEvent *event)
{
printf("enter event\n");
}
void SSViewAbstract::leaveEvent(QEvent *event)
{
printf("leave event\n");
// Restore mouse pointer
//setCursor(QCursor(Qt::ArrowCursor));
emit Leaved();
}
|
cb7c72eb38dcd0e5c673f30aa66853fda0d59b30 | ec2ca75c541dedc55635cbec240c825d9327502a | /qcore/controller/tcpbackend.h | cfaddc665de7110f20b283698b6f8078ef26b16c | [
"Apache-2.0"
] | permissive | ivandzen/RMCS | 5f921c0da648f3852acb8b2216663e2ba6494a0d | a695725212f1e32845bc04c1d9197535c2aa3732 | refs/heads/master | 2020-03-26T09:52:25.546248 | 2018-08-14T17:20:16 | 2018-08-14T17:20:16 | 144,769,627 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 2,054 | h | tcpbackend.h | #ifndef TCPBACKEND_H
#define TCPBACKEND_H
#include <controller/deviceconnection.h>
#include <QTcpSocket>
#include <QMutex>
class TcpBackend :
public QObject,
public DeviceConnection
{
Q_OBJECT
public:
explicit TcpBackend(QObject * parent = nullptr);
protected:
bool init(qint64 timeout);
virtual ControlPacket beginControlTransaction(Length_t max_length) override;
virtual bool endControlTransaction(NodeID_t ep_id,
CtlReq_t req,
const ControlPacket & packet,
Time_t timeout,
const TransmitHandler & handler) override;
virtual bool requestControlPacket(NodeID_t ep_id,
CtlReq_t req,
Length_t max_length,
Time_t timeout,
const ReceiveHandler & handler) override;
virtual void timerEvent(QTimerEvent * event) override;
private:
typedef uint8_t TransType_t;
enum TransType
{
TT_INIT,
TT_CTL_WRITE,
TT_CTL_REQ
};
struct ControlHeader
{
TransType_t type;
NodeID_t ep_id;
CtlReq_t req;
Length_t length;
inline Length_t totalLength() const
{
return sizeof(ControlHeader) + length;
}
};
inline ControlHeader * controlHeader() const
{
return reinterpret_cast<ControlHeader*>(const_cast<unsigned char*>(_controlPacket.data()));
}
inline unsigned char * controlData()
{
return const_cast<unsigned char*>(_controlPacket.data());
}
QTcpSocket * _controlSocket;
QTcpSocket * _outStreamSocket;
QTcpSocket * _intStreamSocket;
QMutex _mutex;
QVector<Data> _controlPacket;
int _timerId;
private slots:
void controlReadyRead();
void bytesWritten(qint64);
};
#endif // TCPBACKEND_H
|
035a160179ad8859785fae35c78ae39d57307c46 | 4b98ec2b8856029ba1e427619fe09929eea628eb | /411/C.cpp | fc311b4dbe87104f8081e61a579fa72190a503cf | [] | no_license | xfcherish/codeforces | 7538ab43d32b03a6b8c74252a0623b89c5f43f0b | 4780abc50a85971eb2dd5a24dedde3248ab967c3 | refs/heads/master | 2021-01-19T11:29:53.875144 | 2017-05-28T00:59:57 | 2017-05-28T00:59:57 | 87,972,618 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 398 | cpp | C.cpp | #include <iostream>
#include <cstdio>
#include <cstring>
#include <algorithm>
#include <vector>
#include <cmath>
#include <queue>
#include <stack>
#include <map>
#include <string>
using namespace std;
# define pb push_back
# define mp make_pair
typedef long long ll;
typedef pair<int,int> PII;
const int maxn = (1e5)+10;
int main()
{
int l,r;
cin >> l >> r;
cout << 2 << endl;
return 0;
} |
469ebe823d299e7f0c194a2e2a4741468d118160 | 00f785ee987cb6923db9b7f283a1843db12c384c | /string.h | 53a285185fae107743bafea4fa8f580c2c7e0fdc | [] | no_license | pyrovski/dpfs | 8c223c659ea4fdd7fa8667988503587429f9985a | acb6dd4ce4a8a792472fc9fc4bce2e5295dc9cc6 | refs/heads/master | 2021-01-10T04:46:23.659930 | 2015-12-16T20:41:10 | 2015-12-16T20:41:10 | 47,600,853 | 1 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 990 | h | string.h | #ifndef STRING_H
#define STRING_H
#include <algorithm>
#include <functional>
#include <cctype>
#include <locale>
#include <string>
#include <uuid/uuid.h>
// trim from start
static inline std::string <rim(std::string &s) {
s.erase(s.begin(), std::find_if(s.begin(), s.end(), std::not1(std::ptr_fun<int, int>(std::isspace))));
return s;
}
// trim from end
static inline std::string &rtrim(std::string &s) {
s.erase(std::find_if(s.rbegin(), s.rend(), std::not1(std::ptr_fun<int, int>(std::isspace))).base(), s.end());
return s;
}
// trim from both ends
static inline std::string &trim(std::string &s) {
return ltrim(rtrim(s));
}
static inline std::string strToLower(const std::string & str){
std::string strLower = str;
std::transform(strLower.begin(), strLower.end(), strLower.begin(), tolower);
return strLower;
}
int strSplit(const std::string &str, const char split, std::string & lhs,
std::string & rhs);
std::string to_string(const uuid_t & uuid);
#endif
|
5cd3fc98bf4be7de793b168c6351ecc878e3e7f5 | c1b64361527e8dd87d2f424795478fa6166ef971 | /uml/Model/Arrive.h | 3a7372cc5455f73c50efba7b3ac1a3bb82f351ca | [] | no_license | nahueJ/steering_behaviors_controller | b7b03eb8a71064df994f619da1cacc3ca9fc28df | 0569b5d1378d0f08206df5f7b6e2a411a49746b8 | refs/heads/master | 2020-04-15T13:37:32.353132 | 2018-04-16T21:57:14 | 2018-04-16T21:57:14 | 58,772,695 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 543 | h | Arrive.h | /**
* Project SteeringBehaviorsController
* @author JOSE Nahuel
* @version 1.0.0
*/
#ifndef _ARRIVE_H
#define _ARRIVE_H
#include "SteeringBehavior.h"
#include <geometry_msgs/Pose.h>
class Arrive: public SteeringBehavior {
public:
/**
* gets the last data and actualizes the desiredTwist
* @param myPose
*/
void update(pose myPose);
/**
* @param objective
* @param id
* @param weight
*/
void Arrive(pose objective, unsigned int id, float weight);
void ~Arrive();
private:
pose target;
};
#endif //_ARRIVE_H |
88032af0c07d62059991a3dbf428a4f50490d262 | a355e712aad01d4309f018c38b727c017e7238e3 | /robot/InterFace.cpp | 8f9a81e9c9bb5dc1a1855333b432429d20cdbda4 | [] | no_license | xxmen/Test4Simulation | 5f0980571de041f755aa2ea6010c988516a07c8d | 092a573754d2b2bad6e2251b7a59c078a3a78d89 | refs/heads/master | 2020-04-09T22:01:38.432392 | 2014-07-22T01:48:02 | 2014-07-22T01:48:02 | null | 0 | 0 | null | null | null | null | GB18030 | C++ | false | false | 12,356 | cpp | InterFace.cpp | #include <windows.h>
#include "InterFace.h"
#include "Strategy.h"
BOOL APIENTRY DllMain( HANDLE hModule, DWORD ul_reason_for_call, LPVOID lpReserved )
{
switch (ul_reason_for_call)
{
case DLL_PROCESS_ATTACH:
break;
case DLL_THREAD_ATTACH:
break;
case DLL_THREAD_DETACH:
break;
case DLL_PROCESS_DETACH:
break;
}
return TRUE;
}
extern "C" STRATEGY_API void Create ( Environment *env )//用于建立初始化文档储存球场动态数据以留作分析
{
//MessageBox(NULL,"四川大学代表队","SCU_KS",MB_OK);
//初始化数据
env->userData=(void* ) new Mydata;//definition of Mydata in Interface.h
Mydata* p;
p=(Mydata*)env->userData;//p as an pointer
p->a=fopen("c:\\output.txt","w");//using txt file to out put the instant data
int i;
for(i =0 ; i < 5; i++)//初始化text中的记录
{
p->robot[i].pos.x=InlitializeMyPosition_X[i];
p->robot[i].pos.y=InlitializeMyPosition_Y[i];
p->robot[i].pos.z=InlitializeMyPosition_Z[i]; //what is 'z'? z为方向
p->myoldpos[i].x=InlitializeMyPosition_X[i];
p->myoldpos[i].y=InlitializeMyPosition_Y[i];
p->myoldpos[i].z=InlitializeMyPosition_Z[i]; //this z is the direction that the robot faces
p->myspeed[i].x=0;
p->myspeed[i].y=0;
p->myspeed[i].z=0;
p->myoldvelocity[i].x=0;//上次的驱动力
p->myoldvelocity[i].y=0;
p->myoldvelocity[i].z=0;
p->opp[i].pos.x = InlitializeOppPosition_X[i]; //对方坐标
p->opp[i].pos.y = InlitializeOppPosition_Y[i]; //对方坐标
p->opp[i].pos.z = InlitializeOppPosition_Z[i]; //对方坐标
p->opoldpos[i].x = InlitializeOppPosition_X[i]; //对方 旧坐标
p->opoldpos[i].y = InlitializeOppPosition_Y[i]; //对方 旧坐标
p->opoldpos[i].z = InlitializeOppPosition_Z[i]; //对方 旧坐标
p->opspeed[0].x = 0; //对方 队员速度
p->opspeed[0].y = 0; //对方 队员速度
p->opspeed[0].z = 0; //对方 队员速度
}
p->locked=false; // 判断了 场地 ??
p->mygrand=true; // 是 黄队 ??
p->oldball.x = (FLEFTX + FRIGHTX) / 2.0;//球上次位置位于球场中央
p->oldball.y = (FTOP + FBOT) / 2.0;
p->oldball.z = 0; //what is 'z' mean? the ball's speed ??
p->curball.x = (FLEFTX + FRIGHTX) / 2.0;//球目前位置位于球场中央
p->curball.y = (FTOP + FBOT) / 2.0;
p->curball.z = 0;
p->preball.x = (FLEFTX + FRIGHTX) / 2.0;//球将来位置位于球场中央
p->preball.y = (FTOP + FBOT) / 2.0;
p->preball.z = 0;
p->ballspeed.x =0;
p->ballspeed.y =0;
p->ballspeed.z =0;
}
extern "C" STRATEGY_API void Strategy ( Environment *env )//程序每周期调用一次
//////////////适用于 !!黄队
{
Mydata * p;
p=(Mydata *)env->userData;
if(!p->locked) // 是 判断场地了 ??
{
//确定区域,blue or yellow
if( env->home[0].pos.x < 50.0 )
p->mygrand=true; /// 是 = 黄队??
else
p->mygrand=false;
p->locked=true;
}
See(env); // 预处理
MyGame(env); //策略
End ( env ); //后期处理
/*int testInt = 100;
int nIndex = 0;
switch (env->gameState)
{
case 0:
{
// 缺省情况下的策略
}
break;
case FREE_BALL:
{
}
break;
case PLACE_KICK:
{
// 发生坠球时的策略
}
break;
case PENALTY_KICK:
// 发生罚球时的策略
switch (env->whosBall)
{
case ANYONES_BALL:
break;
case BLUE_BALL:
break;
case YELLOW_BALL:
break;
}
break;
case FREE_KICK:
{
// 保存对方机器人的相关坐标
}
break;
case GOAL_KICK:
{
// 发生点球时的策略
}
break;
}*/
}
void See ( Environment *env )
{
Mydata * p;
p=(Mydata *)env->userData;
int i=0;
if(p->mygrand)
{
///场地变换,球坐标变换
//我方是黄队
p->gameState = env->gameState ;
switch(env->whoseBall) //据说环境给出的控球消息不准确...可参考别的代码...貌似有能抄的...
{
case ANYONES_BALL ://自由球,在处理球的时候这种方法可能不保险
//最好包括用球的坐标,来判断谁的点球,和其他的球
p->whoseBall = 0;
case BLUE_BALL :
p->whoseBall = 1;
case YELLOW_BALL:
p->whoseBall =2 ;
}
//对于黄队,坐标系如图...
/*
^ y ^ y
| |
黄队 | (默认情况) 蓝队(需要转换) |
|__ __ __>x x<__ __ __|
*/
p->curball.x = env->currentBall.pos.x; //球坐标变化
p->curball.y = env->currentBall.pos.y;
//p->curball.z = env->currentBall.pos.z;
for(i=0; i<5; i++)
{
p->robot[i].pos.x = env->home[i].pos.x ; //我方队员坐标变换
p->robot[i].pos.y = env->home[i].pos.y ;
//p->robot[i].pos.z = env->home[i].pos.z ;
p->robot[i].rotation= env->home[i].rotation;
p->opp[i].pos.x =env->opponent[i].pos.x; //对方坐标变换
p->opp[i].pos.y =env->opponent[i].pos.y;
//p->opp[i].pos.z = env->opponent[i].pos.z;
p->opp[i].rotation =env->opponent[i].rotation;
ReAngle(p->opp[i].rotation);
}
}
else
{
//we are blue
p->gameState = env->gameState ;
switch(env->whoseBall)
{
case ANYONES_BALL ://自由球,在处理球的时候这种方法可能不保险 Break??!!!!!!!!!
//最好包括用球的坐标,来判断谁的点球,和其他的球
p->whoseBall = 0;
case BLUE_BALL :
p->whoseBall = 2;
case YELLOW_BALL:
p->whoseBall = 1;
}
p->curball.x =FLEFTX+FRIGHTH + CORRECTX - env->currentBall.pos.x; //球坐标变化
p->curball.y =FBOT+FTOP + CORRECTY - env->currentBall.pos.y;
//p->curball.z = env->currentBall.pos.z;
for(i=0; i<5; i++)
{
p->robot[i].pos.x =FLEFTX+FRIGHTH + CORRECTX - env->home[i].pos.x ; //我方队员坐标变换
p->robot[i].pos.y =FBOT+FTOP + CORRECTY - env->home[i].pos.y ;
//p->robot[i].pos.z = env->home[i].pos.z ;
p->robot[i].rotation= 180.0 + env->home[i].rotation;
ReAngle(p->robot[i].rotation);
p->opp[i].pos.x = FLEFTX+FRIGHTH + CORRECTX- env->opponent[i].pos.x; //对方坐标变换
p->opp[i].pos.y = FBOT+FTOP + CORRECTY - env->opponent[i].pos.y;
//p->opp[i].pos.z = env->opponent[i].pos.z;
p->opp[i].rotation = 180 + env->opponent[i].rotation;
ReAngle(p->opp[i].rotation);
}
}
////第一次处理速度 (上次)................判断是不是暂停过之后重新开球了...一周期内产生位移大于10...
bool ReSet=false;
if(p->curball.x -p->oldball.x > 10 || p->curball.x -p->oldball.x < -10 || p->curball.y -p->oldball.y > 10 || p->curball.y -p->oldball.y < -10 )
{
ReSet=true;
}
for(i=0; i<5; i++)
{
if(p->robot[i].pos.x -p->myoldpos[i].x > 10 || p->robot[i].pos.x -p->myoldpos[i].x < -10 || p->robot[i].pos.y -p->myoldpos[i].y > 10 || p->robot[i].pos.y -p->myoldpos[i].y < -10 )
{
ReSet=true;
}
if(p->opp[i].pos.x -p->opoldpos[i].x > 10 || p->opp[i].pos.x -p->opoldpos[i].x < -10 || p->opp[i].pos.y -p->opoldpos[i].y > 10 || p->opp[i].pos.y -p->opoldpos[i].y < -10 )
{
ReSet=true;
}
}
if(ReSet==true)
{
p->flag=true;//重新开球标志
for(i=0; i<5; i++)
{
///speed...重新初始化变量...
p->myspeed[i].x = 0; //70为比例系数,有待调整
p->myspeed[i].y = 0;
p->myspeed[i].z = 0; //关于他的 运动方向 和转角速度,考虑中
p->opspeed[i].x = 0;
p->opspeed[i].y = 0;
p->opspeed[i].z = 0;
}
p->ballspeed.x = 0;
p->ballspeed.y = 0;
p->ballspeed.z = 0;
}
else
{
p->flag=false;
for(i=0; i<5; i++)
{
///speed
p->myspeed[i].x = ( p->robot[i].pos.x - p->myoldpos[i].x); //70为比例系数,有待调整 deltaX
p->myspeed[i].y = ( p->robot[i].pos.y - p->myoldpos[i].y); //deltaY
p->myspeed[i].z = Atan(p->myspeed[i].y,p->myspeed[i].x); //关于他的 运动方向 和转角速度,考虑中
p->opspeed[i].x = ( p->opp[i].pos.x - p->opoldpos[i].x);
p->opspeed[i].y = ( p->opp[i].pos.y - p->opoldpos[i].y);
p->opspeed[i].z = Atan(p->opspeed[i].y,p->opspeed[i].x);
}
p->ballspeed.x = p->curball.x - p->oldball.x;
p->ballspeed.y = p->curball.y - p->oldball.y;
p->ballspeed.z = Atan( p->ballspeed.y , p->ballspeed.x );
//预测下一周期本队机器人运动
{
double v,a,b,c,omiga,angle;
for(i=0; i<5; i++)
{
omiga = p->robot[i].rotation - p->myoldpos[i].z ;//上周期至本周期偏转角
ReAngle(omiga);//归为-180--180
omiga = AngleOne(omiga,p->myoldvelocity[i].x , p->myoldvelocity[i].y);//计算下一个周期达到的角速度
c = p->robot[i].rotation;
p->robot[i].rotation+=omiga;//下周期的朝向
ReAngle(p->robot[i].rotation);
v = sqrt((p->myspeed[i].x * p->myspeed[i].x) + (p->myspeed[i].y * p->myspeed[i].y));//本周期速度
angle = p->robot[i].rotation - p->myspeed[i].z;//本周期至下周期偏转角
ReAngle(angle);
if(angle >-90 && angle < 90 )
v=v;
else
v=-v;
v=VelocityOne(v,p->myoldvelocity[i].x , p->myoldvelocity[i].y);//下一个周期速度
a=p->robot[i].pos.x;//保存本周期坐标
b=p->robot[i].pos.y;
p->robot[i].pos.x += v*cos( p->robot[i].rotation * PI / 180) ;//下周期坐标
p->robot[i].pos.y += v*sin( p->robot[i].rotation * PI / 180) ;
///处理撞墙
//不处理最好
////处理撞墙
p->myoldpos[i].x =a;
p->myoldpos[i].y =b;
p->myoldpos[i].z =c;
p->myspeed[i].x = ( p->robot[i].pos.x - p->myoldpos[i].x ); //70为比例系数,有待调整//下一周期deltaX
p->myspeed[i].y = ( p->robot[i].pos.y - p->myoldpos[i].y );//下一周期deltaY
p->myspeed[i].z = Atan( p->myspeed[i].y , p->myspeed[i].x );//下一周期朝向
}
///////// 预测球的坐标
double x,y;
x = p->curball.x ;
y = p->curball.y ;
PredictBall(env); //求到现在球的位置
p->curball = p->preball;
p->oldball.x = x;
p->oldball.y = y;
PredictBall(env); //预测下一步球的位置
p->ballspeed.x = p->curball.x - p->oldball.x;
p->ballspeed.y = p->curball.y - p->oldball.y;
p->ballspeed.z = Atan( p->ballspeed.y , p->ballspeed.x );
}
}
PredictBall2(env);
for(i=0; i<5; i++)
{
//赋初值
p->robot[i].velocityLeft = 0;
p->robot[i].velocityRight = 0;
}
}
extern "C" STRATEGY_API void Destroy ( Environment *env )
{
}
|
33c38fb641b35d34606c683e4802c72eb7cec08d | a92b18defb50c5d1118a11bc364f17b148312028 | /src/prod/src/Reliability/LoadBalancing/ApplicationEntry.cpp | 61dc5d9d86ac41a5295d924344725e9c8c9d8131 | [
"MIT"
] | permissive | KDSBest/service-fabric | 34694e150fde662286e25f048fb763c97606382e | fe61c45b15a30fb089ad891c68c893b3a976e404 | refs/heads/master | 2023-01-28T23:19:25.040275 | 2020-11-30T11:11:58 | 2020-11-30T11:11:58 | 301,365,601 | 1 | 0 | MIT | 2020-11-30T11:11:59 | 2020-10-05T10:05:53 | null | UTF-8 | C++ | false | false | 10,705 | cpp | ApplicationEntry.cpp | // ------------------------------------------------------------
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License (MIT). See License.txt in the repo root for license information.
// ------------------------------------------------------------
#include "stdafx.h"
#include "PlacementReplica.h"
#include "ApplicationEntry.h"
#include "TempSolution.h"
#include "PlacementAndLoadBalancing.h"
using namespace std;
using namespace Common;
using namespace Reliability::LoadBalancingComponent;
ApplicationEntry::ApplicationEntry(
wstring && name,
uint64 applicationId,
int scaleoutCount,
LoadEntry && appCapacities,
LoadEntry && perNodeCapacities,
LoadEntry && reservation,
LoadEntry && totalLoad,
std::map<NodeEntry const*, LoadEntry> && nodeLoads,
std::map<NodeEntry const*, LoadEntry> && disappearingNodeLoads,
std::map<NodeEntry const*, size_t> && nodeCounts,
std::set<Common::TreeNodeIndex> && ugradedUDs)
: name_(move(name)),
applicationId_(applicationId),
scaleoutCount_(scaleoutCount),
appCapacities_(move(appCapacities)),
perNodeCapacities_(move(perNodeCapacities)),
reservation_(move(reservation)),
hasAppCapacity_(false),
hasPerNodeCapacity_(false),
hasReservation_(false),
totalLoads_(move(totalLoad)),
nodeLoads_(move(nodeLoads)),
disappearingNodeLoads_(move(disappearingNodeLoads)),
nodeCounts_(move(nodeCounts)),
upgradeCompletedUDs_(move(ugradedUDs)),
hasPartitionsInSingletonReplicaUpgrade_(false),
corelatedSingletonReplicasInUpgrade_()
{
ASSERT_IFNOT(appCapacities_.Values.size() == perNodeCapacities_.Values.size(),
"Application capacities size {0} and capacity per node size {1} should be equal",
appCapacities_.Values.size(), perNodeCapacities_.Values.size());
if (find_if(appCapacities_.Values.begin(), appCapacities_.Values.end(), [](int64 value) { return value >= 0; })
!= appCapacities_.Values.end())
{
hasAppCapacity_ = true;
}
if (find_if(perNodeCapacities_.Values.begin(), perNodeCapacities_.Values.end(), [](int64 value) { return value >= 0; })
!= perNodeCapacities_.Values.end())
{
hasPerNodeCapacity_ = true;
}
if (find_if(reservation_.Values.begin(), reservation_.Values.end(), [](int64 value) { return value > 0; })
!= reservation_.Values.end())
{
hasReservation_ = true;
}
hasScaleoutOrCapacity_ = hasAppCapacity_ || hasPerNodeCapacity_ || hasReservation_ || (scaleoutCount > 0);
}
ApplicationEntry::ApplicationEntry(ApplicationEntry && other)
: name_(move(other.name_)),
applicationId_(other.applicationId_),
scaleoutCount_(other.scaleoutCount_),
appCapacities_(move(other.appCapacities_)),
perNodeCapacities_(move(other.perNodeCapacities_)),
reservation_(move(other.reservation_)),
hasAppCapacity_(other.hasAppCapacity_),
hasPerNodeCapacity_(other.hasPerNodeCapacity_),
hasReservation_(other.hasReservation_),
totalLoads_(move(other.totalLoads_)),
nodeLoads_(move(other.NodeLoads)),
disappearingNodeLoads_(move(other.disappearingNodeLoads_)),
nodeCounts_(move(other.nodeCounts_)),
upgradeCompletedUDs_(move(other.upgradeCompletedUDs_)),
hasScaleoutOrCapacity_(other.hasScaleoutOrCapacity_),
hasPartitionsInSingletonReplicaUpgrade_(other.hasPartitionsInSingletonReplicaUpgrade_),
corelatedSingletonReplicasInUpgrade_(move(other.corelatedSingletonReplicasInUpgrade_))
{
}
ApplicationEntry & ApplicationEntry::operator = (ApplicationEntry && other)
{
if (this != &other)
{
name_ = move(other.name_);
applicationId_ = other.applicationId_;
scaleoutCount_ = other.scaleoutCount_;
appCapacities_ = move(other.appCapacities_);
perNodeCapacities_ = move(other.perNodeCapacities_);
reservation_ = move(other.reservation_);
hasAppCapacity_ = other.hasAppCapacity_;
hasPerNodeCapacity_ = other.hasPerNodeCapacity_;
hasReservation_ = other.hasReservation_;
totalLoads_ = move(other.totalLoads_);
nodeLoads_ = move(other.nodeLoads_);
disappearingNodeLoads_ = move(other.disappearingNodeLoads_);
nodeCounts_ = move(other.nodeCounts_);
upgradeCompletedUDs_ = move(other.upgradeCompletedUDs_);
hasScaleoutOrCapacity_ = other.hasScaleoutOrCapacity_;
hasPartitionsInSingletonReplicaUpgrade_ = other.hasPartitionsInSingletonReplicaUpgrade_;
corelatedSingletonReplicasInUpgrade_ = move(other.corelatedSingletonReplicasInUpgrade_);
}
return *this;
}
// return the effective load reservation.
int64 ApplicationEntry::GetReservationDiff(size_t capacityIndex, int64 actualNodeLoad) const
{
if (reservation_.Values.empty())
{
// No reservation capacity defined
return 0;
}
int64 diff = (actualNodeLoad < reservation_.Values[capacityIndex] ? (reservation_.Values[capacityIndex] - actualNodeLoad) : 0);
return diff;
}
int64 ApplicationEntry::GetMetricNodeLoad(NodeEntry const* node, size_t metricIndex) const
{
auto itOrigLoad = NodeLoads.find(node);
if (itOrigLoad != NodeLoads.end())
{
return itOrigLoad->second.Values[metricIndex];
}
return 0;
}
int64 ApplicationEntry::GetDisappearingMetricNodeLoad(NodeEntry const* node, size_t metricIndex) const
{
auto itDisappearingLoad = DisappearingNodeLoads.find(node);
if (itDisappearingLoad != DisappearingNodeLoads.end())
{
return itDisappearingLoad->second.Values[metricIndex];
}
return 0;
}
void ApplicationEntry::SetRelaxedScaleoutReplicaSet(Placement const* placement)
{
int appNodeCount = static_cast<int>(NodeCounts.size());
bool hasNonMovableReplicas = false;
// If application is in a scaleout violation with more that 2 nodes
// then do not proceed with the upgrade
if (appNodeCount > 2)
{
corelatedSingletonReplicasInUpgrade_.clear();
return;
}
// Function that adds movable replicas to the vector
auto AddMovableReplicasFunc = [&](const Reliability::LoadBalancingComponent::PlacementReplica *const curReplica)
{
// If the replica is in StandBy state,
// (return persisted service after upgrade)
// skip the search, as movable replica is already included
if (curReplica->Role != ReplicaRole::Enum::StandBy)
{
// If partition is in upgrade, return new one.
// Find movable replicas, for partitions which are not in upgrade,
// but belongs to the application in singleton replica upgrade
// (returns nullptr if there is none)
PlacementReplica const* replica = curReplica->Partition->FindMovableReplicaForSingletonReplicaUpgrade();
if (replica)
{
corelatedSingletonReplicasInUpgrade_.push_back(replica);
}
else
{
hasNonMovableReplicas = true;
}
}
};
// Add replicas from all relevant application partitions (including also the ones that are not in upgrade yet or from stateless services)
// Application node count can have following values:
// - One node:
// * In this case we either have all partitions in upgrade or some still didn't receive +1 (or stateless),
// but there were no movements generated
// Node: N0 N1
// Replicas(+1): P/LI
// Replicas(-): P
// Replicas(-): S
// - Two nodes:
// * Either it is not an initial upgrade run (some replicas have successfully moved and build to destination node)
// and all other replicas from the source node are now in upgrade mode (initial move was dropped by FM)
// Node: N0 N1
// Replicas(-): S P
// Replicas(+1): P/LI
// Or application was in scaleout violation before upgrade, in which case optimization will wait for violation fix.
if (appNodeCount == 1)
{
NodeEntry const* node = NodeCounts.begin()->first;
ReplicaSet const& replicas = placement->ApplicationPlacements[this].operator[](node);
std::for_each(replicas.Data.begin(), replicas.Data.end(), AddMovableReplicasFunc);
}
else
{
// Include all relevant replicas from both nodes
placement->ApplicationPlacements[this].ForEach([&](std::pair<NodeEntry const*, ReplicaSet> const& itAppNode) -> bool
{
ReplicaSet const& curNodereplicas = itAppNode.second;
std::for_each(curNodereplicas.Data.begin(), curNodereplicas.Data.end(), AddMovableReplicasFunc);
return true;
});
}
// If there is a non-movable replica in the application
// which is correlated to the in-upgrade replicas,
// clear the list and wait for future runs to move all replicas
if (hasNonMovableReplicas)
{
corelatedSingletonReplicasInUpgrade_.clear();
}
}
bool ApplicationEntry::IsInSingletonReplicaUpgrade(PlacementAndLoadBalancing const& plb, vector<PlacementReplica *>& replicas) const
{
bool isAppInSingletonUpgrade = false;
// Check if it is application upgrade
Application const* app = plb.GetApplicationPtrCallerHoldsLock(ApplicationId);
if (app != nullptr && app->ApplicationDesc.UpgradeInProgess)
{
isAppInSingletonUpgrade = true;
}
// Check if it is cluster upgrade
if (const_cast<PlacementAndLoadBalancing&>(plb).IsClusterUpgradeInProgress())
{
isAppInSingletonUpgrade = true;
}
// Check if it is node deactivation
for (auto itReplica = replicas.begin(); itReplica != replicas.end(); ++itReplica)
{
PlacementReplica * replica = *itReplica;
if (replica->Role == ReplicaRole::Primary &&
replica->IsOnDeactivatedNode)
{
isAppInSingletonUpgrade = true;
}
}
return isAppInSingletonUpgrade;
}
GlobalWString const ApplicationEntry::TraceDescription = make_global<wstring>(
L"[Applications]\r\n#applicationName scaleoutCount appCapacities perNodeCapacities");
void ApplicationEntry::WriteTo(TextWriter& writer, FormatOptions const&) const
{
writer.Write("{0} {1} {2} {3} {4} {5} {6} {7}", name_, scaleoutCount_, appCapacities_, perNodeCapacities_, reservation_,
hasAppCapacity_, hasPerNodeCapacity_, totalLoads_);
}
void ApplicationEntry::WriteToEtw(uint16 contextSequenceId) const
{
PlacementAndLoadBalancing::PLBTrace->PLBDump(contextSequenceId, wformatString(*this));
}
|
3aa158b2b61d106db6cc9f5d46a53989393ee48f | a2206795a05877f83ac561e482e7b41772b22da8 | /Source/PV/build/VTK/Wrapping/Python/vtkBSPCutsPython.cxx | 06c0311ce3d41a9142e999cce913ddfcad39fb21 | [] | no_license | supreethms1809/mpas-insitu | 5578d465602feb4d6b239a22912c33918c7bb1c3 | 701644bcdae771e6878736cb6f49ccd2eb38b36e | refs/heads/master | 2020-03-25T16:47:29.316814 | 2018-08-08T02:00:13 | 2018-08-08T02:00:13 | 143,947,446 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 24,470 | cxx | vtkBSPCutsPython.cxx | // python wrapper for vtkBSPCuts
//
#define VTK_WRAPPING_CXX
#define VTK_STREAMS_FWD_ONLY
#include "vtkPythonArgs.h"
#include "vtkPythonOverload.h"
#include "vtkConfigure.h"
#include <vtksys/ios/sstream>
#include "vtkIndent.h"
#include "vtkBSPCuts.h"
#if defined(VTK_BUILD_SHARED_LIBS)
# define VTK_PYTHON_EXPORT VTK_ABI_EXPORT
# define VTK_PYTHON_IMPORT VTK_ABI_IMPORT
#else
# define VTK_PYTHON_EXPORT VTK_ABI_EXPORT
# define VTK_PYTHON_IMPORT VTK_ABI_EXPORT
#endif
extern "C" { VTK_PYTHON_EXPORT void PyVTKAddFile_vtkBSPCuts(PyObject *, const char *); }
extern "C" { VTK_PYTHON_EXPORT PyObject *PyVTKClass_vtkBSPCutsNew(const char *); }
#ifndef DECLARED_PyVTKClass_vtkDataObjectNew
extern "C" { PyObject *PyVTKClass_vtkDataObjectNew(const char *); }
#define DECLARED_PyVTKClass_vtkDataObjectNew
#endif
static const char **PyvtkBSPCuts_Doc();
static PyObject *
PyvtkBSPCuts_GetClassName(PyObject *self, PyObject *args)
{
vtkPythonArgs ap(self, args, "GetClassName");
vtkObjectBase *vp = ap.GetSelfPointer(self, args);
vtkBSPCuts *op = static_cast<vtkBSPCuts *>(vp);
PyObject *result = NULL;
if (op && ap.CheckArgCount(0))
{
const char *tempr = (ap.IsBound() ?
op->GetClassName() :
op->vtkBSPCuts::GetClassName());
if (!ap.ErrorOccurred())
{
result = ap.BuildValue(tempr);
}
}
return result;
}
static PyObject *
PyvtkBSPCuts_IsA(PyObject *self, PyObject *args)
{
vtkPythonArgs ap(self, args, "IsA");
vtkObjectBase *vp = ap.GetSelfPointer(self, args);
vtkBSPCuts *op = static_cast<vtkBSPCuts *>(vp);
char *temp0 = NULL;
PyObject *result = NULL;
if (op && ap.CheckArgCount(1) &&
ap.GetValue(temp0))
{
int tempr = (ap.IsBound() ?
op->IsA(temp0) :
op->vtkBSPCuts::IsA(temp0));
if (!ap.ErrorOccurred())
{
result = ap.BuildValue(tempr);
}
}
return result;
}
static PyObject *
PyvtkBSPCuts_NewInstance(PyObject *self, PyObject *args)
{
vtkPythonArgs ap(self, args, "NewInstance");
vtkObjectBase *vp = ap.GetSelfPointer(self, args);
vtkBSPCuts *op = static_cast<vtkBSPCuts *>(vp);
PyObject *result = NULL;
if (op && ap.CheckArgCount(0))
{
vtkBSPCuts *tempr = (ap.IsBound() ?
op->NewInstance() :
op->vtkBSPCuts::NewInstance());
if (!ap.ErrorOccurred())
{
result = ap.BuildVTKObject(tempr);
if (result && PyVTKObject_Check(result))
{
PyVTKObject_GetObject(result)->UnRegister(0);
PyVTKObject_SetFlag(result, VTK_PYTHON_IGNORE_UNREGISTER, 1);
}
}
}
return result;
}
static PyObject *
PyvtkBSPCuts_SafeDownCast(PyObject *, PyObject *args)
{
vtkPythonArgs ap(args, "SafeDownCast");
vtkObject *temp0 = NULL;
PyObject *result = NULL;
if (ap.CheckArgCount(1) &&
ap.GetVTKObject(temp0, "vtkObject"))
{
vtkBSPCuts *tempr = vtkBSPCuts::SafeDownCast(temp0);
if (!ap.ErrorOccurred())
{
result = ap.BuildVTKObject(tempr);
}
}
return result;
}
static PyObject *
PyvtkBSPCuts_CreateCuts_s1(PyObject *self, PyObject *args)
{
vtkPythonArgs ap(self, args, "CreateCuts");
vtkObjectBase *vp = ap.GetSelfPointer(self, args);
vtkBSPCuts *op = static_cast<vtkBSPCuts *>(vp);
double *temp0 = NULL;
double *save0 = NULL;
double small0[8];
int size0 = 0;
int temp1;
int *temp2 = NULL;
int *save2 = NULL;
int small2[8];
int size2 = 0;
double *temp3 = NULL;
double *save3 = NULL;
double small3[8];
int size3 = 0;
int *temp4 = NULL;
int *save4 = NULL;
int small4[8];
int size4 = 0;
int *temp5 = NULL;
int *save5 = NULL;
int small5[8];
int size5 = 0;
double *temp6 = NULL;
double *save6 = NULL;
double small6[8];
int size6 = 0;
double *temp7 = NULL;
double *save7 = NULL;
double small7[8];
int size7 = 0;
int *temp8 = NULL;
int *save8 = NULL;
int small8[8];
int size8 = 0;
PyObject *result = NULL;
if (op)
{
size0 = ap.GetArgSize(0);
temp0 = small0;
if (size0 > 4)
{
temp0 = new double[2*size0];
}
save0 = &temp0[size0];
size2 = ap.GetArgSize(2);
temp2 = small2;
if (size2 > 4)
{
temp2 = new int[2*size2];
}
save2 = &temp2[size2];
size3 = ap.GetArgSize(3);
temp3 = small3;
if (size3 > 4)
{
temp3 = new double[2*size3];
}
save3 = &temp3[size3];
size4 = ap.GetArgSize(4);
temp4 = small4;
if (size4 > 4)
{
temp4 = new int[2*size4];
}
save4 = &temp4[size4];
size5 = ap.GetArgSize(5);
temp5 = small5;
if (size5 > 4)
{
temp5 = new int[2*size5];
}
save5 = &temp5[size5];
size6 = ap.GetArgSize(6);
temp6 = small6;
if (size6 > 4)
{
temp6 = new double[2*size6];
}
save6 = &temp6[size6];
size7 = ap.GetArgSize(7);
temp7 = small7;
if (size7 > 4)
{
temp7 = new double[2*size7];
}
save7 = &temp7[size7];
size8 = ap.GetArgSize(8);
temp8 = small8;
if (size8 > 4)
{
temp8 = new int[2*size8];
}
save8 = &temp8[size8];
}
if (op && ap.CheckArgCount(9) &&
ap.GetArray(temp0, size0) &&
ap.GetValue(temp1) &&
ap.GetArray(temp2, size2) &&
ap.GetArray(temp3, size3) &&
ap.GetArray(temp4, size4) &&
ap.GetArray(temp5, size5) &&
ap.GetArray(temp6, size6) &&
ap.GetArray(temp7, size7) &&
ap.GetArray(temp8, size8))
{
ap.SaveArray(temp0, save0, size0);
ap.SaveArray(temp2, save2, size2);
ap.SaveArray(temp3, save3, size3);
ap.SaveArray(temp4, save4, size4);
ap.SaveArray(temp5, save5, size5);
ap.SaveArray(temp6, save6, size6);
ap.SaveArray(temp7, save7, size7);
ap.SaveArray(temp8, save8, size8);
if (ap.IsBound())
{
op->CreateCuts(temp0, temp1, temp2, temp3, temp4, temp5, temp6, temp7, temp8);
}
else
{
op->vtkBSPCuts::CreateCuts(temp0, temp1, temp2, temp3, temp4, temp5, temp6, temp7, temp8);
}
if (ap.ArrayHasChanged(temp0, save0, size0) &&
!ap.ErrorOccurred())
{
ap.SetArray(0, temp0, size0);
}
if (ap.ArrayHasChanged(temp2, save2, size2) &&
!ap.ErrorOccurred())
{
ap.SetArray(2, temp2, size2);
}
if (ap.ArrayHasChanged(temp3, save3, size3) &&
!ap.ErrorOccurred())
{
ap.SetArray(3, temp3, size3);
}
if (ap.ArrayHasChanged(temp4, save4, size4) &&
!ap.ErrorOccurred())
{
ap.SetArray(4, temp4, size4);
}
if (ap.ArrayHasChanged(temp5, save5, size5) &&
!ap.ErrorOccurred())
{
ap.SetArray(5, temp5, size5);
}
if (ap.ArrayHasChanged(temp6, save6, size6) &&
!ap.ErrorOccurred())
{
ap.SetArray(6, temp6, size6);
}
if (ap.ArrayHasChanged(temp7, save7, size7) &&
!ap.ErrorOccurred())
{
ap.SetArray(7, temp7, size7);
}
if (ap.ArrayHasChanged(temp8, save8, size8) &&
!ap.ErrorOccurred())
{
ap.SetArray(8, temp8, size8);
}
if (!ap.ErrorOccurred())
{
result = ap.BuildNone();
}
}
if (temp0 && temp0 != small0)
{
delete [] temp0;
}
if (temp2 && temp2 != small2)
{
delete [] temp2;
}
if (temp3 && temp3 != small3)
{
delete [] temp3;
}
if (temp4 && temp4 != small4)
{
delete [] temp4;
}
if (temp5 && temp5 != small5)
{
delete [] temp5;
}
if (temp6 && temp6 != small6)
{
delete [] temp6;
}
if (temp7 && temp7 != small7)
{
delete [] temp7;
}
if (temp8 && temp8 != small8)
{
delete [] temp8;
}
return result;
}
static PyObject *
PyvtkBSPCuts_CreateCuts_s2(PyObject *self, PyObject *args)
{
vtkPythonArgs ap(self, args, "CreateCuts");
vtkObjectBase *vp = ap.GetSelfPointer(self, args);
vtkBSPCuts *op = static_cast<vtkBSPCuts *>(vp);
vtkKdNode *temp0 = NULL;
PyObject *result = NULL;
if (op && ap.CheckArgCount(1) &&
ap.GetVTKObject(temp0, "vtkKdNode"))
{
if (ap.IsBound())
{
op->CreateCuts(temp0);
}
else
{
op->vtkBSPCuts::CreateCuts(temp0);
}
if (!ap.ErrorOccurred())
{
result = ap.BuildNone();
}
}
return result;
}
static PyObject *
PyvtkBSPCuts_CreateCuts(PyObject *self, PyObject *args)
{
int nargs = vtkPythonArgs::GetArgCount(self, args);
switch(nargs)
{
case 9:
return PyvtkBSPCuts_CreateCuts_s1(self, args);
case 1:
return PyvtkBSPCuts_CreateCuts_s2(self, args);
}
vtkPythonArgs::ArgCountError(nargs, "CreateCuts");
return NULL;
}
static PyObject *
PyvtkBSPCuts_GetKdNodeTree(PyObject *self, PyObject *args)
{
vtkPythonArgs ap(self, args, "GetKdNodeTree");
vtkObjectBase *vp = ap.GetSelfPointer(self, args);
vtkBSPCuts *op = static_cast<vtkBSPCuts *>(vp);
PyObject *result = NULL;
if (op && ap.CheckArgCount(0))
{
vtkKdNode *tempr = (ap.IsBound() ?
op->GetKdNodeTree() :
op->vtkBSPCuts::GetKdNodeTree());
if (!ap.ErrorOccurred())
{
result = ap.BuildVTKObject(tempr);
}
}
return result;
}
static PyObject *
PyvtkBSPCuts_GetNumberOfCuts(PyObject *self, PyObject *args)
{
vtkPythonArgs ap(self, args, "GetNumberOfCuts");
vtkObjectBase *vp = ap.GetSelfPointer(self, args);
vtkBSPCuts *op = static_cast<vtkBSPCuts *>(vp);
PyObject *result = NULL;
if (op && ap.CheckArgCount(0))
{
int tempr = (ap.IsBound() ?
op->GetNumberOfCuts() :
op->vtkBSPCuts::GetNumberOfCuts());
if (!ap.ErrorOccurred())
{
result = ap.BuildValue(tempr);
}
}
return result;
}
static PyObject *
PyvtkBSPCuts_GetArrays(PyObject *self, PyObject *args)
{
vtkPythonArgs ap(self, args, "GetArrays");
vtkObjectBase *vp = ap.GetSelfPointer(self, args);
vtkBSPCuts *op = static_cast<vtkBSPCuts *>(vp);
int temp0;
int *temp1 = NULL;
int *save1 = NULL;
int small1[8];
int size1 = 0;
double *temp2 = NULL;
double *save2 = NULL;
double small2[8];
int size2 = 0;
int *temp3 = NULL;
int *save3 = NULL;
int small3[8];
int size3 = 0;
int *temp4 = NULL;
int *save4 = NULL;
int small4[8];
int size4 = 0;
double *temp5 = NULL;
double *save5 = NULL;
double small5[8];
int size5 = 0;
double *temp6 = NULL;
double *save6 = NULL;
double small6[8];
int size6 = 0;
int *temp7 = NULL;
int *save7 = NULL;
int small7[8];
int size7 = 0;
PyObject *result = NULL;
if (op)
{
size1 = ap.GetArgSize(1);
temp1 = small1;
if (size1 > 4)
{
temp1 = new int[2*size1];
}
save1 = &temp1[size1];
size2 = ap.GetArgSize(2);
temp2 = small2;
if (size2 > 4)
{
temp2 = new double[2*size2];
}
save2 = &temp2[size2];
size3 = ap.GetArgSize(3);
temp3 = small3;
if (size3 > 4)
{
temp3 = new int[2*size3];
}
save3 = &temp3[size3];
size4 = ap.GetArgSize(4);
temp4 = small4;
if (size4 > 4)
{
temp4 = new int[2*size4];
}
save4 = &temp4[size4];
size5 = ap.GetArgSize(5);
temp5 = small5;
if (size5 > 4)
{
temp5 = new double[2*size5];
}
save5 = &temp5[size5];
size6 = ap.GetArgSize(6);
temp6 = small6;
if (size6 > 4)
{
temp6 = new double[2*size6];
}
save6 = &temp6[size6];
size7 = ap.GetArgSize(7);
temp7 = small7;
if (size7 > 4)
{
temp7 = new int[2*size7];
}
save7 = &temp7[size7];
}
if (op && ap.CheckArgCount(8) &&
ap.GetValue(temp0) &&
ap.GetArray(temp1, size1) &&
ap.GetArray(temp2, size2) &&
ap.GetArray(temp3, size3) &&
ap.GetArray(temp4, size4) &&
ap.GetArray(temp5, size5) &&
ap.GetArray(temp6, size6) &&
ap.GetArray(temp7, size7))
{
ap.SaveArray(temp1, save1, size1);
ap.SaveArray(temp2, save2, size2);
ap.SaveArray(temp3, save3, size3);
ap.SaveArray(temp4, save4, size4);
ap.SaveArray(temp5, save5, size5);
ap.SaveArray(temp6, save6, size6);
ap.SaveArray(temp7, save7, size7);
int tempr = (ap.IsBound() ?
op->GetArrays(temp0, temp1, temp2, temp3, temp4, temp5, temp6, temp7) :
op->vtkBSPCuts::GetArrays(temp0, temp1, temp2, temp3, temp4, temp5, temp6, temp7));
if (ap.ArrayHasChanged(temp1, save1, size1) &&
!ap.ErrorOccurred())
{
ap.SetArray(1, temp1, size1);
}
if (ap.ArrayHasChanged(temp2, save2, size2) &&
!ap.ErrorOccurred())
{
ap.SetArray(2, temp2, size2);
}
if (ap.ArrayHasChanged(temp3, save3, size3) &&
!ap.ErrorOccurred())
{
ap.SetArray(3, temp3, size3);
}
if (ap.ArrayHasChanged(temp4, save4, size4) &&
!ap.ErrorOccurred())
{
ap.SetArray(4, temp4, size4);
}
if (ap.ArrayHasChanged(temp5, save5, size5) &&
!ap.ErrorOccurred())
{
ap.SetArray(5, temp5, size5);
}
if (ap.ArrayHasChanged(temp6, save6, size6) &&
!ap.ErrorOccurred())
{
ap.SetArray(6, temp6, size6);
}
if (ap.ArrayHasChanged(temp7, save7, size7) &&
!ap.ErrorOccurred())
{
ap.SetArray(7, temp7, size7);
}
if (!ap.ErrorOccurred())
{
result = ap.BuildValue(tempr);
}
}
if (temp1 && temp1 != small1)
{
delete [] temp1;
}
if (temp2 && temp2 != small2)
{
delete [] temp2;
}
if (temp3 && temp3 != small3)
{
delete [] temp3;
}
if (temp4 && temp4 != small4)
{
delete [] temp4;
}
if (temp5 && temp5 != small5)
{
delete [] temp5;
}
if (temp6 && temp6 != small6)
{
delete [] temp6;
}
if (temp7 && temp7 != small7)
{
delete [] temp7;
}
return result;
}
static PyObject *
PyvtkBSPCuts_Equals(PyObject *self, PyObject *args)
{
vtkPythonArgs ap(self, args, "Equals");
vtkObjectBase *vp = ap.GetSelfPointer(self, args);
vtkBSPCuts *op = static_cast<vtkBSPCuts *>(vp);
vtkBSPCuts *temp0 = NULL;
double temp1 = 0.0;
PyObject *result = NULL;
if (op && ap.CheckArgCount(1, 2) &&
ap.GetVTKObject(temp0, "vtkBSPCuts") &&
(ap.NoArgsLeft() || ap.GetValue(temp1)))
{
int tempr = (ap.IsBound() ?
op->Equals(temp0, temp1) :
op->vtkBSPCuts::Equals(temp0, temp1));
if (!ap.ErrorOccurred())
{
result = ap.BuildValue(tempr);
}
}
return result;
}
static PyObject *
PyvtkBSPCuts_PrintTree(PyObject *self, PyObject *args)
{
vtkPythonArgs ap(self, args, "PrintTree");
vtkObjectBase *vp = ap.GetSelfPointer(self, args);
vtkBSPCuts *op = static_cast<vtkBSPCuts *>(vp);
PyObject *result = NULL;
if (op && ap.CheckArgCount(0))
{
if (ap.IsBound())
{
op->PrintTree();
}
else
{
op->vtkBSPCuts::PrintTree();
}
if (!ap.ErrorOccurred())
{
result = ap.BuildNone();
}
}
return result;
}
static PyObject *
PyvtkBSPCuts_PrintArrays(PyObject *self, PyObject *args)
{
vtkPythonArgs ap(self, args, "PrintArrays");
vtkObjectBase *vp = ap.GetSelfPointer(self, args);
vtkBSPCuts *op = static_cast<vtkBSPCuts *>(vp);
PyObject *result = NULL;
if (op && ap.CheckArgCount(0))
{
if (ap.IsBound())
{
op->PrintArrays();
}
else
{
op->vtkBSPCuts::PrintArrays();
}
if (!ap.ErrorOccurred())
{
result = ap.BuildNone();
}
}
return result;
}
static PyObject *
PyvtkBSPCuts_GetData_s1(PyObject *, PyObject *args)
{
vtkPythonArgs ap(args, "GetData");
vtkInformation *temp0 = NULL;
PyObject *result = NULL;
if (ap.CheckArgCount(1) &&
ap.GetVTKObject(temp0, "vtkInformation"))
{
vtkBSPCuts *tempr = vtkBSPCuts::GetData(temp0);
if (!ap.ErrorOccurred())
{
result = ap.BuildVTKObject(tempr);
}
}
return result;
}
static PyObject *
PyvtkBSPCuts_GetData_s2(PyObject *, PyObject *args)
{
vtkPythonArgs ap(args, "GetData");
vtkInformationVector *temp0 = NULL;
int temp1 = 0;
PyObject *result = NULL;
if (ap.CheckArgCount(1, 2) &&
ap.GetVTKObject(temp0, "vtkInformationVector") &&
(ap.NoArgsLeft() || ap.GetValue(temp1)))
{
vtkBSPCuts *tempr = vtkBSPCuts::GetData(temp0, temp1);
if (!ap.ErrorOccurred())
{
result = ap.BuildVTKObject(tempr);
}
}
return result;
}
static PyMethodDef PyvtkBSPCuts_GetData_Methods[] = {
{NULL, PyvtkBSPCuts_GetData_s1, METH_VARARGS | METH_STATIC,
(char*)"O *vtkInformation"},
{NULL, PyvtkBSPCuts_GetData_s2, METH_VARARGS | METH_STATIC,
(char*)"O|i *vtkInformationVector"},
{NULL, NULL, 0, NULL}
};
static PyObject *
PyvtkBSPCuts_GetData(PyObject *self, PyObject *args)
{
PyMethodDef *methods = PyvtkBSPCuts_GetData_Methods;
int nargs = vtkPythonArgs::GetArgCount(args);
switch(nargs)
{
case 2:
return PyvtkBSPCuts_GetData_s2(self, args);
case 1:
return vtkPythonOverload::CallMethod(methods, self, args);
}
vtkPythonArgs::ArgCountError(nargs, "GetData");
return NULL;
}
static PyObject *
PyvtkBSPCuts_Initialize(PyObject *self, PyObject *args)
{
vtkPythonArgs ap(self, args, "Initialize");
vtkObjectBase *vp = ap.GetSelfPointer(self, args);
vtkBSPCuts *op = static_cast<vtkBSPCuts *>(vp);
PyObject *result = NULL;
if (op && ap.CheckArgCount(0))
{
if (ap.IsBound())
{
op->Initialize();
}
else
{
op->vtkBSPCuts::Initialize();
}
if (!ap.ErrorOccurred())
{
result = ap.BuildNone();
}
}
return result;
}
static PyObject *
PyvtkBSPCuts_ShallowCopy(PyObject *self, PyObject *args)
{
vtkPythonArgs ap(self, args, "ShallowCopy");
vtkObjectBase *vp = ap.GetSelfPointer(self, args);
vtkBSPCuts *op = static_cast<vtkBSPCuts *>(vp);
vtkDataObject *temp0 = NULL;
PyObject *result = NULL;
if (op && ap.CheckArgCount(1) &&
ap.GetVTKObject(temp0, "vtkDataObject"))
{
if (ap.IsBound())
{
op->ShallowCopy(temp0);
}
else
{
op->vtkBSPCuts::ShallowCopy(temp0);
}
if (!ap.ErrorOccurred())
{
result = ap.BuildNone();
}
}
return result;
}
static PyObject *
PyvtkBSPCuts_DeepCopy(PyObject *self, PyObject *args)
{
vtkPythonArgs ap(self, args, "DeepCopy");
vtkObjectBase *vp = ap.GetSelfPointer(self, args);
vtkBSPCuts *op = static_cast<vtkBSPCuts *>(vp);
vtkDataObject *temp0 = NULL;
PyObject *result = NULL;
if (op && ap.CheckArgCount(1) &&
ap.GetVTKObject(temp0, "vtkDataObject"))
{
if (ap.IsBound())
{
op->DeepCopy(temp0);
}
else
{
op->vtkBSPCuts::DeepCopy(temp0);
}
if (!ap.ErrorOccurred())
{
result = ap.BuildNone();
}
}
return result;
}
static PyMethodDef PyvtkBSPCuts_Methods[] = {
{(char*)"GetClassName", PyvtkBSPCuts_GetClassName, METH_VARARGS,
(char*)"V.GetClassName() -> string\nC++: const char *GetClassName()\n\n"},
{(char*)"IsA", PyvtkBSPCuts_IsA, METH_VARARGS,
(char*)"V.IsA(string) -> int\nC++: int IsA(const char *name)\n\n"},
{(char*)"NewInstance", PyvtkBSPCuts_NewInstance, METH_VARARGS,
(char*)"V.NewInstance() -> vtkBSPCuts\nC++: vtkBSPCuts *NewInstance()\n\n"},
{(char*)"SafeDownCast", PyvtkBSPCuts_SafeDownCast, METH_VARARGS | METH_STATIC,
(char*)"V.SafeDownCast(vtkObject) -> vtkBSPCuts\nC++: vtkBSPCuts *SafeDownCast(vtkObject* o)\n\n"},
{(char*)"CreateCuts", PyvtkBSPCuts_CreateCuts, METH_VARARGS,
(char*)"V.CreateCuts([float, ...], int, [int, ...], [float, ...], [int,\n ...], [int, ...], [float, ...], [float, ...], [int, ...])\nC++: void CreateCuts(double *bounds, int ncuts, int *dim,\n double *coord, int *lower, int *upper, double *lowerDataCoord,\n double *upperDataCoord, int *npoints)\nV.CreateCuts(vtkKdNode)\nC++: void CreateCuts(vtkKdNode *kd)\n\nInitialize the cuts with arrays of information. This type of\n information would be obtained from a graph partitioning\nsoftware\n package like Zoltan.\n\n\n bounds - the bounds (xmin, xmax, ymin, ymax, zmin, zmax) of the\n space being partitioned\n ncuts - the number cuts, also the size of the following arrays\n dim - the dimension along which the cut is made (x/y/z -\n0/1/2)\n coord - the location of the cut along the axis\n lower - array index for the lower region bounded by the cut\n upper - array index for the upper region bounded by the cut\n lowerDataCoord - optional upper bound of the data in the lower\nregion\n upperDataCoord - optional lower bound of the data in the upper\nregion\n npoints - optional number of points in the spatial region\n"},
{(char*)"GetKdNodeTree", PyvtkBSPCuts_GetKdNodeTree, METH_VARARGS,
(char*)"V.GetKdNodeTree() -> vtkKdNode\nC++: vtkKdNode *GetKdNodeTree()\n\nReturn a tree of vtkKdNode's representing the cuts specified\n in this object. This is our copy, don't delete it.\n"},
{(char*)"GetNumberOfCuts", PyvtkBSPCuts_GetNumberOfCuts, METH_VARARGS,
(char*)"V.GetNumberOfCuts() -> int\nC++: int GetNumberOfCuts()\n\nGet the number of cuts in the partitioning, which also the size\nof\n the arrays in the array representation of the partitioning.\n"},
{(char*)"GetArrays", PyvtkBSPCuts_GetArrays, METH_VARARGS,
(char*)"V.GetArrays(int, [int, ...], [float, ...], [int, ...], [int, ...],\n [float, ...], [float, ...], [int, ...]) -> int\nC++: int GetArrays(int len, int *dim, double *coord, int *lower,\n int *upper, double *lowerDataCoord, double *upperDataCoord,\n int *npoints)\n\nGet the arrays representing the cuts in the partitioning.\n"},
{(char*)"Equals", PyvtkBSPCuts_Equals, METH_VARARGS,
(char*)"V.Equals(vtkBSPCuts, float) -> int\nC++: int Equals(vtkBSPCuts *other, double tolerance=0.0)\n\nCompare these cuts with those of the other tree. Returns true if\nthe two trees are the same.\n"},
{(char*)"PrintTree", PyvtkBSPCuts_PrintTree, METH_VARARGS,
(char*)"V.PrintTree()\nC++: void PrintTree()\n\n"},
{(char*)"PrintArrays", PyvtkBSPCuts_PrintArrays, METH_VARARGS,
(char*)"V.PrintArrays()\nC++: void PrintArrays()\n\n"},
{(char*)"GetData", PyvtkBSPCuts_GetData, METH_VARARGS | METH_STATIC,
(char*)"V.GetData(vtkInformation) -> vtkBSPCuts\nC++: static vtkBSPCuts *GetData(vtkInformation *info)\nV.GetData(vtkInformationVector, int) -> vtkBSPCuts\nC++: static vtkBSPCuts *GetData(vtkInformationVector *v, int i=0)\n\nRetrieve an instance of this class from an information object.\n"},
{(char*)"Initialize", PyvtkBSPCuts_Initialize, METH_VARARGS,
(char*)"V.Initialize()\nC++: virtual void Initialize()\n\nRestore data object to initial state,\n"},
{(char*)"ShallowCopy", PyvtkBSPCuts_ShallowCopy, METH_VARARGS,
(char*)"V.ShallowCopy(vtkDataObject)\nC++: virtual void ShallowCopy(vtkDataObject *src)\n\nShallow copy. These copy the data, but not any of the pipeline\nconnections.\n"},
{(char*)"DeepCopy", PyvtkBSPCuts_DeepCopy, METH_VARARGS,
(char*)"V.DeepCopy(vtkDataObject)\nC++: virtual void DeepCopy(vtkDataObject *src)\n\nShallow copy. These copy the data, but not any of the pipeline\nconnections.\n"},
{NULL, NULL, 0, NULL}
};
static vtkObjectBase *PyvtkBSPCuts_StaticNew()
{
return vtkBSPCuts::New();
}
PyObject *PyVTKClass_vtkBSPCutsNew(const char *modulename)
{
PyObject *cls = PyVTKClass_New(&PyvtkBSPCuts_StaticNew,
PyvtkBSPCuts_Methods,
"vtkBSPCuts", modulename,
NULL, NULL,
PyvtkBSPCuts_Doc(),
PyVTKClass_vtkDataObjectNew(modulename));
return cls;
}
const char **PyvtkBSPCuts_Doc()
{
static const char *docstring[] = {
"vtkBSPCuts - This class represents an axis-aligned Binary Spatial\n\n",
"Superclass: vtkDataObject\n\n",
"This class converts between the vtkKdTree\n representation of a tree of vtkKdNodes (used by\nvtkDistributedDataFilter)\n and a compact array representation that might be provided by a\n graph partitioning library like Zoltan. Such a representation\n could be used in message passing.\n\nSee Also:\n\n\n vtkKdTree vtkKdNode vtkDistributedDataFilter\n\n",
NULL
};
return docstring;
}
void PyVTKAddFile_vtkBSPCuts(
PyObject *dict, const char *modulename)
{
PyObject *o;
o = PyVTKClass_vtkBSPCutsNew(modulename);
if (o && PyDict_SetItemString(dict, (char *)"vtkBSPCuts", o) != 0)
{
Py_DECREF(o);
}
}
|
ce89614806a350c440c2983712490e3e4de771f2 | ee045b5ecd7676f69ae37111ef6df703cc4d2075 | /Codeforces/946A_Partition.cpp | c014e971ea8948041b150cb918a99b85e8c8d7d3 | [] | no_license | jguerra7/ProblemSolving-1 | 59661c6f9176f51af858f1750eef902fba17842d | 0ff07369097426c0edf21c47c1c5e538bfca1a06 | refs/heads/master | 2022-03-08T06:44:28.400804 | 2019-11-23T20:44:12 | 2019-11-23T20:44:12 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 377 | cpp | 946A_Partition.cpp | #include <bits/stdc++.h>
#define Endl "\n"
#define ll long long
using namespace std;
void init() { ios::sync_with_stdio(false); cin.tie(0); cout.tie(0); }
int a[2000];
int main()
{
init();
int n; cin>>n;
for(int i=0; i<n; ++i) {
cin>>a[i];
}
sort(a, a+n);
int mn = 0;
for(int i=1; i<n; ++i) {
mn += (a[i] - a[i-1] -1);
}
cout<<mn<<Endl;
return 0;
}
|
227ae8284ae0bd02866c0b3df4d1b90761d41a78 | b02f819b1b5721df811dd7a29b2e4d8025635bd0 | /HW02TestDirectory9_9_2014/HW02TestDirectory/mydirectory/mack_hw02/MovingAverage.h | 85d10806d54c4ee0796abb4f7b7eff705bd7878e | [] | no_license | TheTattedcoder/Stock-Market-Excercise | cc24b3cb3d6042a0d15effeb9f7486ea409c8db8 | 22a79745a1b4ba1f34b028a82da3b06be5005276 | refs/heads/master | 2022-03-11T18:11:38.686581 | 2014-10-27T20:51:19 | 2014-10-27T20:51:19 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 816 | h | MovingAverage.h | /******************************************************************************
Homework 2 Main program
Author/copyright: Domonick Mack
Date last modified: 8 September 2014
This program calculates stocks , which are
100 values , reads them in averages 5 and 10
at a time. Compares the tolerance to see if
to sell or buy that item.
*****/
#ifndef MOVINGAVERAGE_H
#define MOVINGAVERAGE_H
#include <iostream>
#include <vector>
using namespace std;
#include "../../Utilities/Scanner.h"
#include "../../Utilities/ScanLine.h"
class MovingAverage
{
public:
MovingAverage();
virtual ~MovingAverage();
void doMovingAverage(int width, double tolerance);
void readData(string fileName);
string toStringTheData();
private:
vector<double> theData;
double computeAverage(int start, int width);
};
#endif
|
03f866c90df58fcc0b71bff468cd330ecfbe351d | 6b345953f84f5639403c31cd260c2af3981f4f95 | /cpp/src/matrix.cpp | 8645bfeb560bb6c7914ad9552ba2c163f06fead7 | [] | no_license | dcareymtn/distributed_computing | a4753165ef6bc12a1162cfdb6715d1fac618e8ec | 09df4e2bb98252b1de1db35d300e0ea85060a181 | refs/heads/master | 2020-03-28T18:18:41.001036 | 2018-12-03T04:43:56 | 2018-12-03T04:43:56 | 148,870,258 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 9,673 | cpp | matrix.cpp | #include <mpi.h>
#include <time.h>
#include <math.h>
#include "matrix.hpp"
using namespace std;
Matrix::Matrix( void )
{
}
Matrix::Matrix( const int rows, const int cols ) :
M(rows, vector<double> (cols, 0)),
rows(rows), cols(cols)
{
}
Matrix::Matrix( double *pBlockM, int nRowBreak, int nColBreak, int subMatNumRows, int subMatNumCols, int nFiltRows, int nFiltCols )
{
if ((nFiltRows % 2) != 1)
{
fprintf(stderr, "Error: Matrix::Matrix ... nFiltRows must be odd");
exit(0);
}
if ((nFiltCols % 2) != 1)
{
fprintf(stderr, "Error: Matrix ... n FiltCols must be odd");
}
this->rows = nRowBreak * (subMatNumRows - nFiltRows + 1);
this->cols = nColBreak * (subMatNumCols - nFiltRows + 1);
this->M = std::vector< std::vector< double > > ( this->rows, std::vector< double > (this->cols, 0));
int extraRowIdx = (nFiltRows - 1)/2;
int extraColIdx = (nFiltCols - 1)/2;
int blockSize = subMatNumRows * subMatNumCols;
int currRow, currCol;
for (int iRowBreak = 0; iRowBreak < nRowBreak; iRowBreak++)
{
for (int iColBreak = 0; iColBreak < nColBreak; iColBreak++)
{
for (int iSubRow = extraRowIdx; iSubRow < subMatNumRows - extraRowIdx; iSubRow++)
{
for (int iSubCol = extraColIdx; iSubCol < subMatNumCols - extraColIdx; iSubCol++)
{
currRow = iRowBreak*(subMatNumRows - nFiltRows + 1 ) + iSubRow - extraRowIdx;
currCol = iColBreak*(subMatNumCols - nFiltCols + 1 ) + iSubCol - extraColIdx;
this->M[currRow][currCol] = *(pBlockM + iRowBreak * blockSize * nColBreak + iColBreak*blockSize + iSubRow * subMatNumCols + iSubCol );
}
}
}
}
}
int Matrix::getRows( void ) const
{
return this->rows;
}
int Matrix::getCols( void ) const
{
return this->cols;
}
void Matrix::getParFiltBlockSize(int nRowBreak, int nColBreak, int nRowFilt, int nColFilt, int &blockSize, int &subMatNumRows, int &subMatNumCols ) const
{
if ((nRowFilt %2 != 1) || (nColFilt %2 != 1))
{
fprintf(stderr, "Filter Size must be odd");
}
if ((this->rows % 2) == 0)
{
subMatNumCols = this->cols/nColBreak + nColFilt - 1;
subMatNumRows = this->rows/nRowBreak + nRowFilt -1;
blockSize = subMatNumRows * subMatNumCols * nRowBreak * nColBreak;
}
else
{
fprintf(stderr, "Matrix Rows size most be 2^N");
exit(0);
}
}
void Matrix::write( FILE * os, bool bExtra ) const
{
if (bExtra)
{
fprintf(os, "nrows = %d\n", rows);
fprintf(os, "ncols = %d\n", cols);
}
if (os != NULL)
{
for (int iRow = 0; iRow < rows; iRow++ )
{
for (int iCol = 0; iCol < cols; iCol++ )
{
fprintf(os, "%5.1f ", M[iRow][iCol]);
}
fprintf(os, "\n");
}
fprintf(os, "\n");
}else
{
fprintf(stderr, "Error:matrix::write - not a valid file");
}
}
vector<double>& Matrix::operator[](int row)
{
return M[row];
}
vector<double> Matrix::operator[](int row) const
{
return M[row];
}
void Matrix::set_all_to_zeros( void )
{
for (int iRow = 0; iRow < this->rows; iRow++)
{
for (int iCol = 0; iCol < this->cols; iCol++)
{
this->M[iRow][iCol] = 0;
}
}
}
Matrix Matrix::getSubMatrix( int start_row, int stop_row, int start_col, int stop_col ) const
{
int nRow = stop_row - start_row + 1;
int nCol = stop_col - start_col + 1;
Matrix newMat( nRow, nCol );
for (int iRow = 0; iRow < nRow; iRow++)
{
for (int iCol = 0; iCol < nCol; iCol++)
{
newMat[iRow][iCol] = this->M[start_row + iRow][start_col + iCol];
}
}
return newMat;
}
Matrix Matrix::operator*( const double &val) const
{
Matrix new_mat(rows, cols);
for (int r = 0; r < rows; r++)
{
for (int c = 0; c < cols; c++)
{
new_mat[r][c] = M[r][c] * val;
}
}
return new_mat;
}
std::vector<std::vector<Matrix> > Matrix::parBreak( int nRowBreak ) const
{
std::vector<std::vector<Matrix> > Mpar(nRowBreak, std::vector<Matrix> (1));
if (this->rows%nRowBreak != 0)
{
fprintf(stderr, "%d is Not-divisible by %d\n", this->rows, nRowBreak);
exit(0);
}
int newRowSize = this->rows / nRowBreak;
for (int iPar = 0; iPar<nRowBreak; iPar++)
{
Mpar[iPar][0] = this->getSubMatrix( iPar*newRowSize, (iPar+1)*newRowSize-1, 0, this->cols);
}
return Mpar;
}
std::vector<std::vector< Matrix> > Matrix::parBreakZeroPadForFilt( int nRowBreak, int nColBreak, int filtNRows, int filtNCols ) const
{
std::vector<std::vector<Matrix> > Mpar( nRowBreak, std::vector<Matrix> (nColBreak) );
if (this->rows%nRowBreak != 0)
{
fprintf( stderr, "%d is Not divisible by %d\n", this->rows, nRowBreak);
exit(0);
}
int newRowSize = this->rows / nRowBreak;
int newColSize = this->cols / nColBreak;
int newRowSizeOverlap = newRowSize + filtNRows - 1;
int newColSizeOverlap = newColSize + filtNCols - 1;
Matrix newOverlap = Matrix( newRowSizeOverlap, newColSizeOverlap );
int start_row_idx, stop_row_idx;
int start_col_idx, stop_col_idx;
int this_row, this_col;
for (int iRowBreak = 0; iRowBreak < nRowBreak; iRowBreak++)
{
for (int iColBreak = 0; iColBreak < nColBreak; iColBreak++)
{
start_row_idx = iRowBreak*newRowSize - (filtNRows - 1)/2;
stop_row_idx = iRowBreak*newRowSize + newRowSize + (filtNRows - 1)/2;
start_col_idx = iColBreak*newColSize - (filtNCols - 1)/2;
stop_col_idx = iColBreak*newColSize + newColSize + (filtNCols - 1)/2;
for (int iNewRow = start_row_idx; iNewRow < stop_row_idx; iNewRow++)
{
for (int iNewCol = start_col_idx; iNewCol < stop_col_idx; iNewCol++)
{
this_row = iNewRow + (filtNRows-1)/2 - iRowBreak*newRowSize;
this_col = iNewCol + (filtNCols-1)/2 - iColBreak*newColSize;
if (iNewRow < 0 || iNewRow >= this->rows || iNewCol < 0 || iNewCol >= this->cols)
{
newOverlap[this_row][this_col] = 0;
}
else
{
newOverlap[this_row][this_col] = this->M[iNewRow][iNewCol];
}
}
}
Mpar[iRowBreak][iColBreak] = newOverlap;
}
}
return Mpar;
}
void Matrix::sendMPI( const int proc, const int tag, const MPI_Comm comm) const
{
for (int iRow = 0; iRow < rows; iRow++)
{
MPI_Send( &M[iRow][0], cols, MPI_DOUBLE, proc, tag, comm);
}
}
void Matrix::recvMPI( const int num_rows, const int num_cols, const int from_proc, const int tag, const MPI_Comm comm, MPI_Status *status)
{
rows = num_rows;
cols = num_cols;
M.resize( num_rows, std::vector<double>( num_cols, 0));
for (int iRow = 0; iRow < rows; iRow++)
{
MPI_Recv( &M[iRow][0], cols, MPI_DOUBLE, from_proc, tag, comm, status);
}
}
void Matrix::copy_to_cptr( double *newM )
{
for (int iRow = 0; iRow < rows; iRow++)
{
for (int iCol = 0; iCol < cols; iCol++)
{
*(newM + iRow * cols + iCol) = M[iRow][iCol];
}
}
}
void Matrix::copy_to_c_zero_padded_blocks( double *newMArray, int nRowBreak, int nColBreak, int filtNRows, int filtNCols ) const
{
std::vector<std::vector< Matrix > > MBlock = this->parBreakZeroPadForFilt( nRowBreak, nColBreak, filtNRows, filtNCols );
int fRows = MBlock[0][0].getRows();
int fCols = MBlock[0][0].getCols();
int fSize = fRows * fCols;
for (int iRowBreak = 0; iRowBreak < nRowBreak; iRowBreak++)
{
for (int iColBreak = 0; iColBreak < nColBreak; iColBreak++)
{
Matrix thisM = MBlock[iRowBreak][0];
for (int iRow = 0; iRow < fRows; iRow++)
{
for (int iCol = 0; iCol < fCols; iCol++)
{
*(newMArray + iRowBreak * fSize * nColBreak + iColBreak * fSize + iRow*fCols + iCol) = MBlock[iRowBreak][iColBreak][iRow][iCol];
}
}
}
}
}
Matrix Matrix::zeros( int rows, int cols )
{
return Matrix( rows, cols );
}
Matrix Matrix::eye( int n )
{
Matrix new_mat = Matrix( n, n );
for (int r = 0; r < n; r++)
{
new_mat[r][r] = 1.0;
}
return new_mat;
}
Matrix Matrix::randi( int rows, int cols, int low_int, int high_int )
{
Matrix new_mat = Matrix( rows, cols );
for (int r = 0; r < rows; r++)
{
for (int c = 0; c < cols; c++)
{
new_mat[r][c] = -1 +low_int + (rand() % (high_int - low_int + 1) + 1);
}
}
return new_mat;
}
Matrix Matrix::unifrand( int rows, int cols, double low, double high )
{
Matrix new_mat = Matrix( rows, cols );
srand(time(NULL));
for (int r = 0; r < rows; r++)
{
for (int c = 0; c < cols; c++)
{
new_mat[r][c] = ((double)rand()/(double)RAND_MAX) * (high - low) - (high-low)/2;
}
}
return new_mat;
}
Matrix Matrix::inf( int rows, int cols )
{
Matrix new_mat( rows, cols );
for (int r = 0; r < rows; r++)
{
for (int c = 0; c < cols; c++)
{
new_mat[r][c] = INFINITY;
}
}
return new_mat;
}
Matrix Matrix::stack( const Matrix & top, const Matrix & middle, const Matrix & bottom )
{
Matrix stackMat = Matrix( top.getRows() + middle.getRows() + bottom.getRows(),
top.getCols());
for (int iRow = 0; iRow < top.getRows(); iRow++)
{
for (int iCol = 0; iCol < top.getCols(); iCol++)
{
stackMat[iRow][iCol] = top[iRow][iCol];
}
}
for (int iRow = 0; iRow < middle.getRows(); iRow++)
{
for (int iCol = 0; iCol < middle.getCols(); iCol++)
{
stackMat[iRow+top.getRows()][iCol] = middle[iRow][iCol];
}
}
for (int iRow = 0; iRow < bottom.getRows(); iRow++)
{
for (int iCol = 0; iCol < bottom.getCols(); iCol++)
{
stackMat[iRow + top.getRows() + middle.getRows()][iCol] = bottom[iRow][iCol];
}
}
return stackMat;
}
|
01620dfe09414a636801a821b6ef421a9453fbee | 9d4053352198a8a662496eb7e18f9507a5b87968 | /src/misc/functionCallWithTooFewArgs.cpp | 82b735dac593e259c31dcb15dc57687aa3d26c17 | [
"MIT"
] | permissive | kkysen/SmartNeuralFuzzer | db8e16a11cfa2c3ec26e47e6e70864c28c7ab350 | 22088a3871e4104c4afc463c05ce58f0221dbc43 | refs/heads/master | 2020-04-20T21:35:58.011772 | 2019-07-29T16:44:12 | 2019-07-29T16:44:12 | 169,113,871 | 3 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 2,365 | cpp | functionCallWithTooFewArgs.cpp | //
// Created by Khyber on 7/24/2019.
//
#include <random>
#include <iostream>
using RR = int;
using R = void;
using F0 = R();
using F1 = R(int);
using F2 = R(int, int);
using F3 = R(int, int, int);
extern "C"
RR p(int x) {
std::cout << "p = " << x << std::endl;
return x;
}
extern "C"
RR f0() {
return p(-1);
}
extern "C"
RR f1(int a) {
return p(a);
}
extern "C"
RR f2(int a, int b) {
return p(a + b);
}
extern "C"
RR f3(int a, int b, int c) {
return p(a + b + c);
}
extern "C"
void* funcs[] = {
reinterpret_cast<void*>(f0),
reinterpret_cast<void*>(f1),
reinterpret_cast<void*>(f2),
reinterpret_cast<void*>(f3),
};
extern "C"
void g0(int i) {
const auto f = reinterpret_cast<F0*>(funcs[i]);
const auto x = (f(), 0);
std::cout << "x0 = " << x << std::endl;
}
extern "C"
void g1(int i) {
const auto f = reinterpret_cast<F1*>(funcs[i]);
const auto x = (f(100), 1);
std::cout << "x1 = " << x << std::endl;
}
extern "C"
void g2(int i) {
const auto f = reinterpret_cast<F2*>(funcs[i]);
const auto x = (f(-1, -2), 2);
std::cout << "x2 = " << x << std::endl;
}
extern "C"
void g3(int i) {
const auto f = reinterpret_cast<F3*>(funcs[i]);
const auto x = (f(1, 2, 3), 3);
std::cout << "x3 = " << x << std::endl;
}
/**
* Test if I can call a function with the wrong number of arguments and different return type.
*
* Result:
* If I call with too many args, everything seems fine.
* If I call with too few args, garbage values are in the args instead,
* but there's no segfault and if the args aren't actually used this should be fine.
* If I call with a larger return type, garbage values are used for the rest of the type.
* But if I call with a void return type (when it's not void),
* things sometimes get messed up (but nothing crashes).
*/
int main(int argc, char** argv) {
std::default_random_engine generator {std::random_device()()};
std::uniform_int_distribution<int> distribution(0, (sizeof(funcs) / sizeof(*funcs)) - 1);
const auto i = argc < 2
? distribution(generator)
: std::strtoull(argv[1], nullptr, 10) % (sizeof(funcs) / sizeof(*funcs));
std::cout << "i = " << i << std::endl;
g0(i);
g1(i);
g2(i);
g3(i);
return 0;
}
|
e4c7cd3e525207268b5b3c7a7c4eb5d4ef2e64c9 | ed16d61a41b4d5fa625eb9295fba01e2de08021e | /components/wic_cl_hook/src/ex_common/WICO_DebugView.cpp | 76da5a20e4d7a23dcb3b1d687ee6adb342e2c668 | [] | no_license | tenerefis/WIC-Client | 5904b910421d3e07cb12584f7c2f81abe8d5722f | 0fd61f9aaa7f4623bc13fa71d5b629879eeb99cb | refs/heads/master | 2021-08-27T20:32:51.185578 | 2021-08-05T13:23:08 | 2021-08-05T13:23:08 | 63,661,024 | 0 | 0 | null | 2016-07-19T04:38:51 | 2016-07-19T04:38:50 | null | UTF-8 | C++ | false | false | 4,841 | cpp | WICO_DebugView.cpp | #include "../stdafx.h"
void WICP_DebugView::InitializeHook()
{
Detours::X86::DetourFunctionClass(reinterpret_cast<uint8_t *>(0x00944A2E), &WICP_DebugView::Init, Detours::X86Option::USE_CALL);
}
bool WICP_DebugView::Init()
{
EX3D_Console::ourInstance->AddFunc("DebugToggle", Console_DebugScriptToggle, this, false, nullptr);
EX3D_Console::ourInstance->AddFunc("DebugToggleDevMenu", Console_DebugViewToggle, this, false, nullptr);
return ((bool(__stdcall *)(WICP_DebugView *))0x008FF040)(this);
}
void WICP_DebugView::SetCycleValue(int aValue)
{
myFlags[aValue]++;
if (myFlags[aValue] == myItems[aValue].myNumCycleStates)
myFlags[aValue] = 0;
if (myItems[aValue].myType == WICO_DebugView::DVT_CYCLE_BUTTON)
PropagateToGroup(static_cast<WICO_DebugView::DV_Flag>(aValue), true);
else
PropagateToGroup(static_cast<WICO_DebugView::DV_Flag>(aValue), myFlags[aValue] == 1);
}
void WICP_DebugView::SetToggleValue(int aValue)
{
if (myItems[aValue].myType == WICO_DebugView::DVT_TOGGLE_RADIO_BUTTON)
myFlags[aValue] = 1;
else
myFlags[aValue] = myFlags[aValue] != 1;
if (myItems[aValue].myAlias != WICO_DebugView::DVF_NUMTYPES)
{
int aliasValue = myItems[aValue].myAliasSetToValue;
if (aliasValue <= -1)
aliasValue = myFlags[aValue];
myFlags[myItems[aValue].myAlias] = aliasValue;
}
if (myItems[aValue].myType == WICO_DebugView::DVT_TOGGLE_GROUP_BUTTON)
PropagateToGroup(static_cast<WICO_DebugView::DV_Flag>(aValue), myFlags[aValue] == 1);
else if (myItems[aValue].myType == WICO_DebugView::DVT_TOGGLE_RADIO_BUTTON)
PropagateToRadioGroup(static_cast<WICO_DebugView::DV_Flag>(aValue), myFlags[aValue] == 1);
}
void WICP_DebugView::PropagateToGroup(WICO_DebugView::DV_Flag aFlag, const bool aEnableFlag)
{
((void(__thiscall *)(WICP_DebugView *, WICO_DebugView::DV_Flag, const bool))0x008FEC00)(this, aFlag, aEnableFlag);
}
void WICP_DebugView::PropagateToRadioGroup(WICO_DebugView::DV_Flag aFlag, const bool aEnableFlag)
{
((void(__thiscall *)(WICP_DebugView *, WICO_DebugView::DV_Flag, const bool))0x008FE9F0)(this, aFlag, aEnableFlag);
}
int WICP_DebugView::GetTypeForString(const char *aString)
{
static const char *flagNames[] =
{
"DVF_EFFECTS",
"DVF_GAME_GROUP",
"DVF_GAME_INFO",
"DVF_GAME_UNITS",
"DVF_GAME_PROJECTILES",
"DVF_GAME_CLOUDS",
"DVF_GAME_BUILDINGS",
"DVF_GAME_PROPS",
"DVF_GAME_COMMANDPOINTS",
"DVF_GAME_DESTRUCTIBLE",
"DVF_PLAYER_INFO",
"DVF_RELATIONS",
"DVF_TRIGGERS",
"DVF_LOS_CHEAT",
"DVF_PLAYER_GROUP",
"DVF_PLAYER_STATS",
"DVF_PLAYER_UNIT",
"DVF_PLAYER_UNIT_DAMAGE",
"DVF_PLAYER_UNIT_VISUAL_REP",
"DVF_PLAYER_UNIT_PHYSIC_REP",
"DVF_PLAYER_UNIT_CROUCHING",
"DVF_PLAYER_BUILDINGS",
"DVF_PLAYER_BUILDINGS_MORE",
"DVF_PLAYER_WORLD",
"DVF_PLAYER_CIVILIANS",
"DVF_PLAYER_FENCES",
"DVF_PLAYER_PROPS",
"DVF_PLAYER_SOUND",
"DVF_PLAYER_SOUND_USAGE",
"DVF_PLAYER_FEEDBACK_STRESS",
"DVF_MAPDATA_GROUP",
"DVF_MAPDATA_MAP_MODE",
"DVF_GAME_GROUP_TOGGLE",
"DVF_PLAYER_GROUP_TOGGLE",
"DVF_ART_MAIN",
"DVF_ART_PATHFINDING",
"DVF_ART_PATHFINDING_NONE",
"DVF_ART_PATHFINDING_TANKS",
"DVF_ART_PATHFINDING_INFANTRY",
"DVF_ART_PATHFINDING_HELICOPTERS",
"DVF_ART_PATHFINDING_VEHICLES",
"DVF_ART_MRB_DIRECTORY_PATH",
"DVF_ART_MRB_DIRECTORY_PATH_HOUSE",
"DVF_ART_MRB_DIRECTORY_PATH_PROPS",
"DVF_ART_UNITS",
"DVF_ART_UNITS_PHYSICAL_REP",
"DVF_ART_UNITS_VISUAL_REP",
"DVF_ART_HOUSE",
"DVF_ART_HOUSE_SLOT_INFO",
"DVF_ART_HOUSE_SLOT_INFO_POSITIONS",
"DVF_ART_HOUSE_SLOT_INFO_DOORS",
"DVF_ART_HOUSE_SLOT_INFO_DIRECTIONS",
"DVF_ART_HOUSE_BOUNDING_BOX",
"DVF_ART_PHYS_BOXES",
"DVF_ART_PHYS_BOXES_HOUSE",
"DVF_ART_PHYS_BOXES_PROPS",
"DVF_ART_PHYS_BOXES_UNITS",
"DVF_NUMTYPES",
};
for (size_t i = 0; i < std::size(flagNames); i++)
{
if (!strcmp(flagNames[i], aString))
return i;
}
return WICO_DebugView::DVF_NUMTYPES;
}
bool WICP_DebugView::Console_DebugScriptToggle(char *aString, void *aUserData)
{
char menuType[255];
auto debugView = reinterpret_cast<WICP_DebugView *>(aUserData);
if (sscanf_s(aString, "%s", menuType, 255) == 1)
{
int type = GetTypeForString(menuType);
if (type == WICO_DebugView::DVF_NUMTYPES)
{
strcpy(aString, "Unknown command");
}
else
{
if (debugView->myItems[type].myType == WICO_DebugView::DVT_CYCLE_BUTTON)
debugView->SetCycleValue(type);
else
debugView->SetToggleValue(type);
//profile->SetDebugViewFlags(debugView->myFlags);
debugView->myIsActiveFlag = true;
debugView->myIsMenuActiveFlag = false;
}
}
else
{
strcpy(aString, "Bad command");
}
return true;
}
bool WICP_DebugView::Console_DebugViewToggle(char *aString, void *aUserData)
{
auto debugView = reinterpret_cast<WICP_DebugView *>(aUserData);
debugView->myIsActiveFlag = true;
debugView->myIsMenuActiveFlag = true;
return true;
} |
2fbd241723222be2416be68cd55caad5f679de4b | 5776421ad0e764f1121a27a26e7de6a822e6aee9 | /src/extern.hpp | e363a36ca85a633a5427ffe2c31d081d10f10edc | [
"CC-BY-4.0",
"LicenseRef-scancode-unknown-license-reference"
] | permissive | eXpl0it3r/Schiffbruch | ee950dbd842a48f8d507bd5ae8cb84aaee933500 | 0463938c151cfc8ba1a861847d2aac00b4764bbf | refs/heads/master | 2022-11-03T16:44:51.339572 | 2022-07-02T23:52:40 | 2022-10-18T06:57:25 | 29,222,558 | 69 | 13 | NOASSERTION | 2022-10-20T22:13:18 | 2015-01-14T02:12:10 | C++ | UTF-8 | C++ | false | false | 4,296 | hpp | extern.hpp | #pragma once
#include "headers.hpp"
#include "types.hpp"
#include <SFML/Audio.hpp>
#include <vector>
extern int Spielzustand; // in welchem Zustand ist das Spiel?
extern bool LAnimation; // Ist die Landschaftanimation angeschaltet?
extern bool Gitter; // Gitternetz an/aus
extern RECT ScapeGrenze; // Diese Koordinaten zeigen die Größe der Landschaft an
extern short CursorTyp; // Welcher Cursortyp?
extern short RouteLaenge; // Länge
extern short RoutePunkt; // Aktueller Index in RouteKoor
extern short Bild, LastBild; // Anzahl der Bilder in der Sekunde
extern RECT rcRectdes, rcRectsrc; // Ständig benötigte Variable zum Blitten
extern short Tag, Stunden, Minuten; // Wieviel Uhr (0-12h)
extern char StdString[1024]; // Standard string
extern char RohString[1024]; // Darin wird gespeichert, wieviel Rohstoffe noch benötigt werden
extern short PapierText; // Wieviel Papier? (in Pixel) -1 = Kein Text
extern short HauptMenue; // Welches Menü?
extern short TwoClicks; // Für Aktionen mit zwei Mausklicks
extern float Chance; // Wie groß ist die Chance am Tag gerettet zu werden
extern bool BootsFahrt; // Gerade mit dem Boot unterwegs?
extern bool Nacht; // Wird die Tageszusammenfassung angezeigt?
extern short Soundzustand; // -1 = keine Soundkarte;0=kein Sound;1=Sound an
extern short Frage; // -1=KeineFrage;0=Frage wird gestellt;1=Ja;2=Nein
extern short AbspannNr; // Zähler für Abspann
extern short AbspannZustand; // Wo im Abspann
extern bool SchatzGef; // wurde der Schatz gefunden
extern short Step, Steps;
// Should be const
extern RECT rcGesamt;
extern RECT rcSpielflaeche;
extern RECT rcPanel;
extern RECT rcKarte;
extern ZWEID EckKoor[13][4];
extern TEXTBEREICH TextBereich[TEXTANZ];
extern ZWEID Camera, // aktueller Kartenausschnitt
MousePosition, // " Mauskoordinaten
RouteZiel, RouteStart, // Koordinaten des Starts und des Endes der Route
Route[MAXXKACH * MAXYKACH], // Liste der Routenpunkte
RouteKoor[2 * MAXXKACH * MAXYKACH], // Liste der Routenkoordinaten
SchatzPos; // Hier ist der Schatz vergraben
extern RGBSTRUCT rgbStruct; // Hier werden die Farben eines Pixels zwischengespeichert
extern GUY Guy;
extern BMP Bmp[BILDANZ];
extern WAV Wav[25]; // Sound::COUNT;
extern ABSPANN AbspannListe[10][10]; // Namenabfolge im Abspann
extern SCAPE Scape[MAXXKACH][MAXYKACH];
// DirectDraw
extern LPDIRECTDRAWSURFACE4 lpDDSPrimary; // DirectDraw primary surface
extern LPDIRECTDRAWSURFACE4 lpDDSBack; // DirectDraw back surface
extern LPDIRECTDRAWSURFACE4 lpDDSMisc; // DirectDraw Bilder surface
extern LPDIRECTDRAWSURFACE4 lpDDSPanel; // DirectDraw Panel surface
extern LPDIRECTDRAWSURFACE4 lpDDSGuyAni; // DirectDraw GuyAni surface
extern LPDIRECTDRAWSURFACE4 lpDDSAnimation; // DirectDraw Animation surface
extern LPDIRECTDRAWSURFACE4 lpDDSKarte; // DirectDraw MiniMap surface
extern LPDIRECTDRAWSURFACE4 lpDDSSchrift; // DirectDraw Schrift surface
extern LPDIRECTDRAWSURFACE4 lpDDSSchrift1; // DirectDraw Schrift1 surface
extern LPDIRECTDRAWSURFACE4 lpDDSSchrift2; // DirectDraw Schrift2 surface
extern LPDIRECTDRAWSURFACE4 lpDDSTextFeld; // DirectDraw TextFeld surface
extern LPDIRECTDRAWSURFACE4 lpDDSPapier; // DirectDraw Paier surface
extern LPDIRECTDRAWSURFACE4 lpDDSBaum; // DirectDraw Bäume surface
extern LPDIRECTDRAWSURFACE4 lpDDSBau; // DirectDraw Bauwerke surface
extern LPDIRECTDRAWSURFACE4 lpDDSCredits; // DirectDraw Credits surface
extern LPDIRECTDRAWSURFACE4 lpDDSLogo; // DirectDraw Logo surface
extern LPDIRECTDRAWSURFACE4 lpDDSCursor; // DirectDraw Cursor surface
extern LPDIRECTDRAWSURFACE4 lpDDSButtons; // DirectDraw Buttons surface
extern LPDIRECTDRAWSURFACE4 lpDDSInventar; // DirectDraw Inventar surface
extern LPDIRECTDRAWSURFACE4 lpDDSScape; // DirectDraw Landschaft surface
extern LPDIRECTDRAWSURFACE4 lpDDSSchatzkarte; // SchatzkartenSurface
extern LPDIRECTDRAWPALETTE lpDDPal; // DirectDraw palette
extern DDBLTFX ddbltfx; // DirectDraw Effekte
extern DDPIXELFORMAT ddpf;
extern DDSURFACEDESC2 ddsd, ddsd2; // Zwischenspeicher der SurfaceEigenschaften
extern LPDIRECTDRAWGAMMACONTROL lpDDGammaControl; // Die drei sind für das Gammaablenden
extern DDGAMMARAMP DDGammaRamp;
extern DDGAMMARAMP DDGammaOld;
// Directinput
extern HINSTANCE g_hInst;
|
9b540f990784ef8686c411250e54319a5a1701e8 | 44890f9b95a8c77492bf38514d26c0da51d2fae5 | /Gif/MotionFont/drawing.h | 2414bf1841ff938cc8d41cf1517e59b564c42227 | [] | no_license | winnison/huang-cpp | fd9cd57bd0b97870ae1ca6427d2fc8191cf58a77 | 989fe1d3fdc1c9eae33e0f11fcd6d790e866e4c5 | refs/heads/master | 2021-01-19T18:07:38.882211 | 2008-04-14T16:42:48 | 2008-04-14T16:42:48 | 34,250,385 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 746 | h | drawing.h | #include "define.h"
#include <string>
using namespace std;
void HSBtoRGB(float hue, float saturation, float brightness, int& r, int& g, int& b);
void RGBtoHSB(int r, int g, int b, float& hue, float& saturation, float& brightness);
COLORREF GetRGBbyHSB(float hue, float saturation, float brightness);
void GetHSBbyRGB(COLORREF rgb, float& hue, float& saturation, float& brightness);
void GrayAdjust(HBITMAP hBitmap);
HBITMAP StretchBitmap(HBITMAP hbmpSrc,int cxDst,int cyDst);
HBITMAP Transform( HBITMAP hBitmap , float matrix[3][3]);
void DrawTextOuter(CDC& dc, string& text, CSize& size, int x, int y, COLORREF outer);
void DrawTextWithOuter(CDC& dc, string& text, CSize& size, int x, int y, COLORREF clr, COLORREF outer);
|
b3b179ca338f0ebf0082d6b45a0da4fe8af0b1de | 38616fa53a78f61d866ad4f2d3251ef471366229 | /3rdparty/GPSTk/ext/lib/Procframe/EquationSystem.hpp | 1df040ebe7502b6548da214ab1f1d861842b383f | [
"GPL-3.0-only",
"LGPL-2.0-or-later",
"LGPL-3.0-only",
"LGPL-2.1-or-later",
"GPL-1.0-or-later",
"MIT"
] | permissive | wuyou33/Enabling-Robust-State-Estimation-through-Measurement-Error-Covariance-Adaptation | 3b467fa6d3f34cabbd5ee59596ac1950aabf2522 | 2f1ff054b7c5059da80bb3b2f80c05861a02cc36 | refs/heads/master | 2020-06-08T12:42:31.977541 | 2019-06-10T15:04:33 | 2019-06-10T15:04:33 | 193,229,646 | 1 | 0 | MIT | 2019-06-22T12:07:29 | 2019-06-22T12:07:29 | null | UTF-8 | C++ | false | false | 16,292 | hpp | EquationSystem.hpp | //============================================================================
//
// This file is part of GPSTk, the GPS Toolkit.
//
// The GPSTk is free software; you can redistribute it and/or modify
// it under the terms of the GNU Lesser General Public License as published
// by the Free Software Foundation; either version 3.0 of the License, or
// any later version.
//
// The GPSTk is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Lesser General Public License for more details.
//
// You should have received a copy of the GNU Lesser General Public
// License along with GPSTk; if not, write to the Free Software Foundation,
// Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110, USA
//
// Copyright 2004, The University of Texas at Austin
// Dagoberto Salazar - gAGE ( http://www.gage.es ). 2009
//
//============================================================================
//============================================================================
//
//This software developed by Applied Research Laboratories at the University of
//Texas at Austin, under contract to an agency or agencies within the U.S.
//Department of Defense. The U.S. Government retains all rights to use,
//duplicate, distribute, disclose, or release this software.
//
//Pursuant to DoD Directive 523024
//
// DISTRIBUTION STATEMENT A: This software has been approved for public
// release, distribution is unlimited.
//
//=============================================================================
/**
* @file EquationSystem.hpp
* Class to define and handle complex equation systems for solvers.
*/
#ifndef GPSTK_EQUATIONSYSTEM_HPP
#define GPSTK_EQUATIONSYSTEM_HPP
#include <algorithm>
#include "DataStructures.hpp"
#include "StochasticModel.hpp"
#include "Equation.hpp"
#include "ConstraintSystem.hpp"
namespace gpstk
{
/// Thrown when attempting to use an invalid EquationSystem
/// @ingroup exceptiongroup
NEW_EXCEPTION_CLASS(InvalidEquationSystem, gpstk::Exception);
/// @ingroup DataStructures
//@{
/** This class defines and handles complex equation systems for solvers,
* generating the Vectors and Matrices they will need, including:
*
* \li Measurements Vector (prefit residuals).
* \li Geometry matrix.
* \li Equation weights matrix.
* \li State Transition Matrix (PhiMatrix).
* \li Process noise covariance matrix (QMatrix).
*
* In addition, this class will provide important/interesting information
* such as number of variables, satellites and data sources being
* processed.
*
* In order to achieve this, the 'EquationSystem' class will start from a
* list of 'Equation descriptions' and the currently available GNSS data.
* From there, it will deduce the unknowns corresponding to each data
* source as well as the specific equations.
*
* A typical way to use this class follows, showing how to set up an
* object to perform "Precise Point Positioning" (PPP):
*
* @code
*
* // DEFINE VARIABLES
*
* // Declare stochastic models to be used
* StochasticModel coordinatesModel;
* TropoRandomWalkModel tropoModel;
* PhaseAmbiguityModel ambiModel;
*
* // These variables are, by default, SourceID-indexed
* Variable dx( TypeID::dx, &coordinatesModel, true, false, 100.0 );
*
* Variable dy( TypeID::dy, &coordinatesModel );
* dy.setInitialVariance( 100.0 ); // Equivalent to 'dx' setup
*
* Variable dz( TypeID::dz, &coordinatesModel );
* dz.setInitialVariance( 100.0 );
*
* Variable cdt( TypeID::cdt );
* cdt.setDefaultForced(true); // Force default coefficient (1.0)
*
* Variable tropo( TypeID::wetMap, &tropoModel );
* tropo.setInitialVariance( 25.0 );
*
*
* // The following variable is, SourceID and SatID-indexed
* Variable ambi( TypeID::BLC, &ambiModel, true, true );
* ambi.setDefaultForced(true); // Force default coefficient (1.0)
*
* // This will be the independent term for code equation
* Variable prefitC( TypeID::prefitC );
*
* // This will be the independent term for phase equation
* Variable prefitL( TypeID::prefitL );
*
*
* // DESCRIBE EQUATIONS
*
* // Define Equation object for code equations, and add variables
* Equation equPC( prefitC );
*
* equPC.addVariable(dx);
* equPC.addVariable(dy);
* equPC.addVariable(dz);
* equPC.addVariable(cdt);
* equPC.addVariable(tropo);
*
* // Define Equation object for phase equations, and add variables
* Equation equLC( prefitL );
*
* equLC.addVariable(dx);
* equLC.addVariable(dy);
* equLC.addVariable(dz);
* equLC.addVariable(cdt);
* equLC.addVariable(tropo);
* equLC.addVariable(ambi); // This variable is for phase only
*
* // Phase equations should have higher relative weight
* equLC.setWeight(10000.0); // 100.0 * 100.0
*
*
* // SETUP EQUATION SYSTEM
*
* // Create 'EquationSystem' object
* EquationSystem eqSystem;
*
* // Add equation descriptions
* eqSystem.addEquation(equPC);
* eqSystem.addEquation(equLC);
*
* @endcode
*
* In this way, rather complex processing strategies may be set up in a
* handy and flexible way.
*
* \warning Please be aware that this class requires a significant amount
* of overhead. Therefore, if your priority is execution speed you should
* either use the already provided 'purpose-specific' solvers (like
* 'SolverPPP' or hand-code your own class. For new processing strategies
* you should balance the importance of machine time (extra overhead)
* versus researcher time (writing a new solver).
*
* @sa Variable.hpp, Equation.hpp.
*
*/
class EquationSystem
{
public:
/// Default constructor
EquationSystem()
: isPrepared(false)
{};
/** Add a new equation to be managed.
*
* @param equation Equation object to be added.
*/
virtual EquationSystem& addEquation( const Equation& equation );
/** Remove an Equation being managed. In this case the equation is
* identified by its independent term.
*
* @param indterm Variable object of the equation independent term
* (measurement type).
*
* \warning All Equations with the same independent term will be
* erased.
*/
virtual EquationSystem& removeEquation( const Variable& indterm );
/// Remove all Equation objects from this EquationSystem.
virtual EquationSystem& clearEquations();
/** Prepare this object to carry out its work.
*
* @param gData GNSS data structure (GDS).
*
*/
virtual EquationSystem& Prepare( gnssSatTypeValue& gData )
{ gnssRinex gds(gData); return ( Prepare(gds) ); };
/** Prepare this object to carry out its work.
*
* @param gData GNSS data structure (GDS).
*
*/
virtual EquationSystem& Prepare( gnssRinex& gData );
/** Prepare this object to carry out its work.
*
* @param gdsMap Map of GNSS data structures (GDS), indexed
* by SourceID.
*
*/
virtual EquationSystem& Prepare( gnssDataMap& gdsMap );
/** Return the TOTAL number of variables being processed.
*
* \warning You must call method Prepare() first, otherwise this
* method will throw an InvalidEquationSystem exception.
*/
virtual int getTotalNumVariables() const
throw(InvalidEquationSystem);
/** Return the set containing all variables being processed.
*
* \warning You must call method Prepare() first, otherwise this
* method will throw an InvalidEquationSystem exception.
*/
virtual VariableSet getVarUnknowns() const
throw(InvalidEquationSystem);
/** Return the CURRENT number of variables, given the current equation
* system definition and the GDS's involved.
*
* \warning You must call method Prepare() first, otherwise this
* method will throw an InvalidEquationSystem exception.
*/
virtual int getCurrentNumVariables() const
throw(InvalidEquationSystem);
/** Return the set containing variables being currently processed.
*
* \warning You must call method Prepare() first, otherwise this
* method will throw an InvalidEquationSystem exception.
*/
virtual VariableSet getCurrentUnknowns() const
throw(InvalidEquationSystem);
/** Return the CURRENT number of sources, given the current equation
* system definition and the GDS's involved.
*
* \warning You must call method Prepare() first, otherwise this
* method will throw an InvalidEquationSystem exception.
*/
virtual int getCurrentNumSources() const
throw(InvalidEquationSystem);
/** Return the set containing sources being currently processed.
*
* \warning You must call method Prepare() first, otherwise this
* method will throw an InvalidEquationSystem exception.
*/
virtual SourceIDSet getCurrentSources() const
throw(InvalidEquationSystem);
/** Return the CURRENT number of satellites, given the current equation
* system definition and the GDS's involved.
*
* \warning You must call method Prepare() first, otherwise this
* method will throw an InvalidEquationSystem exception.
*/
virtual int getCurrentNumSats() const
throw(InvalidEquationSystem);
/** Return the set containing satellites being currently processed.
*
* \warning You must call method Prepare() first, otherwise this
* method will throw an InvalidEquationSystem exception.
*/
virtual SatIDSet getCurrentSats() const
throw(InvalidEquationSystem);
/** Get prefit residuals GPSTk Vector, given the current equation
* system definition and the GDS' involved.
*
* \warning You must call method Prepare() first, otherwise this
* method will throw an InvalidEquationSystem exception.
*/
virtual Vector<double> getPrefitsVector() const
throw(InvalidEquationSystem);
/** Get geometry matrix, given the current equation system definition
* and the GDS' involved.
*
* \warning You must call method Prepare() first, otherwise this
* method will throw an InvalidEquationSystem exception.
*/
virtual Matrix<double> getGeometryMatrix() const
throw(InvalidEquationSystem);
/** Get weights matrix, given the current equation system definition
* and the GDS' involved.
*
* \warning You must call method Prepare() first, otherwise this
* method will throw an InvalidEquationSystem exception.
*/
virtual Matrix<double> getWeightsMatrix() const
throw(InvalidEquationSystem);
/** Get the State Transition Matrix (PhiMatrix), given the current
* equation system definition and the GDS' involved.
*
* \warning You must call method Prepare() first, otherwise this
* method will throw an InvalidEquationSystem exception.
*/
virtual Matrix<double> getPhiMatrix() const
throw(InvalidEquationSystem);
/** Get the Process Noise Covariance Matrix (QMatrix), given the
* current equation system definition and the GDS' involved.
*
* \warning You must call method Prepare() first, otherwise this
* method will throw an InvalidEquationSystem exception.
*/
virtual Matrix<double> getQMatrix() const
throw(InvalidEquationSystem);
/// Get the number of equation descriptions being currently processed.
virtual int getEquationDefinitionNumber() const
{ return equationDescriptionList.size(); };
/// Get the list of current equations.
virtual std::list<Equation> getCurrentEquationsList() const
{ return currentEquationsList; };
/// Get a copy of the constraint system.
virtual ConstraintSystem getConstraintSystem() const
{ return equationConstraints; };
/** Set the constraint system.
*
* @param equationConst Object of ConstraintSystem
*/
virtual EquationSystem& setConstraintSystem(
const ConstraintSystem& equationConst )
{ equationConstraints = equationConst; return (*this); };
/// Remove all constraints from the equation system.
virtual EquationSystem& clearConstraintSystem()
{ equationConstraints.clearConstraint(); return (*this); };
/// Destructor
virtual ~EquationSystem() {};
private:
/// Object holding constraints equations
ConstraintSystem equationConstraints;
/// List containing the DESCRIPTIONS of Equation objects.
std::list<Equation> equationDescriptionList;
/// List of current equations
std::list<Equation> currentEquationsList;
/// Global set of unknowns
VariableSet varUnknowns;
/// Current set of unknowns
VariableSet currentUnknowns;
/// Old set of unknowns
VariableSet oldUnknowns;
/// List of all unknowns(std::list is used to keep order)
std::list<Variable> allUnknowns;
/// Set of reject unknowns
VariableSet rejectUnknowns;
/// Whether or not this EquationSystem is ready to be used
bool isPrepared;
/// Set containing all sources being currently processed
SourceIDSet currentSourceSet;
/// Set containing satellites being currently processed
SatIDSet currentSatSet;
/// State Transition Matrix (PhiMatrix)
Matrix<double> phiMatrix;
/// Process noise covariance matrix (QMatrix)
Matrix<double> qMatrix;
/// Geometry matrix
Matrix<double> hMatrix;
/// Weights matrix
Matrix<double> rMatrix;
/// Measurements vector (Prefit-residuals)
Vector<double> measVector;
/// Get current sources (SourceID's) and satellites (SatID's)
void prepareCurrentSourceSat( gnssDataMap& gdsMap );
/// Prepare set of current unknowns and list of current equations
VariableSet prepareCurrentUnknownsAndEquations( gnssDataMap& gdsMap );
/// Compute phiMatrix and qMatrix
void getPhiQ( const gnssDataMap& gdsMap );
/// Compute prefit residuals vector
void getPrefit( gnssDataMap& gdsMap );
/// Compute hMatrix and rMatrix
void getGeometryWeights( gnssDataMap& gdsMap );
/// Impose the constraints system to the equation system
/// the prefit residuals vector, hMatrix and rMatrix will be appended.
void imposeConstraints();
/// General white noise stochastic model
static WhiteNoiseModel whiteNoiseModel;
}; // End of class 'EquationSystem'
//@}
} // End of namespace gpstk
#endif // GPSTK_EQUATIONSYSTEM_HPP
|
95f5531e9047a92ff8130e1fa5614a914496cb5c | 263fd0f66c29df9ea9301ecf70c5ba7d91a31e01 | /Project-NN/entity/MenuItem.h | b554d604e345b6e850b16c8de432e159a24a1b1d | [] | no_license | Daminvar/Project-NN | d90a0e1478cf5364fdc92dd895e9e9582908cd33 | 95a92a0627d646dfdbccc89205e3fc639805ff3d | refs/heads/master | 2021-01-18T19:12:02.881171 | 2013-05-16T23:22:17 | 2013-05-16T23:22:17 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 984 | h | MenuItem.h | #pragma once
#include <iostream>
#include "GameObject.h"
#include "StateManager.h"
class Transform;
class UIDrawable;
class MenuComponent;
enum MENU_ITEM_STYLE {
MENU_STATIC = 0,
MENU_BUTTON = 1
};
struct UIElementBuffer {
float width;
float height;
XMFLOAT2 position;
};
// this describes menu items
struct UIElementDescription
{
float width;
float height;
XMFLOAT2 position;
char* texture;
MENU_ITEM_STYLE style;
int (*function)( StateManager* manager );
};
class MenuItem : public GameObject {
public:
MenuItem( StateManager* _manager, UIElementDescription description );
~MenuItem( );
void Draw( );
void Trigger( );
float GetWidth( ) { return this->description.width; };
float GetHeight( ) { return this->description.height; };
XMFLOAT2 GetPosition( ) { return this->description.position; }
private:
Transform* transform;
MenuComponent* control;
UIDrawable* drawable;
StateManager* manager;
UIElementDescription description;
bool triggered;
}; |
166a04b85fe69619ebd45a716487064b6d6b2a9d | 9a69dc0135bf6ce567343d6b0adaf791c3efc1fd | /main.cpp | c9e6de32b8fc544b999b8a09063d269e93783456 | [] | no_license | cybern0id/SidBerry | 2ce24bbd92d5bf6877f10a7c5d6c01acedb65121 | 46d5d84ec172f3b1523462d3a768b6af4a1f8bc4 | refs/heads/master | 2021-05-29T02:49:23.322789 | 2015-07-04T14:15:23 | 2015-07-04T14:15:23 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 7,618 | cpp | main.cpp | //============================================================================
// Description : SidBerry player & driver
// Author : Gianluca Ghettini
//============================================================================
#include <iostream>
using namespace std;
#include <stdlib.h>
#include "mos6502.h"
#include "SidFile.h"
#include <wiringPi.h>
#include <sys/time.h>
uint8_t memory[65535]; // 64K ram
static uint8_t kk = 0;
static FILE* tty;
void TestWrite(uint16_t addr, uint8_t byte)
{
printf("\na: %02X, b: %02X", addr, byte);
uint16_t phyaddr = addr;
// set address to the bus
if(phyaddr & 0x01) digitalWrite(8, HIGH);
else digitalWrite(8, LOW);
if(phyaddr & 0x02) digitalWrite(9, HIGH);
else digitalWrite(9, LOW);
if(phyaddr & 0x04) digitalWrite(7, HIGH);
else digitalWrite(7, LOW);
if(phyaddr & 0x08) digitalWrite(0, HIGH);
else digitalWrite(0, LOW);
if(phyaddr & 0x10) digitalWrite(2, HIGH);
else digitalWrite(2, LOW);
// set data to the bus
if(byte & 0x01) digitalWrite(15, HIGH);
else digitalWrite(15, LOW);
if(byte & 0x02) digitalWrite(16, HIGH);
else digitalWrite(16, LOW);
if(byte & 0x04) digitalWrite(1, HIGH);
else digitalWrite(1, LOW);
if(byte & 0x08) digitalWrite(4, HIGH);
else digitalWrite(4, LOW);
if(byte & 0x10) digitalWrite(5, HIGH);
else digitalWrite(5, LOW);
if(byte & 0x20) digitalWrite(6, HIGH);
else digitalWrite(6, LOW);
if(byte & 0x40) digitalWrite(10, HIGH);
else digitalWrite(10, LOW);
if(byte & 0x80) digitalWrite(11, HIGH);
else digitalWrite(11, LOW);
// assert cs line
digitalWrite(3, LOW);
usleep(10);
digitalWrite(3, HIGH);
printf("\nOK\n");
return;
}
void MemWrite(uint16_t addr, uint8_t byte)
{
if(addr >= 0xD400 && addr <= 0xD7FF) // address decoding login
{
// access to SID chip
memory[addr] = byte;
if(!((kk++)&3))
{
printf("\n");
printf("%02X%02X ", memory[0xD400], memory[0xD401]);
printf("%02X%02X ", memory[0xD402], memory[0xD403]);
printf("%02X %02X %02X ", memory[0xD404], memory[0xD405], memory[0xD406]);
printf("%02X%02X ", memory[0xD407], memory[0xD408]);
printf("%02X%02X ", memory[0xD409], memory[0xD40A]);
printf("%02X %02X %02X ", memory[0xD40B], memory[0xD40C], memory[0xD40D]);
printf("%02X%02X ", memory[0xD40E], memory[0xD40F]);
printf("%02X%02X ", memory[0xD410], memory[0xD411]);
printf("%02X %02X %02X ", memory[0xD412], memory[0xD413], memory[0xD414]);
fflush(stdout);
}
uint16_t phyaddr = addr & 0x1f;
// set address to the bus
if(phyaddr & 0x01) digitalWrite(8, HIGH);
else digitalWrite(8, LOW);
if(phyaddr & 0x02) digitalWrite(9, HIGH);
else digitalWrite(9, LOW);
if(phyaddr & 0x04) digitalWrite(7, HIGH);
else digitalWrite(7, LOW);
if(phyaddr & 0x08) digitalWrite(0, HIGH);
else digitalWrite(0, LOW);
if(phyaddr & 0x10) digitalWrite(2, HIGH);
else digitalWrite(2, LOW);
// set data to the bus
if(byte & 0x01) digitalWrite(15, HIGH);
else digitalWrite(15, LOW);
if(byte & 0x02) digitalWrite(16, HIGH);
else digitalWrite(16, LOW);
if(byte & 0x04) digitalWrite(1, HIGH);
else digitalWrite(1, LOW);
if(byte & 0x08) digitalWrite(4, HIGH);
else digitalWrite(4, LOW);
if(byte & 0x10) digitalWrite(5, HIGH);
else digitalWrite(5, LOW);
if(byte & 0x20) digitalWrite(6, HIGH);
else digitalWrite(6, LOW);
if(byte & 0x40) digitalWrite(10, HIGH);
else digitalWrite(10, LOW);
if(byte & 0x80) digitalWrite(11, HIGH);
else digitalWrite(11, LOW);
// assert CS line (strobe)
digitalWrite(3, LOW);
usleep(1);
digitalWrite(3, HIGH);
}
else
{
// access to memory
memory[addr] = byte;
}
return;
}
uint8_t MemRead(uint16_t addr)
{
if(addr >= 0xD400 && addr <=0xD7FF) // address decoding logic
{
// access to SID chip
if((addr & 0x00FF) == 0x001B)
{
// emulate read access to OSC3/Random register, returna a random value
printf("\mread! 1b");
return rand();
}
if((addr & 0x00FF) == 0x001C)
{
// emulate access to envelope ENV3 register, return a random value
printf("\nread! 1c");
return rand();
}
}
return memory[addr];
}
void TestLoop()
{
int addr;
int byte;
printf("\n\n");
while(1)
{
printf("\naddr:");
scanf("%d", &addr);
printf("\nbyte:");
scanf("%d", &byte);
TestWrite(addr, byte);
}
}
int main(int argc, char *argv[])
{
SidFile sid;
int res = sid.Parse(argv[1]);
if(res == SIDFILE_ERROR_FILENOTFOUND)
{
cout << endl << "error loading sid file! not found";
return 0;
}
if(res == SIDFILE_ERROR_MALFORMED)
{
cout << endl << "error loading sid file! malformed";
return 0;
}
cout << endl << sid.GetModuleName();
cout << endl << sid.GetAuthorName();
cout << endl << sid.GetCopyrightInfo();
cout << endl << sid.GetLoadAddress();
cout << endl << sid.GetInitAddress();
cout << endl << sid.GetPlayAddress();
for(unsigned int i = 0; i < 65536; i++)
{
memory[i] = 0x00; // fill with NOPs
}
uint16_t load = sid.GetLoadAddress();
uint16_t len = sid.GetDataLength();
uint8_t *buffer = sid.GetDataPtr();
for(unsigned int i = 0; i < len; i++)
{
memory[i + load] = buffer[i];
}
uint16_t play = sid.GetPlayAddress();
uint16_t init = sid.GetInitAddress();
// install reset vector for microplayer (0x0000)
memory[0xFFFD] = 0x00;
memory[0xFFFC] = 0x00;
// install IRQ vector for play routine launcher (0x0013)
memory[0xFFFF] = 0x00;
memory[0xFFFE] = 0x13;
// install the micro player, 6502 assembly code
memory[0x0000] = 0xA9; // A = 0, load A with the song number
memory[0x0001] = atoi(argv[2]);
memory[0x0002] = 0x20; // jump sub to INIT routine
memory[0x0003] = init & 0xFF; // lo addr
memory[0x0004] = (init >> 8) & 0xFF; // hi addr
memory[0x0005] = 0x58; // enable interrupt
memory[0x0006] = 0xEA; // nop
memory[0x0007] = 0x4C; // jump to 0x0006
memory[0x0008] = 0x06;
memory[0x0009] = 0x00;
memory[0x0013] = 0xEA; // nop //0xA9; // A = 1
memory[0x0014] = 0xEA; // nop //0x01;
memory[0x0015] = 0xEA; // 0x78 CLI
memory[0x0016] = 0x20; // jump sub to play routine
memory[0x0017] = play & 0xFF;
memory[0x0018] = (play >> 8) & 0xFF;
memory[0x0019] = 0xEA; // 0x58 SEI
memory[0x001A] = 0x40; // RTI: return from interrupt
// setup wiringPi, configure GPIOs
wiringPiSetup();
pinMode(15, OUTPUT); // b0
pinMode(16, OUTPUT); // b1
pinMode(1, OUTPUT); // b2
pinMode(4, OUTPUT); // b3
pinMode(5, OUTPUT); // b4
pinMode(6, OUTPUT); // b5
pinMode(10, OUTPUT); //b6
pinMode(11, OUTPUT); //b7
pinMode(8, OUTPUT); // a0
pinMode(9, OUTPUT); // a1
pinMode(7, OUTPUT); // a2
pinMode(0, OUTPUT); // a3
pinMode(2, OUTPUT); // a4
pinMode(3, OUTPUT); // cs
digitalWrite(15, LOW);
digitalWrite(16, LOW);
digitalWrite(1, LOW);
digitalWrite(4, LOW);
digitalWrite(5, LOW);
digitalWrite(6, LOW);
digitalWrite(10, LOW);
digitalWrite(11, LOW);
digitalWrite(8, LOW);
digitalWrite(9, LOW);
digitalWrite(7, LOW);
digitalWrite(0, LOW);
digitalWrite(2, LOW);
digitalWrite(3, HIGH);
srand(0);
mos6502 cpu(MemRead, MemWrite);
cpu.Reset();
cpu.Run(10000000);
int ts = 0;
int sec = 0;
timeval t1,t2;
long int elaps;
// main loop, play song
while(1)
{
gettimeofday(&t1, NULL);
// trigger IRQ interrupt
cpu.IRQ();
// execute the player routine
cpu.Run(0);
gettimeofday(&t2, NULL);
// wait 1/50 sec.
if(t1.tv_sec == t2.tv_sec) elaps = t2.tv_usec - t1.tv_usec;
else elaps = 1000000 - t1.tv_usec + t2.tv_usec;
if(elaps < 20000) usleep(20000 - elaps); // 50Hz refresh rate
ts++;
}
return 0;
}
|
65bedec36a90da852a5439ea034b139295598656 | 9f520bcbde8a70e14d5870fd9a88c0989a8fcd61 | /pitzDaily/762/alpha | ea7ed7f9a4b715b55cfb5960ac6176ae6a36b2a1 | [] | no_license | asAmrita/adjoinShapOptimization | 6d47c89fb14d090941da706bd7c39004f515cfea | 079cbec87529be37f81cca3ea8b28c50b9ceb8c5 | refs/heads/master | 2020-08-06T21:32:45.429939 | 2019-10-06T09:58:20 | 2019-10-06T09:58:20 | 213,144,901 | 1 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 68,875 | alpha | /*--------------------------------*- C++ -*----------------------------------*\
| ========= | |
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
| \\ / O peration | Version: v1806 |
| \\ / A nd | Web: www.OpenFOAM.com |
| \\/ M anipulation | |
\*---------------------------------------------------------------------------*/
FoamFile
{
version 2.0;
format ascii;
class volScalarField;
location "762";
object alpha;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
dimensions [0 0 -1 0 0 0 0];
internalField nonuniform List<scalar>
6400
(
0.900804095022
1.4557080616
2.31853612661
2.9180402655
3.48960607433
4.05736779754
4.75763660021
5.53818108415
6.03619251259
6.77796279871
8.07123680834
9.01841095896
9.82565841776
10.7178028019
11.7943674808
12.9276593466
13.9639688763
14.9411502837
15.7688746395
16.2904043139
16.6100522224
17.0793068724
17.8946859377
19.0264376003
20.2535019758
21.3730141343
22.3250039619
23.2161302171
24.1439179443
25.1236916969
26.1002228278
26.8898107113
27.4155750811
27.7910283437
28.0625374793
28.2385970999
28.5801185001
29.1232466709
29.3716315898
29.4132166248
29.8068840217
30.6724744702
31.5308027122
32.0291665883
32.2063876656
32.1572114556
31.9469905724
31.6173236518
31.1812690483
30.6583075072
29.971381929
28.9162091874
27.4908517233
25.7778675711
24.1957511765
22.765372513
20.8715888297
18.2895969427
15.5914905931
13.2802004044
10.9430296483
8.49799409157
6.23009403932
5.97852280352
9.02047482855
13.5909311306
16.3888160801
15.9594788255
13.8726435075
12.2286744689
11.3845352966
11.6702206844
12.3194002141
12.2737948661
14.4600540537
13.9455840457
15.9030894863
9.79979281207
12.8554644842
4.80132496346
3.16928454145
2.55669008819
3.19794447761
4.47675033211
4.47347275917
4.46862451512
4.75998677277
5.2724052075
5.98777307673
6.89007419105
7.96572874881
9.04083874333
10.0016431639
10.925074607
11.8710407786
12.9465271504
14.0793813436
15.1588105179
16.2393471779
16.598859315
16.7449303538
17.1959801992
17.9942911825
19.1164339146
20.4544592389
21.5231811153
22.4482415314
23.373777411
24.3147618416
25.2658514278
26.2162968619
27.085349312
27.6050563203
27.9733599553
28.2735335061
28.375145253
28.7576245488
29.3255026812
29.5354803469
29.4586021832
29.8262097265
31.1480187995
32.2618507455
32.675412503
32.7992155566
32.6844368939
32.39220474
32.0058121665
31.4318191923
30.7636548181
30.1348383364
29.5255243486
28.2688734609
26.0008117703
24.5170653808
22.8987943107
20.5317607235
18.0119780205
15.5161868693
13.0372230975
10.7095772768
8.7975881212
6.61830008986
6.49767279341
9.29105707567
14.6740452097
18.2179950516
16.7937381037
14.531825729
12.5629502078
11.8960099835
12.3989354758
13.6180875863
13.09213879
13.0216827895
12.5664546685
11.4326370653
9.63788667715
8.13103889547
4.21211361577
3.30128762134
2.93139816154
3.45763119167
3.80518491415
4.42522052518
4.91750775529
4.94547595971
5.16511003846
5.88465793886
6.86317945573
7.94973111357
9.04432624912
10.0487294745
10.9732039911
11.7747161388
12.7558169255
15.3002496633
17.3039459193
17.8422452919
17.4662819103
16.5509344723
16.8972777666
18.1046293083
19.2749410218
20.3916183782
21.5179086088
22.5387765064
23.4664161385
24.3875638051
25.3328359274
26.2531282968
27.2029861408
27.7154548433
27.8787584108
28.4522789998
28.5724748479
28.6847127205
29.4133066681
29.6758903095
29.665825598
30.0481605429
30.8909241973
31.7232919191
32.2223839824
32.4245732229
32.416250178
32.2396137731
31.9145875037
31.4443473495
30.8490934331
30.1267222109
29.1643775131
27.8373492168
26.3757628235
24.8629518539
22.8184152807
20.4509175848
17.9938128477
15.5231901099
13.1117218277
10.8637782073
8.71314889616
7.22337304523
7.9236181091
11.7082403897
15.7336861883
17.6704736148
17.6367568056
15.9821641439
14.2960448617
13.6398058861
13.5972338842
12.9729769128
12.4321236429
12.4901449396
12.231674183
11.3193280384
9.73123668097
7.29728044704
7.50492261828
3.38444674378
5.57825878459
3.84108430984
4.00868777272
4.73835985889
11.9504307153
10.3759582216
5.67378755538
5.84367466181
6.85276480506
7.96987192982
9.08608887705
10.0655820292
10.9941915355
12.6672923056
14.7353045827
16.4538259099
17.0388552214
16.3221317945
15.871133962
16.3750529173
17.1320383007
18.0995684192
19.2624140536
20.4693210765
21.6239565633
22.6695298635
23.5792851371
24.5149262913
25.3983393762
26.4255015888
27.1987491891
27.9537754272
28.0995898156
28.0704396726
28.6404403524
28.842273884
29.0690818886
29.4855392371
29.8671461415
30.3547753373
31.0598586262
31.7729793974
32.2676647376
32.5079305227
32.5352115718
32.3856767561
32.080765145
31.6295064887
31.0378714258
30.2874671192
29.314997196
28.077542473
26.6306050308
24.9359077499
22.867526278
20.5075167648
18.0462825361
15.6022112073
13.2712987604
11.1698549601
9.50107011807
8.85041579351
9.51358590103
11.5393599253
16.2251190724
19.4166043415
19.4381140528
17.6955096862
15.2920515654
13.6746739204
12.9055978969
13.1294917394
14.630598206
14.6304031245
13.3619229774
13.2792737819
16.6225795001
13.0001530892
10.9976086
5.81678238756
7.67421417802
4.69248843509
5.01366321676
6.75825612861
11.8492981932
8.45511151116
6.20854781967
6.37190384937
7.06954097669
8.10756655954
9.23512022466
10.6765493616
12.883453869
13.9651414207
14.4932984006
14.7491597957
14.8613103829
15.2101872593
15.91279778
16.4978862742
17.1891513134
18.191238113
19.3576829598
20.5754411929
21.7556084529
22.7775333573
23.7926098963
24.6187790796
25.6524916615
26.4668269948
27.7192668055
27.8957063959
27.7938872938
28.1439789567
28.259100302
28.6398868455
29.1374453139
29.6331848283
30.1016175413
30.6231239951
31.2546849169
31.8869799231
32.3663670154
32.631838788
32.691101566
32.5691954736
32.2873307355
31.8567032472
31.2767079398
30.525909979
29.5637194808
28.3619218849
26.9098553268
25.1451131759
23.0226026006
20.6548882841
18.2241529606
15.873496641
13.7402252125
12.0057037299
10.9409799865
10.8287838375
10.9899071775
12.119727743
15.9746145195
19.6031775352
20.8038798599
19.5470731192
16.7257432831
14.1980057105
13.8656167375
16.1877285444
17.1012461283
16.103848848
15.2309520759
17.9540981866
21.0066366525
16.2786989832
15.3886263808
10.0945384522
9.2804007602
5.85179471073
6.34940398134
12.1400887768
11.641221899
7.02036693779
6.84055244338
7.01920616278
7.4253048957
8.33725306907
10.8830402098
13.9965476782
14.527431227
14.3299648197
13.7012735114
13.6613987646
14.2551053892
15.2973049897
15.8725478547
16.4086405693
17.2600480629
18.3272318383
19.517860907
20.6727051754
21.8593900593
23.0917934328
23.892947663
25.0573835325
25.7071263619
27.1612784687
27.5388050372
28.4039799579
27.9675292911
27.6723177115
28.0418935893
28.6577102732
29.2721846141
29.8292915047
30.3481097234
30.889742901
31.4834452783
32.0638683531
32.5261069458
32.8061768361
32.8919125746
32.7969775675
32.5409333439
32.1359467747
31.5787514614
30.8475865056
29.907936423
28.7234253412
27.2510880123
25.4389637669
23.301543225
20.978097036
18.6546595875
16.4970226859
14.6777846796
13.3852290074
12.8464104372
13.0955590107
12.3660280151
14.1493324536
18.0887275718
21.0756966548
22.1788424028
21.1341852792
17.6888849135
15.415510389
17.1909591761
19.406719188
18.8949418279
17.9329220641
18.0469691246
22.7040375103
24.3234817594
19.274079046
19.078392819
12.2361678304
9.23291846438
7.10888295758
6.66351437119
12.1198740579
8.70252297974
7.32773379072
7.46517209595
7.62596652035
8.34623899339
8.91246343278
13.626273461
14.4115970901
14.5495191564
13.4532686195
12.7957462407
13.3062020902
14.6758944405
15.2400361455
15.6047489246
16.4171922099
17.3649793578
18.4355045832
19.6228348364
20.9328206158
22.1854708061
23.1157038152
24.5704977918
25.1514447778
26.6968560402
26.9491262575
28.0686917023
27.9516816324
27.7656166263
27.5439565773
28.0176110921
28.7519883388
29.444827639
30.0473540712
30.6036930837
31.1651892044
31.7437425974
32.2947613037
32.74401674
33.033463504
33.141112912
33.0731121664
32.8474071928
32.4761392922
31.9540723734
31.2571753122
30.3473865715
29.1770687714
27.6951500621
25.8769679873
23.7853389294
21.582860942
19.4577160563
17.5667420526
16.04731615
15.0631680922
14.6571095426
14.352211725
14.338078274
16.0902682718
20.9291779259
22.6951544445
22.6942095395
21.4473143658
19.0633436235
18.6627604527
21.1313908675
21.5182866801
20.6860442919
20.1238166398
22.1732888893
24.9985605061
26.5137800697
21.8927889808
20.7511534106
12.0032235419
8.99363893946
8.28657438093
12.3447495453
12.2776946569
7.90004286675
8.01360655724
8.1861576345
8.28393537661
8.88591383159
13.3422436798
14.3180712757
14.5029520843
14.1554897174
12.4234396298
12.4418246544
14.0135554806
14.7824499913
14.9095961371
15.4814470797
16.4457565588
17.5175708971
18.6221554418
19.8577214603
21.0244923502
22.4888024072
23.1880460683
24.5883623912
26.1934437897
26.8384899558
26.6904754149
27.61553004
27.9888246539
27.345553811
27.5523500784
28.1679804636
28.9102564545
29.6326069357
30.2784650371
30.8727340447
31.4569338784
32.0363839256
32.5751748737
33.0176465244
33.3147590188
33.4422990774
33.4030652195
33.2138915213
32.8859712076
32.4115331219
31.7624810536
30.8941277106
29.7522343041
28.2943454977
26.5320545574
24.5679908158
22.5700986859
20.6848833003
18.9969642046
17.6140802044
16.7149986736
16.307750184
16.2209009273
16.5273436459
16.564294423
21.5424370154
24.7863356443
24.3994463811
23.5514503327
22.3929916057
22.9742396753
24.1551856009
23.3729233555
22.6711551631
22.9214894136
25.3700426105
26.1267981529
26.7776625049
23.8937953144
21.7481257001
11.3518825139
9.00934994634
8.97046508151
13.3521741094
11.3728210275
8.60100937649
8.75974426945
9.06553301078
10.1624362753
9.03651973033
14.1118477499
14.8656679249
14.5626205998
13.0450052868
12.1393472297
12.5754588423
14.0711121362
14.5287875097
14.8061736134
15.4935901568
16.4409407817
17.577713603
18.7736877569
20.3725539198
21.7281906613
22.4615300728
24.3666310623
24.5207202495
26.3437044512
26.4081641931
27.6288870358
27.0719566377
27.0546186354
27.2827938385
27.72820973
28.3716114263
29.102768175
29.8379231191
30.5232115654
31.159538782
31.7718789176
32.362572441
32.9021320871
33.3453889784
33.6513287293
33.7994160135
33.793130217
33.6482853686
33.3742180254
32.9607229713
32.3756638854
31.5691302148
30.4879162794
29.1101158593
27.4852381028
25.7369916718
23.9916639494
22.2797623183
20.6086764604
19.2161328747
18.456103152
18.3691675597
18.5964653535
18.7497552485
18.6014300786
19.4763481536
25.3408525152
26.6231487458
26.2228513164
26.4648447813
27.1468150269
26.5012677796
25.3016126759
25.0440975157
26.1217012957
27.4678402949
27.4382082616
26.9109464893
25.9342816694
24.5815025088
10.9148439947
9.51998532532
10.1208673154
13.4540315362
9.60843801155
9.62968707917
9.51183806378
9.79435746769
12.7060458015
11.5184142974
14.9468616996
15.1620823293
14.6711632327
12.4628982205
12.2050699615
13.7479334734
14.2829614563
14.3055852544
14.7687972073
15.6262998842
16.559229291
17.6411457063
18.6980562163
20.5019429861
22.6357974969
22.4145394557
24.3094429921
25.7125165041
26.5590380998
27.3585636186
27.0416428333
27.2558932618
26.8146900052
27.2147387899
27.8964100093
28.5976713241
29.3235333598
30.0636331401
30.7818411529
31.4638031009
32.113437003
32.7253465938
33.2751021747
33.7264243702
34.0456153829
34.2175301985
34.2497266407
34.1583369752
33.9500236637
33.6125138495
33.1122409491
32.3988949006
31.428824426
30.2079282116
28.81526449
27.3542014037
25.823936003
24.0830872222
22.2718733238
21.023141921
20.7517212754
21.1794257456
21.5847963114
21.5877205367
21.1593725181
19.7739640451
19.1440399603
28.6440551757
31.0413524932
31.5074272359
30.8244046147
28.9079237048
27.6179567701
27.7707999525
29.0723566943
29.6328649411
29.5947979841
29.451995162
29.8846463061
30.1202771267
10.9964690844
10.417317244
13.4456315488
13.6963319785
9.82538441503
10.4175195528
10.2640342963
10.7038980062
12.3213201951
14.9121189346
15.8182801911
15.4751239552
14.963814542
12.5574832529
12.3776707384
14.2312646577
14.4029871318
14.2956179917
14.7866306938
15.7418444752
16.8828995039
17.9859051125
18.8561097633
20.1348677327
22.7862892305
24.0830426469
24.0046623457
25.8056317741
25.6237988236
27.3643037027
27.9057500271
27.2332564443
26.8048694418
27.3243761733
28.0914358134
28.8333099313
29.5681460415
30.3148454104
31.0572964511
31.7842606761
32.4813698379
33.1260601052
33.69509814
34.1615076216
34.4999735107
34.7023513141
34.7809052594
34.7523606056
34.6218714664
34.3773844194
33.988087856
33.4105992685
32.6201315437
31.6517899391
30.5855779308
29.4198218706
27.9324994866
25.9799176407
24.2267850341
23.5674462746
24.1496577249
25.1473082938
25.6539197515
25.4851724752
24.635052917
22.8950019788
20.4383496764
20.4767607543
32.7301829092
37.3513625941
35.4058038136
32.1425585011
30.558027645
30.7306967881
31.7537266391
32.5227183024
33.2401898362
34.0242738585
34.7608045008
35.5031101797
11.4383278569
11.33217433
15.1140305763
14.4872254095
12.7023963617
11.6719807715
11.248933219
12.1465962492
11.8990977627
15.8881837
16.518955223
15.8695517751
15.1290795546
13.241706905
13.1358854962
14.6761317224
14.4532470916
14.3925830596
14.894564321
15.7712170446
17.0035404052
18.4277218048
20.1454428886
20.2367331374
22.295637236
24.4242672999
23.9282880395
26.0197827159
27.0404261426
26.686406105
27.1393291249
26.7565276677
27.0767889459
27.6343239942
28.3417938906
29.0903482241
29.8401593942
30.5990026566
31.3568793902
32.1183407371
32.8705637409
33.5658481534
34.1649577683
34.6523275745
35.0175330425
35.2600383472
35.3949772286
35.4389280333
35.3975748113
35.2632550351
35.0142527481
34.6257139877
34.1021046664
33.4923161491
32.8033438059
31.8004855212
30.1936202015
28.3093282422
27.0464539237
27.4301109515
29.4240812799
31.1541520057
31.790014791
31.5851462695
30.5911774731
28.5270192772
25.3190777219
20.86437104
28.3503752711
38.5826255881
40.7832503742
36.6909700911
34.5124423545
34.2748211968
35.2220135483
36.3454088943
38.0620092372
39.2788020395
39.3968086579
39.7155979579
12.0977715029
12.0171866854
14.9150965344
15.0366858025
15.0777588197
12.8663904424
12.3625819592
14.9289366912
12.3511057677
16.7560696163
17.0554564738
16.271811154
15.2873920106
13.9054360446
15.5769195439
15.7131719529
14.6828810875
14.6277024854
15.1376411619
15.8958165868
16.9471754858
18.4149004778
21.3306253198
22.3178427792
21.8229707019
24.4539446624
25.5298226165
25.6146010752
26.9883254961
27.5977006321
27.4283777289
26.8009858493
27.2734258273
27.9515209511
28.6466798713
29.3811238498
30.1321203829
30.9141394915
31.7026165095
32.4853092365
33.2774123262
34.0331333483
34.6830394523
35.2030451531
35.6028010624
35.8968076864
36.1004465671
36.2263997303
36.2823699438
36.2712360074
36.1916027916
36.0541424176
35.897605333
35.7340002504
35.3546213174
34.2684841819
33.039265074
32.5411126541
31.6410465861
33.141090467
34.5695815257
34.3714055213
32.8828668645
31.1521594405
28.2278812622
24.639231255
21.2239065729
13.8601722754
13.3866604205
30.4758218265
38.1743267237
36.9948044409
32.6659344307
31.5589677247
35.0762236944
39.6693299798
43.3017598313
44.769870545
44.9347473052
45.2210946007
12.8114144581
12.7540293549
12.4033777027
15.4032245554
15.6590479679
13.6964428212
13.3594543675
15.9607021586
13.0687365435
17.6619202994
17.5450267465
16.6879035285
15.54557639
14.2598159999
16.7194143966
16.3454785451
15.169628672
15.0446957954
15.4897820989
16.1904112545
17.0130993151
18.2832648704
21.7947080546
23.3757795147
22.1565839153
24.4361733198
26.0142197012
25.2020157556
26.5989795334
27.2103617701
26.6838554899
27.1306225265
27.6973746832
28.3200904163
28.9842324988
29.7211019409
30.4747754328
31.2457462005
32.0676014978
32.9006656964
33.7277050158
34.5301408064
35.2387440603
35.8100650584
36.259923731
36.620153891
36.9057811243
37.1200520501
37.2756848621
37.3935809594
37.5045907877
37.6845054085
37.9968487134
38.3083729613
37.9426479281
36.7001340132
37.2224837534
31.8237613304
26.4433684768
19.4978846066
0.00737086482773
1.49685661573e-06
5.18439545135e-09
5.28952399803e-10
4.19755050897e-11
1.18236528968e-11
1.39173290936e-10
1.42200736989e-09
1.60630748518e-08
4.19552686297e-08
6.96699936447e-05
0.0182880324056
16.4843326538
41.5890236497
43.3111844168
42.1949377105
45.7131840441
49.6817057223
51.7094723457
52.1030131612
13.7034718259
13.8011118973
16.0575883609
16.0911315735
16.1591919524
14.4065547184
14.4251008831
16.8610417696
14.1201142834
18.4589439248
18.0194936683
17.1301236141
15.8859753675
14.6803051334
17.0313103375
16.6090745034
15.6499322284
15.5246476037
15.8874961596
16.5102428715
17.2546942028
18.2706680991
21.2544304419
24.1700586579
24.3960484742
23.8630099336
26.2003754879
27.1473881427
25.6606076718
25.9256075288
26.621902698
27.3562836836
28.0465989788
28.7012893891
29.3765824172
30.0906661363
30.8509971883
31.6431538217
32.4619301365
33.3373996873
34.2242847488
35.0752414856
35.8352348321
36.4655469643
36.986566555
37.4341381522
37.8172909545
38.1284794566
38.3749339945
38.6014762785
38.9155363322
39.4759657622
40.3319153624
41.0058897715
40.1706510502
36.8355758135
24.3873246672
1.75808975554e-12
1.93371641696e-15
3.62502700602e-17
6.1446691932e-19
1.77780525439e-21
5.05213446005e-24
8.74514912668e-29
6.84048159315e-29
1.66071163117e-28
1.11945094048e-27
5.24344570549e-27
1.93693146097e-26
1.23088967401e-25
9.63759137558e-26
8.36113450444e-24
4.75888259248e-21
4.78369246627e-19
3.63001449377e-17
8.35904622119e-15
1.40709051876e-10
48.7580966042
56.7508005264
55.8650195433
14.5458167501
14.7394379888
17.6933042616
16.8183743914
16.354071212
15.1151746217
15.4523650188
17.6387926193
17.6154505641
19.453828712
18.5639952025
17.6694472807
16.3164108909
15.241130752
17.3625800622
16.802965964
16.1019047665
16.009661365
16.2956763075
16.831557239
17.5342392215
18.4829473318
20.7733682394
24.4125380702
25.7224614895
23.6626899117
25.6901779192
27.2300100464
27.2438496922
26.3043842242
26.6821471347
27.5593986732
28.391497611
29.1209199964
29.7689160413
30.4909369331
31.2522715258
32.0682062178
32.9133734717
33.8111979492
34.7553113356
35.6723893209
36.4811668845
37.1596372709
37.765045774
38.3507280651
38.8760490418
39.2716455932
39.53843566
39.8415766827
40.3895865159
41.3530196877
42.7919556427
43.6865095757
33.8909493586
8.39398683749
9.7220723565e-19
3.93697013214e-21
1.13850803127e-22
1.65745899584e-24
1.34665040868e-27
2.24701525847e-30
1.58393136799e-31
0
0
0
0
0
0
0
0
2.20297841699e-35
7.43019013158e-33
1.11139807022e-30
6.44797568805e-28
9.00623959411e-25
4.87710892224e-20
7.40647866151e-16
5.77437445846e-09
61.8147989878
15.2341557106
15.4495159037
19.8078246354
17.3912251283
16.311918859
15.7389083818
16.1960951124
17.7644020581
19.201450892
20.5895320767
19.2641123173
18.3450730821
16.9967937753
16.0860425986
17.8990544745
17.1444848177
16.6260361622
16.5391410516
16.7420745513
17.1898468905
17.8176772923
18.6946345825
20.5722038032
24.2740600045
26.6920076457
26.0459509605
25.1889321782
26.5882582159
27.045462938
26.3805585872
27.1002273654
27.9955272204
28.8731510332
29.5898087202
30.2603018111
30.9305618652
31.7048658043
32.5250919427
33.4039712132
34.3354845694
35.3188434496
36.305787538
37.2003932943
37.929520781
38.6158765207
39.3610793341
40.0546049076
40.5140174462
40.7651972649
41.1197680761
41.8797699255
43.1669193171
44.9496240237
34.0689777175
1.897410621
1.40753321261e-21
4.61609608561e-25
1.86655861021e-26
2.54499647542e-28
6.97907199222e-31
0
0
0
0
0
0
0
0
0
0
0
0
0
2.83853743865e-34
2.82070426048e-33
6.18359489767e-32
2.99833965895e-30
1.66504681344e-26
1.38592437206e-17
2.67159293357e-22
15.7675388747
15.9741195135
21.8328756025
17.8325447722
16.4973540554
16.3107863508
17.0001966135
17.2294565779
20.1428786241
21.4035902242
19.9376025355
19.0329747946
17.8676055181
17.9154716328
18.6489937372
17.7251944389
17.3421437657
17.2589402013
17.2960036945
17.6337941707
18.1535135258
18.9482270349
20.5513944972
24.1092581317
27.0860166974
27.6561451501
25.1154345266
25.6215046693
25.9506702171
26.473909973
27.3927308024
28.4543235307
29.3446102298
30.1052575236
30.8005924541
31.5287912941
32.2236813072
33.0455065824
33.9387760142
34.8890844625
35.9452300091
37.0156934382
37.9816583205
38.7142196551
39.4283126179
40.6880092969
42.2507235643
42.8844430353
42.3983406527
42.5892642077
43.4537940207
44.7859449242
33.4107956251
7.44841401894e-16
1.12257356305e-20
5.03604150411e-32
5.08898232752e-29
8.3038167231e-31
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
4.38545135035e-33
2.96975522012e-32
5.47647484549e-30
97.7208171502
16.2212640571
16.3940472738
21.6990483734
17.3496216847
16.7414068713
16.8026332373
17.9076679885
17.29053932
20.944653189
22.1549862842
20.5711972906
19.666244584
18.5477886026
20.0673741171
19.6778304159
18.5056819536
18.1646762167
18.3160867329
18.0700265017
18.2456688405
18.587906564
19.2488167867
20.6688112001
23.9334913083
26.9405800657
28.7284656619
27.6136034326
26.8373520345
26.752159914
26.6848523657
27.6557751736
29.0251867765
29.7908577498
30.6320813601
31.5452428616
32.1350458392
32.8318712325
33.663872041
34.5810599746
35.5475861914
36.5858851027
37.7231892925
38.8267082343
39.8839727898
41.0518400583
42.638291119
44.0107758812
44.2971672518
44.3783379764
44.8584267198
45.8235986729
36.8657147849
3.38724806489e-15
3.091881073e-20
4.06372877014e-24
5.51932257243e-26
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
1.3493963108e-32
9.82162992344e-22
16.7302594395
16.8787739785
21.3682188644
17.0788098723
17.0539310865
17.2023035108
18.6892448373
17.7829148158
21.6525512828
22.8913605232
21.1951926826
20.2918392986
19.1126400737
20.8435480905
20.6278673598
19.3481400751
18.9730066577
19.2207730434
18.9920508972
19.0743627141
19.216948463
19.6076170843
20.9459200312
23.8921764842
26.6426706225
29.019598378
28.781476378
27.4215027134
26.3438646201
27.1485590809
28.1142988967
29.4520050286
30.5602395133
31.537145862
32.3649018287
32.8536051892
33.5251314318
34.3700879792
35.3096983091
36.3170306553
37.3768715738
38.5983137586
39.9899183459
41.5578425945
42.7219191952
43.4686357212
44.5002579822
45.3805154556
46.8189358412
48.3037788701
42.0997370843
3.08644169257e-14
4.09820533831e-20
7.06714499172e-24
1.44950783176e-26
3.50953728898e-28
1.17803254049e-30
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
2.26770588439e-33
3.00038201259e-33
17.4734942705
17.621477968
21.0872783037
17.3884148303
17.6155769688
17.6947902788
18.7434747932
18.510663498
22.1763247262
23.592081695
21.8477119783
20.9596262084
19.7847635511
21.5425141198
21.4762857907
20.2649264978
19.8292671264
20.0968635572
19.8924981958
20.0446595958
20.1075721928
20.1224231846
21.4157814895
24.0518612173
26.4912216485
29.0771698069
29.3285858151
28.2145023736
26.8689129665
27.3624081899
28.6660501198
29.6378182228
30.640692573
31.8081414129
33.261929327
33.8745891006
34.4652506497
35.1881709366
36.0952845057
37.1774328537
38.3483941314
39.7023394186
41.6571030086
43.3959508634
43.9410991731
44.5665873135
46.1166260916
49.2933827932
53.3234281995
45.9743472057
8.81806003926e-15
1.46483459677e-21
6.06182810769e-26
1.98747449498e-29
1.24703366015e-31
2.52763616919e-31
3.88150596385e-32
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
1.67612797215e-34
7.61080461056e-34
18.5915524043
18.7028346705
21.4171662337
18.3281703925
18.7607082775
18.5511622111
19.0912857976
19.8019641568
22.2764551684
24.129059745
22.5573492487
21.6919918326
20.557193407
22.3366815057
22.3491333891
21.3335514184
20.8569820584
21.1091966472
20.8003621862
21.1070926674
21.2960684005
20.852406349
21.9677095766
24.4171848359
26.5403775815
28.9299570338
29.5686826013
28.9007623245
28.7638540758
28.1998105404
29.0328550103
30.3510116359
31.8957625395
32.3980273894
33.5657904666
34.8814440344
35.5269749459
36.3043282391
37.1210111913
38.1279522417
39.4348255031
41.4502203507
43.9763995013
45.037284626
45.1847619086
46.5294676421
50.7991731433
58.0603148194
52.1811039031
18.090983228
2.21930348566e-23
2.07202241136e-28
1.41774603845e-30
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
20.1491095777
20.0412655754
22.2633886396
20.1823385857
20.6777101123
19.8080027596
20.0427190382
21.6594904307
22.5352592755
24.7652467209
23.3747763009
22.4985873636
21.4047403424
23.1670424558
23.2172984713
22.5065232039
22.3394634526
22.4239096356
21.8014274862
22.2580322192
22.7703316887
21.8792464731
22.4129537673
24.8757759153
26.7982840701
28.8101798221
29.7251394049
29.0833107957
29.9372803326
29.7537992259
30.0489903127
30.1348548053
31.7041344872
33.5517763077
34.5119619255
35.6421736234
36.5884309817
37.4058859841
38.3498493616
39.381047805
41.0664774889
44.0433248804
46.2733008212
46.8607420943
47.61593834
50.978850891
58.2211907999
55.1654645556
30.9234305858
1.98054487923e-25
3.46241047533e-28
1.58539360978e-30
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
21.7912835463
21.2968786435
23.1676596635
22.6249611313
22.3678720228
21.2516042283
21.0817663624
22.7876447033
21.8747737467
25.2672511466
24.282069161
23.3709378455
22.3165027301
24.0051905439
24.022864791
23.4893799227
24.3530030382
23.9979012024
22.9176352096
23.513907641
24.0949369027
23.1826218031
22.6185281037
24.8827051713
26.9779293129
28.7252600661
29.7801966629
29.1636959874
30.336870331
31.025271518
31.4249012193
30.9082772748
31.8980390996
33.5233452793
35.4145150196
36.8478236966
37.874580484
38.6709074692
39.6015506727
41.0006379695
43.7805536813
46.9890904142
48.787119421
49.8195586563
52.1556476931
57.0535067499
53.0823736451
30.650746891
5.33278865064e-25
7.72033668849e-28
2.70381084659e-30
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
22.6073875306
22.166339938
23.7411127373
23.6681067204
23.4231259232
22.6042751302
22.2557215878
24.1414089291
22.9166676103
25.8999463622
25.1987990837
24.2807336505
23.2870853615
24.865487851
24.82879712
24.3071886933
25.3267471847
25.1095325008
23.9867896034
24.7325622605
24.8462916318
24.0091087575
23.5999467971
23.8349751009
26.4560599202
28.2060646361
29.5452444588
29.1074738089
30.3948929105
31.5712823012
32.5591128309
32.6626326782
32.3124639903
33.5891547646
35.6498403852
37.7178017539
39.2735791333
40.3242854547
41.2492572082
43.6023587422
47.1582455494
50.0649581273
51.7032202954
53.6790103736
57.6839760456
54.306838965
27.4592133171
8.97008339971
2.53776583541e-27
7.2276884818e-30
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
22.6962474161
22.6921997255
24.0765417214
23.8845031246
24.0801008801
23.6429125142
23.2695790562
25.4712244326
24.5647524395
26.6984426058
26.1664622071
25.2132802047
24.3116971725
25.7632329519
25.6946035909
25.2415360984
26.1361936533
26.0713823361
25.0885069991
25.7499592751
24.7718383875
24.7630441119
24.6179373213
24.8729143719
25.6789132155
26.7549885354
28.6618653906
28.8292556085
29.9666085236
31.5820282401
33.0037563102
33.9993368397
33.8132748331
34.3744075893
35.873869849
37.9336623653
40.1945653234
42.045480876
43.6478695409
46.9618449614
50.5676596891
53.0124212997
54.3691463132
56.2944576707
51.9973088711
34.133989829
36.4860256271
8.81507101591e-27
1.97465836881e-29
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
22.9209848987
23.0464511335
24.3488476684
23.0491832787
24.3507387871
24.205326161
23.9386816116
26.0809374435
25.404830593
27.4952351599
27.1555046744
26.1360122726
25.3953589274
26.6855565198
26.5955830859
26.3034748636
27.0426846693
27.1424863633
26.3166921027
27.1440222676
26.1035113859
26.3439668823
25.8658451159
26.1701856141
27.4129976522
28.0467223936
28.2452470514
28.4702466156
29.4746067338
31.4592173463
32.9437080989
34.2183493945
35.058910606
35.4502362248
37.1116249814
38.6477460952
40.9370049497
43.6297317582
46.5990695098
50.5551172332
53.8069183571
55.5266361266
55.1931206876
52.2138572173
49.5598905447
30.8915574186
7.39695715411e-26
1.6839534915e-28
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
23.5740386862
23.663996725
24.6337969752
23.4177311695
24.5787392171
24.5025891087
24.3913849234
26.2805081556
25.9723863449
28.0760721789
28.1052218086
26.9884433556
26.5225203572
27.5833214209
27.4474061111
27.3253021325
27.9145502787
28.291769665
27.5912059034
28.5621350809
27.8539796631
28.3418258042
28.1895275296
27.1981827657
28.2109365267
29.132017821
29.3322043807
28.2177075051
28.9096395285
31.2762920496
33.0012515139
33.8635592142
34.8639628282
35.7339354729
37.476180362
39.2882770112
41.7795012848
45.2203627295
49.7299568244
54.245095142
56.8228960323
57.1507031139
54.8911694545
49.7500800817
31.5412403108
35.6985303669
1.17344499378e-27
4.75834553862e-30
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
24.401343136
25.3889836902
25.0556204784
24.3091160283
25.0630560456
24.8426126279
24.8113726528
26.4344507109
26.4735928781
28.3105958049
29.0045064928
27.7296768313
27.5062214595
28.3075083283
28.2278544275
28.0907609879
28.2600770624
29.3237192296
28.9100225522
29.7946312575
29.7295045389
29.6762899467
29.59143335
29.2556257032
28.6218807451
29.3166387648
30.2031236682
27.720229048
28.3045403984
30.5291796149
32.9470230412
34.2666972204
35.3791737467
35.6470432388
37.2585414767
39.4560374222
42.2667417555
46.6870683493
52.8579116613
57.8001367399
59.3496197
55.7706581754
53.7993570822
53.8986591494
36.0691190635
7.95371661314e-27
2.0299797877e-29
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
24.9979203761
26.0281102833
25.6803179325
25.0924179182
25.6776493746
25.3305828971
25.2788134046
26.6463104398
26.9427882571
28.2745436384
29.781703963
28.4111403177
28.084536559
28.879911648
29.0363160294
28.7570260058
28.5186260769
30.0501123884
30.2318111025
30.858701641
31.0302139134
31.2590408421
30.2554648816
30.2852658869
29.8428504113
30.8345710256
31.4485868811
29.1946314909
27.725910391
29.4026593699
32.0937299173
34.2578532544
35.5315206783
36.0414214468
36.769479392
39.0373276588
42.1023165294
47.7726500646
55.8310501755
61.3898373765
60.6033697224
55.7727872397
49.9041728624
30.1866447405
41.1170639641
2.34518609334e-28
7.88115712543e-31
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
25.3857404092
26.3105343879
26.1873331409
25.5976134343
26.2491525069
25.9177851117
25.7958546118
26.9828415369
27.4304230349
27.8702780538
30.2868202459
29.1076819071
28.4660954649
28.8597360975
29.8294842398
29.5166420565
29.0646960146
30.6396576076
30.9724369036
31.7199924774
31.9959777
32.5182104432
32.7278338866
32.7655789113
32.4435464144
31.9934325308
32.8511544436
30.932725377
27.6397514544
28.3310744536
30.1297621481
32.8031456686
34.9879062614
36.7692127384
36.9941231298
38.0407702868
40.8630374478
47.7401751318
58.5231167393
63.9258924288
60.4102508686
60.5151478968
58.5687402623
36.8820142584
3.36016122721e-27
9.18733353165e-30
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
25.7151209944
26.5304204491
26.5509198258
25.8951850308
26.706253784
26.5600423398
26.2924415028
27.3886759765
28.0692696909
27.3516352501
30.5745686911
29.8707120285
28.9948791856
28.484079639
30.5088724066
30.3233481717
29.878129931
31.3687044915
31.5174341198
32.1387135607
32.9688427328
32.5994717946
34.1065026596
34.6570841543
34.71819928
34.683957066
34.8543062765
33.929713479
29.5822012043
27.8453159318
28.8762102235
30.5450819629
33.0235972636
35.0306693166
37.2513951252
37.6501349315
39.0127734827
44.7305680707
61.7185800443
66.0736064042
56.9733630938
53.3846682274
51.3814729624
50.5181623298
1.14004213428e-28
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
25.986852722
26.6864305031
26.4502758025
26.0402076693
27.0318248384
27.1131823693
26.6647493832
27.3434265335
28.9010891285
28.1718905243
30.7626691162
30.6965343801
29.7485237903
29.1097742272
31.189371359
31.1324045417
30.9562304028
32.3159294388
32.3472457771
32.1740161346
34.0160984921
33.900840782
35.1577590829
35.7844963453
36.3381465407
36.9550827113
37.4522229657
37.5069997217
35.1216125825
29.5072187631
28.8051419977
29.6732206597
31.8667546203
33.3114627574
35.3211568459
37.0773122935
37.9095190872
39.0944090152
58.2968031701
67.126344836
63.2757745846
51.5710124757
20.4928434148
31.588320365
9.38557898527e-30
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
26.1712524514
26.7479174104
26.207979408
26.3042692211
27.3336425392
27.3898032968
26.961572517
27.1398806858
29.2531589252
29.0188470405
30.5997721702
31.5205878984
30.5346637289
30.2229597588
31.8786752001
31.8864532974
32.1357316399
33.2069038905
33.4747272754
33.3003141027
35.0112732358
35.3736100847
36.3467415702
36.673739095
37.9479193133
38.6468512779
39.8306082334
40.9127182315
41.4217247231
37.2070101256
31.3881932675
31.0201808907
30.8183528328
32.7977729196
34.2197894325
35.5020203383
36.3697986191
36.0003254784
38.7568077176
59.7262310896
69.4102562492
69.6771521128
47.7293051749
2.33416381216e-28
2.85900519168e-31
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
26.3370893299
26.4848504614
26.695682733
27.254419152
27.7097334795
27.6541426279
27.3238188809
27.3726272069
29.0912184526
29.5046799301
30.2622018674
32.1735487619
31.2003453834
31.0761666884
32.2810802337
32.5620917102
32.6389208407
33.6570363694
34.5058608141
34.7004835852
35.9490534644
36.4493987482
37.2966126027
38.3464428779
39.3616261404
39.5736134245
41.4090825476
42.9746142931
44.6765413044
45.8054670947
41.037782462
34.8342767637
33.245983247
32.5451831648
32.9342880845
33.6251115751
34.0880164804
33.6890460328
31.132604733
35.1235989823
50.8351873685
60.3106081252
61.2053366415
1.74441173107e-29
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
26.4857604684
26.5893273898
28.0405720476
28.0194959804
27.9466211386
27.8547644184
27.7394781867
27.759213168
29.1013232063
30.0115751495
29.5744814062
32.3279700688
31.8193551452
31.3093202932
31.9104962321
33.1882040795
32.9537536053
33.0793090613
35.151783589
35.3817165332
36.4883168144
37.5430394997
37.4346333877
39.7074176793
40.6490883726
41.8703336624
43.1008822984
44.5606086527
46.5422558825
48.7295100234
50.0983784917
46.2911576009
41.4445483445
37.8085834713
36.3989277285
36.0122816778
36.5975194653
36.9477154403
35.3084335191
32.2361523785
16.9613839625
23.9638318602
42.8291547515
2.20533172149e-30
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
6.68996450718e-35
26.4872390435
26.7078189164
26.9602995096
27.8143344453
27.8600870032
27.9147388181
28.0908019217
27.9934676485
29.143313366
30.3755724743
29.8588918639
31.9106748195
32.5784300186
31.6481108689
31.3064252436
33.6389036707
33.5367445893
33.540652644
35.560676201
35.9449160229
36.1902135706
38.6421268534
38.8411839846
40.5216362232
41.4812611423
43.4559738475
44.5584441348
46.0711683337
48.0590655102
50.2585714152
52.504951447
54.9663046643
53.8252148753
51.2873451696
49.536565309
49.0127527583
49.3065311344
50.2850379487
52.2649767936
58.3015839984
50.5237399517
0.000434460372023
7.10528582319e-29
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
1.67612797215e-34
26.3692390302
26.6244626008
26.5254911323
27.4895720333
27.9071181588
27.9670348421
28.1908136595
27.9897548302
28.6265241878
30.3307656238
30.2244344301
31.0842712495
33.2590854532
32.2775962584
32.0815434243
33.8001030393
34.2580545609
34.3558163735
35.7654679849
36.8125392932
37.143900207
39.2103872326
39.9565690606
41.1716928795
42.8155734301
44.2303961468
45.84005579
47.6363700797
49.3740785136
51.745211256
53.637269999
56.9632938901
59.3287072641
61.4708839349
61.1637693414
61.3108659617
61.6048891328
63.7982586357
68.3178302551
75.6035091079
82.7140778024
64.8421755717
9.60139421992e-30
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
1.67612797215e-34
1.67612797215e-34
26.2500917421
26.5355152082
27.044948434
28.0322751419
28.2340711305
28.0259789348
28.0789607358
27.8604873423
28.1508255593
29.818697924
30.5412686469
29.8892440918
32.7926974764
33.0438982428
32.4486534472
33.0993018377
34.8839327357
34.7589630561
35.1136875785
37.3462684591
37.8433807846
39.4569648267
40.9280492149
41.1235377491
43.6324453882
44.4022570221
47.1026184298
48.4435019141
50.1338077344
52.6992008741
54.8924803821
57.2186552153
59.593490949
62.1275321216
63.7318991078
64.3412985874
65.0442487346
66.4504449742
68.3710780978
71.3996942361
80.0383045172
75.6225680898
1.33635611783e-30
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
8.18054970818e-35
1.67612797215e-34
1.67612797215e-34
26.0854767861
26.3424113358
27.533822542
28.6879129066
28.1542270175
27.8859250469
27.8590563606
27.7206056419
27.8762026503
29.3031463724
30.5405993902
30.3703389908
31.5343323263
33.8745230163
32.855922849
32.7326988192
35.0665774279
35.3093222357
35.5037704024
37.5439250983
38.4436286062
39.0797209881
41.5854650933
42.2236641173
44.0912465472
45.6852301469
47.4062236634
48.8879728738
50.9238959355
52.8143994842
54.9847152946
57.0039823528
59.0447342588
61.2242750214
63.0108591711
63.9961738224
63.9309914649
62.6885326042
58.9726083406
53.2361226115
47.7243861912
53.9629347097
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
1.01842910383e-34
1.67612797215e-34
2.68728600209e-33
2.83558538599e-33
25.8506524293
26.0256123495
26.8362051884
27.6391027441
27.6685841369
27.5205969354
27.5152706919
27.5641584467
27.5168413817
28.3474161415
29.9125967301
30.6243700468
30.056237411
33.0137110095
33.5712107442
32.9562728516
34.0039479683
35.8272053342
35.8847839528
36.7654069839
39.0163985067
39.5026908282
41.6262708076
43.1419389485
43.4367393299
46.067425579
47.6317802997
49.6704165653
51.1862911664
52.8976565617
55.4224510763
57.2241696453
59.2042480343
61.1650992004
62.4479594457
63.8352443715
63.8504357855
62.5627633988
57.72476825
56.6987743616
0.00457892617981
1.05934122002e-29
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
2.08592854456e-33
7.04094687243e-33
1.04939905038e-32
25.5930939602
25.6878757871
26.3469636552
25.3919470273
26.7710889298
27.0139527475
27.0439684459
27.2155757733
26.9442056079
27.4249661163
29.0284667755
30.455668972
30.5851247935
31.447140859
34.0052867062
33.5245882532
33.5256656823
35.9418594787
36.5987975917
36.7004646058
39.1594735246
40.1710629583
40.8041455278
43.0211915857
44.2073511007
45.9879794961
48.1256087022
49.7598532476
51.752013804
53.7623311025
55.7690811041
57.6936455747
59.9543198267
62.0886002917
63.8938984603
65.2169363814
66.6822535878
67.7187249011
69.0019111334
66.2298386486
11.6066272777
3.14194181866e-30
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
9.49683513426e-34
3.40220515671e-33
4.78317304415e-32
3.2434806088e-28
25.137085548
25.2248528289
26.3796994041
25.4709014403
26.0356184123
26.3724699153
26.4555704076
26.5917985769
26.3970543804
26.6633207939
27.7354216694
29.4932187666
30.8770257552
30.9508305483
32.5964018711
34.4339591934
33.8056186489
33.9572217198
36.8454624206
36.846530895
37.441543988
40.1292713557
40.8331962992
42.7823468376
44.4745629881
45.713258447
47.9812449077
49.8437668593
52.1369422397
53.8170971097
56.1079040598
58.9381459697
61.621038812
63.9735789467
66.3559600337
68.8212766267
70.8671133983
72.2060180553
76.8501066013
74.1147435709
36.3611595444
8.37636952949e-32
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
5.99246792605e-34
1.99196682489e-33
1.91114148057e-31
5.53983659821e-29
2.6750416072e-19
24.3133863434
24.3909499225
25.4852104981
25.7951773895
24.7277071392
25.5867219225
25.8158725952
25.9888892061
26.1013322834
25.9945851455
26.5476515592
28.2390464688
29.9199220753
31.0087911479
30.9175880149
33.7816840505
34.6508249339
33.9814195612
36.1850133693
37.2697499272
37.4147579306
39.7400120205
41.1674261361
42.5858134966
44.4071640286
46.310050269
47.9046979036
50.4841836528
52.0679016912
53.9076911084
57.3408795311
60.2515303553
63.2643943026
66.0829409611
69.6969511567
72.8673416115
75.8885296864
77.4724878085
80.443246831
71.4402390447
4.85106141064e-05
5.7553085877e-33
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
1.92583540911e-33
2.38483047833e-31
5.4842598489e-29
2.05951825855e-24
4.1758107568e-14
23.4762920533
23.5109193903
23.574494019
25.3505169368
23.9778793274
24.8333212845
25.2652275274
25.4720022685
25.7694674288
25.4688041519
25.8641398849
26.443070772
28.5744377576
30.3968499923
30.7693404
31.1674815167
33.9565725317
34.3828404949
34.6538355354
36.908291097
37.8821854034
38.8770310332
40.9752635656
42.5527037391
44.2900169399
46.0909922372
48.1921424261
50.1934911124
52.2638755184
55.1420974668
58.1922725981
61.4325966552
65.1020373064
69.2778948575
74.1155617623
79.3154714843
83.810946091
88.9908923172
97.7715750388
79.8078024732
0.247822476865
1.39997982595e-32
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
5.99246792605e-34
1.42160084594e-31
3.20164973771e-29
4.73941640287e-25
1.18641220741e-15
29.824439114
23.0715107267
23.0686968
23.0490675162
25.2912242377
25.7241516194
24.8800604418
24.9375014963
25.0428067935
25.2370137924
25.2110643729
25.194672978
25.8810789989
27.0460650491
28.9836076459
30.6218912418
30.5470010365
32.1613730878
34.1212378173
34.6113343299
35.1510504685
37.6056458615
38.9208499292
40.0580196985
42.2328054569
43.9851170255
45.693029972
47.8895020794
50.1284853205
53.3928152496
56.4795080893
60.27026336
64.5002288583
68.5057697556
73.4184426371
79.2193980608
85.3309658861
93.8126635943
99.9999991832
100
99.9999999999
68.7920565102
1.39997982595e-32
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
2.98652939239e-32
9.78266368123e-30
4.67791586203e-26
1.12825327915e-18
0.0104784482611
75.9156751499
22.9011712392
22.8115143715
23.3221771594
24.597544349
25.6317892749
25.1891952658
25.1737098346
24.8776297361
24.7930287947
25.0038921009
24.6132301541
25.2051876568
25.5253118042
27.2473893693
28.9553201089
30.4687688424
30.8176463131
33.0033288919
34.3019676735
35.0216671552
35.6776548544
38.3155348087
39.8667073362
41.4615752916
43.3702881523
45.7850848849
47.9993596461
51.4496679307
54.4477820707
58.5070609576
61.9642790565
66.0396584908
70.6178164293
76.1832417814
82.0802707183
89.8035012419
99.9919868112
99.9999999995
100
100
76.9184838243
3.758511705e-35
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
1.50124516809e-33
1.39210210602e-30
3.6426763501e-27
9.70978474119e-22
4.81216402538e-08
68.6021604113
68.181101581
22.484694857
22.1552539969
22.8972441054
22.9270116534
24.3285334377
25.7822615557
26.4042203013
25.127485166
24.4211725559
24.3061693373
24.2879055228
23.9080602538
24.824092215
24.9484980075
26.5521090366
28.8072259244
30.350701707
30.9394537244
33.1094586058
34.5239238408
35.5612315746
36.4172858155
39.1353438602
40.8105163005
42.8551985849
45.647834221
48.6984453303
51.6318848193
55.0763537201
58.2770413858
61.8312831094
66.6006669527
72.2354913342
77.6366351383
83.4843865311
92.2775882046
99.9778225377
99.9999989947
100
99.9969421531
99.9998206554
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
2.89867138432e-32
1.53013839994e-28
7.04898314247e-24
3.72295439979e-14
59.2331613836
57.153014718
59.6842941579
21.9137514131
21.0335021252
21.094007877
21.3060356322
21.9184046542
24.2665182501
26.3530891594
24.8652444037
23.9018493162
23.4608160508
23.4856978749
23.0723303884
23.8006085879
24.1177334416
24.9262507138
26.0167215031
29.0109350832
30.5175676671
31.166902556
33.2982994204
34.8145264013
36.1830009335
37.2717772613
40.06341654
42.6260622309
45.2765489111
48.0447239974
50.9523564172
54.4845104553
58.0444318341
63.4115239182
68.0998092227
72.8232306241
77.7031635007
84.1614243794
90.9127903108
96.8257947707
99.4607195775
99.9922101785
99.9758972905
99.8827889202
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
2.13194294161e-30
5.98320006238e-26
7.16098082445e-19
12.0441839124
53.2399572282
52.1171488014
50.624112556
21.5858314923
19.7751827633
19.531692513
19.702104533
20.154093766
21.6696332314
23.7965874747
24.2640477148
23.127517193
22.5338068514
22.296173062
22.4835204269
21.8489639743
22.957871474
23.1655097066
25.3811017672
26.6608649298
29.0961872614
30.6824937405
31.5442175611
33.4814711334
35.3743416569
37.2017234576
39.0526907069
42.1532517044
45.0690312395
47.3540771636
51.1872080555
54.8567245751
60.1126043341
63.7714606334
67.7138239088
72.3813147805
78.134567741
85.1159954704
92.733759651
99.8587338772
99.9999932252
99.999268023
83.1430608424
0.00276653982207
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
1.60432695737e-33
2.33821147308e-28
2.3252897638e-22
5.59525918371e-08
52.1707207993
51.754779772
45.0523493096
43.5273100692
21.4723896046
18.6740108732
18.1785594294
18.0792634731
18.4057364931
19.3311299827
21.295993186
23.3603848133
22.3974356835
21.5313256167
21.0837806022
20.9593539939
21.1079692763
20.6090185655
22.5322861787
22.7516798301
25.0563913166
26.147886611
28.898857491
30.5876699752
32.3322215257
33.3370611916
36.6297580894
38.9940910757
41.7031064637
44.6355258324
47.95277116
51.7145986626
56.629323424
59.7079467796
62.7246309541
68.0491547569
73.6411160618
80.1624175132
87.6940786654
95.982760824
99.9996984409
100
52.9830532902
2.59556100846e-16
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
1.94071920426e-32
5.20529434551e-26
1.51042187061e-13
53.3833172123
53.1468912812
46.8885936299
41.0918144557
38.7960195737
20.319017698
17.8100782992
16.947544048
16.7603388577
16.7447910578
17.3047168721
17.6819849042
20.9042583403
21.8127512366
20.5746444929
19.8203707819
19.4518782627
19.4567100526
19.6258573907
20.8871898774
21.5236543569
21.617239987
24.7078608583
26.2582661743
27.6839100754
31.2169634234
33.1931295264
35.4824228858
38.5304401662
41.4111701432
44.3838556641
48.2445731314
52.5706229219
55.5785804152
58.1683665022
63.7005328873
68.8813185458
74.5681052752
81.0808535344
88.2801460271
96.0786232209
99.9907957259
99.9999715224
9.33420650517e-18
5.18267179311e-17
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
2.29023091319e-29
1.35043942705e-20
53.7237794436
60.0381337085
50.9668010176
43.6312341774
39.5319703993
38.2570220406
18.6680596365
17.1755671721
15.9553610667
15.65526066
15.4643283435
15.3769617205
16.4594948054
17.0470353176
19.8561993081
19.5628546996
18.5042623042
17.8952166489
17.5602346155
17.9988717269
17.763766594
19.4331600035
20.2900848781
22.7075606915
24.4496126945
26.7335856293
28.9549358703
32.5311562567
35.1486960202
38.0507242739
40.7397723631
44.680537925
48.2214114851
51.7132826812
54.3605456401
59.5782304071
64.3718946046
69.6506164681
75.2268458528
81.272488613
87.5254391174
92.8378580242
97.1336911269
99.967751732
1.30986996806e-16
2.30510691435e-11
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
4.34958493862e-34
1.70728400465e-26
15.0186616981
65.2179804012
57.5068653741
49.6666448041
43.5449721687
40.1009038415
39.3011695929
17.5558001306
16.2154749308
15.1454679839
14.5201767602
14.2577759245
13.8865227666
13.752348634
15.3993731633
15.4508234946
18.0635765484
17.3890784571
16.3370706384
15.4690370338
15.2351920374
15.7519606478
15.9089371831
19.0445529036
19.9339937352
22.630673562
24.0548818191
28.3176107869
31.7933769862
34.6437111134
37.2672811304
40.4324290517
44.1708827974
48.4585034989
51.2779843761
56.0598946663
60.3781272066
65.3459466491
69.8487983117
74.6565078795
79.5574106047
83.9241160415
88.5571356986
94.2105698197
80.3555845072
1.73531318201e-16
3.02378204715e-08
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
1.35656390415e-32
2.06432803301e-14
66.4920332641
62.9975032415
55.6760278773
49.4442511232
44.9188359226
42.4418720506
42.1595049517
17.2590281485
14.9048016554
14.1694967623
13.2856064372
12.882414631
12.3280789013
11.5210998138
11.5971092111
13.1609395806
13.4526867715
16.6176784734
15.2435280078
12.9998141756
12.2552078328
12.6024302538
14.2320811932
15.1435970944
18.7091586405
19.9980867866
24.0584121215
27.0005856527
31.081540355
34.0100933653
36.8532310067
40.429201394
44.6823197765
48.306905797
52.8946708767
56.837844551
61.3226742529
65.3796215259
69.8493843601
73.9203278018
77.6268707234
80.7810881726
85.1985065139
86.801464529
43.2760676946
6.34183867035e-16
8.93529218809e-05
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
5.7604917804e-28
59.3508166041
67.331080436
60.7625066538
54.9095218578
50.2334200003
46.9975776681
45.2029503746
43.9993605756
17.4877276802
13.6645680535
12.6693033236
11.8828981944
11.261401428
10.6740112704
9.6856227625
8.06808032223
10.0487864867
9.86595977882
11.6938083772
13.994423595
8.97127358659
9.11998184971
8.80157007795
10.8034945966
14.0222882611
15.7914311039
20.1022756413
22.5467687898
26.8241196605
30.2180070391
33.6231282106
37.3570836958
40.8905119015
44.9129641827
49.6186383593
53.5424162171
57.8729321962
61.7069336662
66.1993839417
69.5974117655
72.6429524878
75.7131487251
78.9625545794
82.0410577211
79.29602404
31.1844879514
1.07575551382e-14
76.9725767224
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
9.58276157867e-34
46.3673320114
72.598743366
66.7691618315
60.3436063033
55.7138586894
52.2968184452
49.8546035836
48.5870639127
47.757106742
16.4871839456
12.1981501222
9.76067382792
9.65456614516
9.43598550187
9.01889728245
8.12020599235
5.91515811635
4.19425614238
6.42541102482
6.69785672817
12.0456122732
9.84846296327
1.91706590054
4.35316701599
7.49522800895
12.2529283398
15.9503309997
18.5287805374
22.9620830727
26.1702680451
30.4043723055
34.2311938969
37.9202692593
41.6459927069
46.0104615678
49.9071729845
54.6628081801
58.371719652
62.6217948163
66.0380916135
69.5983752837
72.3036570945
75.7523229854
78.2485501124
78.0130207379
79.6171960991
58.1881732276
1.60310511971e-13
99.999982611
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
6.88450067515e-10
73.1633963667
71.2019306394
65.9710681583
61.1946760848
57.866302041
56.2678298688
54.9515116774
53.7144570934
53.4479294831
14.2521412223
5.47590175779
4.63692353306
6.5952590517
7.62477073435
7.82318803931
7.19057637788
5.17274498321
0.270003301078
6.33105268189
4.83928328374
5.14959696514
0.0833167978281
9.16848714999
2.20152867522
7.05585731397
11.9905942013
15.4770052638
19.2219407898
22.310475889
26.5694609462
30.1404738897
34.6072925041
38.6179622264
42.1718187365
46.4501485456
51.1896162981
55.1615077973
59.4294231592
62.9960768636
67.186828644
70.0555746458
73.2997802901
77.4341098993
78.1002298135
79.4451449947
83.701118241
75.4727514785
3.47171964348e-13
100
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
6.54983524684e-33
67.2953108418
70.4696088984
69.4823038204
66.066190454
63.1476520914
61.3681072275
61.0505374375
62.1129561318
60.0833761605
61.5552645966
12.163107699
0.420317245123
0.170243578041
4.20295774688
6.78531241561
7.44257085577
7.13068792091
5.74846457482
0.242212814846
0.0314584363576
0.449534228419
0.17696350062
0.0735908384239
0.242797981468
0.665658806499
9.5760504058
13.407042955
15.768100725
19.9174892883
23.2314801435
26.3688302221
30.9735161685
35.49908392
39.2980214347
43.0778859952
47.4998538355
51.5123944408
56.2693565667
59.8717616779
63.9797508389
67.6788678437
71.9930614212
76.2696531034
78.4501120018
79.3796303284
80.5730100227
81.6535159123
82.0840674882
9.40258530321e-13
100
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
54.2560134921
73.6043349954
71.9940902193
69.9456465392
67.4448449982
65.6256471344
64.6338169768
64.3076072822
66.1712392578
65.1322873259
64.5567171364
10.2663586325
0.134310775818
0.0224958244112
4.63271671639
7.39174756443
7.95175030136
7.50657634213
6.32369796854
2.73156327486
0.0144551901509
0.00641004159573
0.0266836143825
0.242258287849
0.10644059519
4.44079182991
9.49841165448
14.4924123135
18.1398901734
22.0465232052
23.7749060533
27.5570570685
31.6573823554
36.0533266445
39.9232058179
43.4812370512
47.8190591127
52.6075790462
56.4641191652
60.7447723979
64.7987315568
70.7474825517
75.1636322653
79.0245087249
81.0377560674
81.8234563929
79.4946729027
80.3195312016
84.1524249261
1.62491302786e-12
100
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
4.1352102466e-27
79.435627071
74.812637131
72.9584049557
71.0958184083
69.2428590174
67.9310935927
67.1000584169
66.5626778535
67.3747178507
67.1099150828
65.754037137
7.0092553355
0.0107618039172
0.00403735896329
7.14014767746
8.88851362915
8.91091025564
8.17290575146
6.75925672571
4.26441773315
0.00599703439267
0.00266732076181
0.00286932529764
0.0144759907219
9.77582203122
10.0387164013
11.5511364769
14.9722028866
18.637509687
22.0642848674
25.5200712947
29.3645079789
32.171814802
36.450172911
40.3509276031
44.1651724459
48.606849674
52.8038653646
57.5843932299
61.5931099447
68.3743337543
74.8930169755
78.9124304977
82.3604713244
85.5189912829
84.9933316852
83.4380498963
82.0509317834
82.233626416
1.14901051678e-12
100
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
68.9169187283
70.1294212601
74.6186504357
73.5856785905
72.4880693105
71.1462941247
70.0939295116
69.3014468737
68.7053666325
69.2134894968
68.6518667869
67.4544161305
0.000312073112609
0.00103966605572
0.849484922388
10.0770547968
10.5287900164
10.0340860816
8.86397510746
7.30867304157
4.8418931695
0.00275882292703
0.00115713579397
0.00111209493485
0.00361187040768
2.43932695321
11.3207098805
11.6875566832
17.0285387998
19.1495291329
22.4214470231
25.6084848968
29.5286479766
33.0976480527
36.6824558187
40.6746501883
44.6084600216
49.0330201791
53.9923635035
58.1752024914
65.3435907191
72.8631564416
77.3550884976
82.5770137786
87.2998778131
90.3618238241
92.0388357485
94.1151030296
94.0088502781
99.8991044269
51.7589841425
100
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
8.71306994296e-12
90.3584098897
80.7648335596
77.8182577509
75.6197415224
74.2547883431
73.0235858201
72.0647737857
71.315563755
70.7493411255
70.9248061914
70.1583092399
69.6944614987
0.000119539823287
0.000206757391938
7.35830011956
10.193955089
10.3219673349
10.0502082574
9.55570205229
7.95719605463
5.48193339759
0.00134182819962
0.000520830338679
0.000495685934164
0.000792094310882
4.96546447633
0.0523820022087
14.8701402019
17.926210531
20.3825882566
23.6838071887
26.542021669
30.0152007193
33.2230139173
37.0331080394
40.9790153832
45.1704060506
50.3308103885
54.861310513
61.5255382154
68.7993524697
74.425040641
80.2066175979
86.1679983248
92.7841507449
98.5843389869
99.9999513384
99.9999998653
99.9999999992
100
99.9988997056
100
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
88.1365024385
83.5480050607
81.9941599445
78.8998710613
76.8650128362
75.3496109377
74.1638988964
73.2354455615
72.5525382177
72.0937401584
71.7008549171
70.9710714971
70.9165785472
0.000111280470673
8.85731501168e-05
6.3301020033
9.8139503646
10.193128419
9.90247239466
9.18972166742
8.15385655355
6.27718142438
0.000633423747195
0.000247963764783
0.000233096128314
0.000437392925998
0.00218950143225
11.2999053286
16.2943088981
17.3112386461
21.7612084677
25.0261433724
27.0309603951
29.8742488289
33.3956109436
37.5783516951
41.2890193872
46.3916595312
51.2905476318
56.8858868589
63.4315439165
70.109672914
76.4016393898
82.6718234795
91.3653589317
99.5968555
99.9999994815
99.9999999996
100
100
100
99.6860107785
0.000221124477069
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
3.46560260251e-19
83.6938607446
82.5923218724
80.865116911
78.8099577043
77.0528437961
75.2675543153
73.9729863745
72.8901280053
72.0692263491
71.846053393
71.1702156303
70.3003073187
70.6895482543
0.000149752115699
4.50190829366e-05
0.000450634302984
9.99164799019
10.3742203461
9.90270865961
8.98665854905
7.62353496235
5.74279191278
0.00128291660957
0.000135703830653
0.000121975089082
0.000245860957859
4.60607836103
8.63105614506
13.2710704493
19.55002623
22.4250963419
23.8282065311
27.8040972513
31.2271197291
33.8254701666
37.1489416593
42.3208828458
47.6033845497
51.8729260975
57.9806648715
65.1223796187
71.6340333509
77.8160651083
86.8581760408
96.8225934609
99.9999735264
99.9999999988
100
100
100
100
3.97790176669e-11
2.04471822668e-12
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
92.6556139103
81.9869319998
82.3181793514
79.9756462906
78.424630727
76.2999356195
74.2677524004
72.6735612383
71.2920194686
70.1277959697
69.1931790052
68.7158531424
68.3921512717
69.4164241353
0.000431791756681
2.8265751828e-05
2.98464113037e-05
10.4880515699
10.7001293094
9.9592299632
8.78262817912
7.1236094413
4.37121098546
0.000140222655176
8.83601814215e-05
7.96508897659e-05
0.000127259370129
4.46569496791
8.72984163966
12.3781115971
17.8526301463
22.1506029816
24.8013381182
28.5316635697
29.6822003349
33.7430562476
39.0569173238
43.6758843583
47.0455458985
53.2439335015
59.9376507708
65.6297601269
72.5768623644
81.1950882994
91.0007189561
99.810020115
99.9999995349
99.9999999997
100
100
100
100
3.31416804923e-16
11.1674763764
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
1.50671562024e-31
97.5356922666
87.9720616918
83.7954399817
80.5186329448
78.0276202642
75.8062405075
73.0282843661
71.0947338157
69.5211194874
68.2725041024
67.3316157996
66.9948635512
66.3917176204
67.0749349725
0.0198128892526
2.53556309249e-05
1.28243401188e-05
10.763479451
10.9012281114
9.9486529792
8.52631446334
6.68108727184
4.18804184617
8.24768545476e-05
4.72014917609e-05
5.17428907983e-05
0.000150092876049
5.49582034792
9.02683480915
12.7142810124
15.813976832
20.4814485758
25.1498195742
27.3829044211
30.4551971157
35.1866181213
39.7953230536
42.2537985694
48.1648650239
54.5788816233
59.83937967
66.527403104
74.6986408925
82.7657053677
92.6798353814
99.9965922451
99.9999999652
100
100
100
100
100
7.79780398384e-21
100
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
95.498524187
81.1688786152
87.5925679528
84.2917752646
81.0808566061
78.0104474257
75.0743310897
71.9727819685
69.7286183191
67.993834726
66.6681144534
65.8225528203
65.5729669485
64.6935237321
63.9515090077
6.62143862659e-05
0.026276340558
8.17795238545e-06
10.0211448373
10.9074627473
9.74707802646
7.9039154061
4.88923654883
4.62255939921e-05
2.08199086034e-05
1.71074015058e-05
2.03355053967e-05
4.07152347058e-05
5.79966608296
10.4758973668
13.6958855858
15.9178026153
18.3033909682
22.5330419375
27.057559186
30.523718984
34.6042773655
37.7648266254
42.3535251975
49.340795035
54.8343215491
59.4814963388
66.5371766607
74.9358335178
84.8844929265
94.8932548483
99.9993280096
99.9999999917
100
100
100
100
99.9999999999
2.0689314011e-20
100
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
100
99.9934676512
92.9722655715
87.0783519681
82.7448851706
78.369795766
74.4922773745
71.303106957
68.8107371934
66.9099184019
65.4532297922
64.6233743422
64.1127078964
63.1768490491
62.4687074888
4.23178342974e-05
5.64164190167
4.98389042334e-06
9.06182255148
10.9615389263
9.60390530061
7.76319602249
6.55469192988
5.06508818474
0.000684213618173
0.000109751468137
8.48619545075e-05
0.00024235736486
6.6084660638
10.7182125913
13.8073896161
16.3046779476
18.7106707234
20.8075025152
23.2265202035
27.9570634978
32.6323436619
36.5605724101
42.2420873088
48.7142045105
53.827458596
59.3890976878
67.3526330502
76.4046460725
84.6340532259
94.9359972
99.9999316778
99.9999999993
100
100
100
100
100
2.68270452613e-14
100
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
3.5140362491e-06
81.1490056496
98.729619846
94.4654439038
89.4306484366
83.7402681117
79.4135992087
74.54119496
71.1040887214
68.3331898063
66.2600005228
64.8168346177
64.2868861749
62.9450646866
61.9564350326
61.3725100265
8.77364375063e-06
6.31166743868
2.88964434321e-06
9.53408369456
10.1586545748
7.65683140733
4.47579294044
1.1516820036
3.65798023475e-06
2.10411804378e-06
1.91036907329e-06
2.42240267064e-06
5.21289959662e-06
4.90942857794
11.3727655069
14.9551434122
16.4016132449
17.7357809753
19.5783500375
22.239498608
25.2323031135
28.8332866184
34.0654410876
41.3524165123
47.9977562093
53.8099404151
58.4078020258
65.8643196746
74.71025089
85.2294353381
96.8902785834
99.9999888977
99.9999999986
100
100
100
100
100
3.40835693932e-13
100
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
100
100
99.9999980845
98.4339368355
92.1913483516
85.7838657663
79.859042526
75.0791851651
71.0650788452
67.8497638541
65.5049704076
63.9637172999
63.0555108357
61.565073364
60.7667341752
61.008005425
1.20185864183e-05
3.88293421178
1.68675540721e-06
9.05835248903
6.94957825851
4.42515938274
2.22317296001
1.42548627368
1.00204301219e-06
1.07657554895e-06
1.56409836029e-06
3.34887517186e-06
4.76063337375e-05
7.04567094805
10.9013896814
12.9457840161
14.07633247
15.1752416308
17.4207784704
21.1244043912
24.1574144353
27.8979376297
32.729172855
38.8628074286
44.8900968339
49.8590355264
55.8181812267
64.884439181
74.7591570038
86.3524212315
97.5487583278
99.9999275082
99.9999999995
100
100
100
100
100
5.05009184926e-12
100
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
3.05263579696e-32
99.9974115573
100
99.9999999891
99.9973900886
94.0088583913
87.5872818256
80.6611937821
75.2545352741
70.6848066278
66.8918885
64.0923630388
62.3340158655
60.7595637132
59.4612991133
58.5311620281
59.4477839425
4.55136665132
1.12231611603e-06
1.02851190772e-06
10.6235374016
8.40702423147
4.88377783325
2.29790002834
1.41179819589
7.1835716535e-07
6.78125944072e-07
7.14124446429e-07
8.61132133215e-07
1.60092577669e-06
5.16220696919
11.5592109516
13.3965938432
14.1405890004
14.8022258344
15.9673451172
17.7480225679
20.8630405146
25.6653384203
31.0930444442
36.9574233049
41.8649542909
46.8677710155
53.7671572373
63.0147529584
74.0766190922
85.4154916264
95.8289857563
99.9998241679
99.9999999999
100
100
100
100
100
2.0208102545e-11
100
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
92.2264401454
99.9999957521
100
100
99.9999989284
97.536037609
88.5125237776
81.2113929481
74.9572910198
69.795732278
65.5337038406
62.167166735
59.7448813949
57.5766559838
56.1660136413
55.1085728586
56.3273709654
8.47143604047
3.31269225059e-05
9.53127616008e-07
11.4036366138
10.0967191871
4.47870621874
2.85709509018
1.80142131414
4.6924116362e-07
5.53449177496e-07
1.10439718749e-06
2.6530586719e-06
3.04473779349e-06
2.70514691762
10.15106613
12.4376741823
13.06282656
12.8898267648
12.7538111303
14.0276981747
17.2600872193
22.4244857452
28.1723129932
34.0484034362
39.9215773882
44.9436948894
52.4676458578
61.332439132
71.1218979362
82.2296573893
93.5470893882
99.9996967645
99.9999999998
100
100
100
100
100
8.62695100023e-10
100
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
100
100
100
100
99.9999999996
99.9976635292
91.5245208197
82.0932219922
74.4977655761
68.646844086
63.9135259147
59.1997412843
55.8537182483
53.4624732555
52.1264115124
51.1330816189
52.171082546
9.73571043981
3.31872733757
1.23487705912e-06
3.02858896128
5.23456123323
5.33247977527
4.84697737641
4.89266590291
6.36880291812
3.33682215029e-06
1.0593983673e-06
7.84960366611e-07
7.89228513358e-07
1.57916109019e-06
8.66053236479
12.4531272757
12.4651849503
10.5876315983
7.22248197668
6.03555369952
11.1742490635
19.6762938305
26.2370700281
31.4903392338
36.445768423
42.1992786416
49.7702373194
58.7930146051
68.8219259139
79.2390449749
89.1583677942
99.9249484404
99.9999999901
100
100
100
100
100
3.41587576131e-09
100
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
1.52021326185e-31
100
100
100
100
100
99.999998608
95.5337239766
84.0742955554
74.4694626694
67.0709553457
61.4710352054
56.8259586982
53.0751699214
49.679492262
47.4472686589
47.0361169512
47.1161892096
7.50589615308
4.66798769032
3.54354547885e-06
0.000720879369808
6.72824991529
8.83271915972
10.0795986786
8.51382075594
6.14589751155
4.02136702404e-06
9.44401104791e-07
6.06712229973e-07
5.04136385539e-07
6.22383990926e-07
6.10478006509
12.2420170475
12.9950288056
10.8686447347
4.71405862741
0.876467376785
8.35296448346
16.1218920119
22.1422168795
27.3348798681
32.5618725133
38.6011656906
46.4179646857
55.5972561088
64.9609421072
73.7639674137
83.9810574715
97.2615584478
99.9999806415
99.9999999957
100
100
100
100
4.12081085135e-06
100
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
98.9548299376
100
100
100
100
100
99.9999999994
99.7492362406
86.8136335302
75.090854324
65.7885657429
58.861436656
53.2281999925
49.0589587818
45.8309354553
42.1869873071
42.2691973078
41.5141478938
4.9375443447
5.62954133931
1.50387282356e-05
2.87250367409e-05
9.29841880933
10.878055096
10.360906561
9.63342444066
8.63907058473
6.34144300121
2.15885289162e-06
6.00142590964e-07
4.10303915408e-07
4.09413462545e-07
1.20215500197
13.3262311927
13.2329158392
7.47820471273
1.88650005807e-05
9.82147187633e-07
1.06566303336e-06
8.07121776206
18.1535402757
23.1211428154
27.916795257
33.7418130025
41.5291901989
51.0577314134
59.5201115186
66.8620979913
76.3691997299
89.0606275682
99.1934603197
99.9999903176
99.9999999997
100
100
100
0.00979090561763
100
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
100
100
100
100
100
100
100
99.9999304946
90.2097767825
76.8097111609
65.487112379
57.1498612159
50.1788072072
44.6874033018
40.9806720074
36.9830601937
36.383717651
37.1398554586
4.55838041621
7.62510004044
0.000541546772658
8.831003477e-06
11.2793568911
11.595042238
11.5958272143
11.2239480526
10.548258835
9.15349198249
1.50854957188
8.8671123593e-07
3.31594521539e-07
2.74066806343e-07
7.18760024302
14.7660780059
13.3359413669
0.00441138869129
9.03374170072e-05
2.61390139182e-07
6.33851592758e-08
4.77845308527
9.40459556295
11.4065464154
19.2487836032
26.3016636966
34.2760974538
45.3460752147
53.271312898
57.6942498771
65.257469836
77.549944685
83.7067198015
98.6134114417
99.9999983699
100
100
100
99.8980667653
100
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
3.5259769453e-32
100
100
100
100
100
100
100
99.999999968
94.0365400141
79.0905599126
65.9322267657
55.8198863413
48.4374018529
41.6478201961
35.9684746008
31.4319725509
31.4588442839
35.8114218504
0.395396164802
1.36899048275
0.000334556506525
2.98102520746
13.0295974574
13.5698562077
13.8393797686
13.6452246257
13.3908977707
12.7564548369
10.8202294623
0.00118352401133
5.85611230473e-07
1.75007593285e-07
1.1312011919e-07
13.0760620726
2.42968411744
0.00489642650986
0.104616685148
12.5009505431
2.11656745234e-08
5.06664430415e-09
3.60742776462
18.4571223299
20.3836112317
20.9163379463
24.9068859329
37.5653353828
49.281266059
45.721192074
49.9069164356
58.5312100896
64.2952863701
72.1936479749
99.195395252
99.9999986409
100
100
100
100
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
100
100
100
100
100
100
100
100
99.9999999998
97.3373186239
80.9247590851
66.7500353257
55.3506744474
46.6921810107
39.9289610693
34.3183114945
30.0597108555
30.1168528632
28.8951401637
1.49550443999
0.000681441378605
0.107532916674
4.13023699584e-06
14.2138307847
16.0706052774
16.8840493912
16.7515394047
16.9050566836
15.6265139178
14.1186771521
10.0515415322
3.48506885045e-06
1.33260092839e-07
9.23434008345e-08
1.26948973992e-06
0.0009870812691
7.15815364626
14.9957970613
12.4323275352
4.65608189638e-09
9.10620736597e-10
2.08302440083e-10
1.58467825317e-10
1.60731010969e-10
0.0008580354261
4.07075201049
7.17003335709e-08
24.0346158815
31.2238575666
26.3635927759
49.7759375589
44.80267123
61.6385160005
65.8897342718
91.3016646112
99.5848037255
100
100
100
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
5.70861418218e-34
99.8699844708
100
100
100
100
100
100
100
100
98.9769419155
82.0793131318
68.1320697452
56.2876937688
46.7642075044
39.6011935312
33.657131443
28.4443115736
25.2435649735
18.6709198191
1.1258800829
6.31291473509
3.91245979243
8.18527429256e-06
1.05396337621e-07
2.9291273271e-07
0.000329520060891
2.13127995783e-06
1.50358340281e-06
7.97549065922e-07
4.25138676582e-07
2.13447949311e-07
9.25200411631e-08
3.14904648517e-08
1.16188864301e-08
3.2644207789e-09
1.6336102874e-09
1.53123281497e-09
1.11511257281e-09
7.00828854941e-10
4.60729558599e-10
2.74368051421e-10
1.36574287207e-10
7.38519468368e-11
5.9722926674e-11
3.79827447647e-11
1.83574750464e-11
7.66206429524e-12
5.42715710293e-12
1.96877665182e-12
1.77813612511e-12
9.57145942485e-14
2.39455613833e-11
1.74703773491e-16
2.58284048069e-11
1.24166232671e-19
2.10217751191e-10
2.70119253517e-25
1.70763478357e-24
100
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
9.49683513426e-34
100
4.19405252338e-13
100
100
100
100
100
100
100
98.890615171
81.1914309955
67.5554056257
55.9098520352
45.8050921107
37.613805627
31.0189806216
25.8331728443
22.4578376038
12.759275137
)
;
boundaryField
{
frontAndBack
{
type empty;
}
upperWall
{
type calculated;
value uniform 0;
}
lowerWall
{
type calculated;
value uniform 0;
}
inlet
{
type calculated;
value uniform 3.39415914361e-31;
}
outlet
{
type calculated;
value nonuniform List<scalar>
20
(
1.95460987389e-33
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
1.67612797215e-34
3.79923278979e-33
)
;
}
}
// ************************************************************************* //
| |
87772c050b2966873ef5b00fcf6d9826cfd6b805 | 00e69a7bc07b52878fbc43679f83dac715b5c7a9 | /leetcode_solved/[editing]leetcode_1027_Longest_Arithmetic_Sequence.cpp | ab572113872a6d91458b770da635bd8d245c2bc7 | [] | no_license | Ghost-2019/Algorithm | 0589e3017c76d312d26e3433498379e75ad975fd | e4421bf5e900ff5fbe3035456b66bd18f0c30bbe | refs/heads/master | 2022-04-17T00:31:04.963031 | 2020-04-12T06:16:21 | 2020-04-12T06:16:21 | 258,400,595 | 1 | 0 | null | 2020-04-24T03:59:37 | 2020-04-24T03:59:36 | null | UTF-8 | C++ | false | false | 90 | cpp | [editing]leetcode_1027_Longest_Arithmetic_Sequence.cpp | class Solution {
public:
int longestArithSeqLength(vector<int>& A) {
}
}; |
4d664ceb8c997fde4e7d0dbb7bff662807fd84b4 | b402a453d76f2b70ed5bb840025ce7d5bc3f0489 | /Fruta.h | 78bab4e749145277e880cdc175a621249778ec1c | [] | no_license | MAndresSL/Mario_Sanchez_Examen2 | 7aa42bec3c2fe099d898cc2d3472b4dce0c7c4e8 | deabe4f3d339a39d75d4ba679ebe7e291b2e83b4 | refs/heads/master | 2021-06-13T13:42:45.421227 | 2017-03-25T01:10:04 | 2017-03-25T01:10:04 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 218 | h | Fruta.h | #pragma once
#include <string>
using namespace std;
class Fruta {
protected:
string nombre;
public:
Fruta ();
Fruta(string);
void setNombre(string);
string getNombre();
virtual ~Fruta ();
};
|
2166e82627771f1688f1ee3decd86ea3e920d5b7 | b22588340d7925b614a735bbbde1b351ad657ffc | /athena/InnerDetector/InDetConditions/PixelConditionsServices/src/PixelConditionsSummarySvc.h | 8678534dee6ca9ef21523b38c50f69b6f764fdd5 | [] | no_license | rushioda/PIXELVALID_athena | 90befe12042c1249cbb3655dde1428bb9b9a42ce | 22df23187ef85e9c3120122c8375ea0e7d8ea440 | refs/heads/master | 2020-12-14T22:01:15.365949 | 2020-01-19T03:59:35 | 2020-01-19T03:59:35 | 234,836,993 | 1 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 3,060 | h | PixelConditionsSummarySvc.h | /*
Copyright (C) 2002-2017 CERN for the benefit of the ATLAS collaboration
*/
#ifndef PIXELCONDITIONSSERVICES_PIXELCONDITIONSSUMMARYSVC_H
#define PIXELCONDITIONSSERVICES_PIXELCONDITIONSSUMMARYSVC_H
#include <string>
#include "AthenaBaseComps/AthService.h"
#include "GaudiKernel/ServiceHandle.h"
#include "AthenaKernel/IOVSvcDefs.h"
#include "InDetConditionsSummaryService/IInDetConditionsSvc.h"
#include "InDetConditionsSummaryService/InDetHierarchy.h"
class Identifier;
class IdentifierHash;
class PixelID;
class IPixelDCSSvc;
class IPixelByteStreamErrorsSvc;
class ISpecialPixelMapSvc;
class DetectorSpecialPixelMap;
class StoreGateSvc;
class IPixelTDAQSvc;
class IBLParameterSvc;
/**
* Returns the status of pixel modules, frontends or single pixels
* as determined by the PixelDCSSvc, PixelByteStreamErrorsSvc and SpecialPixelMapSvc.
*
* ruwiedel@physik.uni-bonn.de
*
*/
class PixelConditionsSummarySvc: public AthService, virtual public IInDetConditionsSvc{
public:
static const InterfaceID& interfaceID();
PixelConditionsSummarySvc(const std::string& name, ISvcLocator* sl);
virtual ~PixelConditionsSummarySvc();
virtual StatusCode initialize();
virtual StatusCode finalize();
virtual StatusCode queryInterface(const InterfaceID& riid, void** ppvIf);
virtual bool isActive(const Identifier & elementId, const InDetConditions::Hierarchy h=InDetConditions::DEFAULT);
virtual bool isActive(const IdentifierHash & elementHash);
virtual bool isActive(const IdentifierHash & elementHash, const Identifier & elementId);
virtual double activeFraction(const IdentifierHash & elementHash, const Identifier & idStart, const Identifier & idEnd);
virtual bool isGood(const Identifier & elementId, const InDetConditions::Hierarchy h=InDetConditions::DEFAULT);
virtual bool isGood(const IdentifierHash & elementHash);
virtual bool isGood(const IdentifierHash & elementHash, const Identifier & elementId);
virtual double goodFraction(const IdentifierHash & elementHash, const Identifier & idStart, const Identifier & idEnd);
virtual StatusCode specialPixelMapCallBack(IOVSVC_CALLBACK_ARGS);
private:
ServiceHandle< StoreGateSvc > m_detStore;
const PixelID* m_pixelID;
std::string m_specialPixelMapKey;
const DetectorSpecialPixelMap* m_specialPixelMap;
ServiceHandle< ISpecialPixelMapSvc > m_specialPixelMapSvc;
ServiceHandle< IPixelDCSSvc > m_pixelDCSSvc;
ServiceHandle< IBLParameterSvc> m_IBLParameterSvc;
ServiceHandle< IPixelByteStreamErrorsSvc > m_pixelBSErrorsSvc;
ServiceHandle< IPixelTDAQSvc > m_pixelTDAQSvc;
std::vector<std::string> m_isActiveStatus;
std::vector<std::string> m_isActiveStates;
bool m_useSpecialPixelMap;
bool m_useDCS;
bool m_useBS;
bool m_useTDAQ;
void getID(const Identifier& id, unsigned int& pixID, unsigned int& mchips) const;
};
inline const InterfaceID& PixelConditionsSummarySvc::interfaceID(){
static const InterfaceID IID_PixelConditionsSummarySvc("PixelConditionsSummarySvc", 1, 0);
return IID_PixelConditionsSummarySvc;
}
#endif
|
a095bbfe9c293eb972a7359c44ac55395d2fcfc6 | 7da0b2806dc4471b472128d5e4e3aba49d9c01e0 | /src/cc/Books/ElementsOfProgrammingInterviews/ch13.cpp | 497d9861f0b608c32774dd1289492e35de63a68d | [
"MIT"
] | permissive | nuggetwheat/study | f0ac18653259c774a46bf39377b0b02f5bac5e4e | 1e438a995c3c6ce783af9ae6a537c349afeedbb8 | refs/heads/master | 2020-04-05T22:51:53.513159 | 2016-02-18T12:23:55 | 2016-02-19T22:14:39 | 34,771,855 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 1,066 | cpp | ch13.cpp |
#include "ch13.hpp"
#include "reference/ch13.hpp"
#include <algorithm>
#include <cassert>
#include <cctype>
#include <cstdlib>
#include <deque>
#include <fstream>
#include <iostream>
#include <istream>
#include <map>
#include <queue>
#include <random>
#include <sstream>
#include <stack>
#include <stdexcept>
#include <string>
#include <unordered_map>
#include <unordered_set>
#include <utility>
#include <vector>
extern "C" {
#include <math.h>
}
using namespace std;
namespace study {
vector<vector<string>> FindAnagrams(const vector<string> &dictionary) {
return reference::FindAnagrams(dictionary);
}
bool CanFormPalindrome(const std::string &word) {
return reference::CanFormPalindrome(word);
}
BSTNode<int> *LCA_optimized(const std::unique_ptr<BSTNode<int>> &node0,
const std::unique_ptr<BSTNode<int>> &node1) {
return reference::LCA_optimized(node0, node1);
}
int FindNearestRepetition(const std::vector<std::string> ¶graph) {
return reference::FindNearestRepetition(paragraph);
}
}
|
e12967b122ce4af3a2d7f50a407a89f6adb2a7bb | c05625d21c7e4922fd25b28677693abfff48b288 | /framework/sandstone_test_groups.cpp | 80109c7a486b6b6b3ec48d31b988ce008c38b9c6 | [
"LicenseRef-scancode-unknown-license-reference",
"Apache-2.0",
"BSD-3-Clause",
"MIT"
] | permissive | dldaley/opendcdiag | 75cc3cbeb0d9507f35d5108d8dfc1294dee1e261 | 1bd4668f024929d5bcf81cbcb6048453676c2fb4 | refs/heads/main | 2023-08-24T03:06:13.477690 | 2021-10-29T21:37:50 | 2021-10-29T21:37:50 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 672 | cpp | sandstone_test_groups.cpp | /*
* SPDX-License-Identifier: Apache-2.0
*/
#include "sandstone_p.h"
#if SANDSTONE_RESTRICTED_CMDLINE
# define TEST_GROUP(name, descr) .id = nullptr, .description = nullptr
#else
# define TEST_GROUP(name, descr) .id = name, .description = descr
#endif
__attribute__((section("test_group"), aligned(8)))
extern constexpr struct test_group group_compression = {
TEST_GROUP("compression",
"Tests that drive compression routines in various libraries"),
};
__attribute__((section("test_group"), aligned(8)))
extern constexpr struct test_group group_math = {
TEST_GROUP("math",
"Tests that perform math using, e.g., Eigen"),
};
|
5d344082f688ebd0453b6340cf64480fc6d0754b | 06a9ffa75f998f7bc7b7978d9c1a1a9a68036f6e | /src/image_selector.cpp | e3168e1675c14c84d2005fc7075b94d0bd62e50f | [] | no_license | wvu-navLab/SRC2-ImageSelector | 0c76b0a52e11145582e5b9b3989ed48afbdd55a7 | 99e5a227aa5d56ed4e3b008f7eed0f699d115a36 | refs/heads/master | 2023-05-31T03:33:02.060287 | 2021-06-07T18:05:20 | 2021-06-07T18:05:20 | 265,283,624 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 2,434 | cpp | image_selector.cpp | #include <ros/ros.h>
#include <image_transport/image_transport.h>
#include <opencv2/highgui/highgui.hpp>
#include <cv_bridge/cv_bridge.h>
//#define SHOWIMAGES
class ImageSelector
{
ros::NodeHandle nh;
image_transport::ImageTransport it;
image_transport::CameraSubscriber sub;
image_transport::CameraPublisher pub;
public:
ImageSelector(): it(nh)
{
sub = it.subscribeCamera("camera/image_raw", 1, &ImageSelector::imageCallback, this);
pub = it.advertiseCamera("camera/sel/image_raw", 1);
#ifdef SHOWIMAGES
cv::namedWindow("original");
cv::namedWindow("edges");
cv::namedWindow("noiseless");
cv::startWindowThread();
#endif
}
void imageCallback(const sensor_msgs::ImageConstPtr& msg, const sensor_msgs::CameraInfoConstPtr& info_msg)
{
cv_bridge::CvImagePtr cv_ptr;
try
{
cv_ptr = cv_bridge::toCvCopy(msg, sensor_msgs::image_encodings::BGR8);
}
catch (cv_bridge::Exception& e)
{
ROS_ERROR("cv_bridge exception: %s", e.what());
return;
}
cv::Mat edges;
cv::Canny(cv_ptr->image, edges, 50, 100);
std::vector<cv::Vec4i> lines;
cv::HoughLinesP(edges, lines, 1, CV_PI/180, 25, 25, 10); // Detect lines
int count=0;
if (lines.size() > 1000) // Lots of lines indicate a high noise
count=500;
else // Looks for horizontal lines close to the borders
for (size_t i=0; i<lines.size(); i++) {
cv::Vec4i l = lines[i];
cv::Point a(l[0], l[1]);
cv::Point b(l[2], l[3]);
//line(cv_ptr->image, a, b, cv::Scalar(255, 0, 0), 3, cv::LINE_AA);
float slope=float(float(b.y - a.y) / float(b.x - a.x));
//ROS_INFO("%f %d %d %d %d", slope, a.x, a.y, b.x, b.y);
if ((fabs(slope) < 0.0001) && ((a.x<10) || b.x > 630)) // horizontal lines that start at righ borders or finish at the left border
count++;
}
#ifdef SHOWIMAGES
cv::imshow("original", cv_ptr->image);
cv::imshow("edges", edges);
#endif
if ((count<1)){
#ifdef SHOWIMAGES
cv::imshow("noiseless", cv_ptr->image);
#endif
pub.publish(msg, info_msg);
}
}
}; // class ImageSelector
int main(int argc, char **argv)
{
ros::init(argc, argv, "image_listener");
ImageSelector IS;
ros::spin();
cv::destroyWindow("view");
}
|
fe64a12a545434cae6459c098b40330b11263dde | e5df7e13ce208c75822f4796a2e668a0b4d30ffc | /MyEngine/SourceEditor/Editor_ImGui/EditorMainFrame_ImGui.cpp | 9585dea4ce69d7967242bab4a44889268cc8269a | [] | no_license | JimmyLord/MyEngine | 84db4f981c454339e688b320245c137996f751e1 | 5a0d3f075102a4afcffb8628f5fc7b6c3bad30c0 | refs/heads/master | 2023-02-19T15:50:02.745008 | 2023-02-13T14:35:20 | 2023-02-13T14:35:20 | 26,408,862 | 2 | 1 | null | 2019-05-15T20:51:29 | 2014-11-09T20:55:33 | C++ | UTF-8 | C++ | false | false | 203,353 | cpp | EditorMainFrame_ImGui.cpp | //
// Copyright (c) 2018-2019 Jimmy Lord http://www.flatheadgames.com
//
// This software is provided 'as-is', without any express or implied warranty. In no event will the authors be held liable for any damages arising from the use of this software.
// Permission is granted to anyone to use this software for any purpose, including commercial applications, and to alter it and redistribute it freely, subject to the following restrictions:
// 1. The origin of this software must not be misrepresented; you must not claim that you wrote the original software. If you use this software in a product, an acknowledgment in the product documentation would be appreciated but is not required.
// 2. Altered source versions must be plainly marked as such, and must not be misrepresented as being the original software.
// 3. This notice may not be removed or altered from any source distribution.
#include "MyEnginePCH.h"
#include "EditorMemoryWindow_ImGui.h"
#include "ImGuiStylePrefs.h"
#include "ComponentSystem/BaseComponents/ComponentCamera.h"
#include "ComponentSystem/BaseComponents/ComponentTransform.h"
#include "ComponentSystem/Core/GameObject.h"
#include "ComponentSystem/FrameworkComponents/ComponentAnimationPlayer2D.h"
#include "ComponentSystem/FrameworkComponents/ComponentAudioPlayer.h"
#include "ComponentSystem/FrameworkComponents/ComponentMeshOBJ.h"
#include "Core/EngineComponentTypeManager.h"
#include "Core/EngineCore.h"
#include "GUI/EditorIcons.h"
#include "GUI/ImGuiExtensions.h"
#if MYFW_USING_MONO
#include "Mono/MonoGameState.h"
#endif
#include "../SourceEditor/EditorState.h"
#include "../SourceEditor/Commands/EditorMenuCommands.h"
#include "../SourceEditor/Commands/EngineCommandStack.h"
#include "../SourceEditor/Commands/EngineEditorCommands.h"
#include "../SourceEditor/Documents/EditorDocument.h"
#include "../SourceEditor/Documents/EditorDocumentManager.h"
#include "../SourceEditor/Editor_ImGui/EditorLayoutManager_ImGui.h"
#include "../SourceEditor/Editor_ImGui/EditorLogWindow_ImGui.h"
#include "../SourceEditor/Editor_ImGui/EditorMainFrame_ImGui.h"
#include "../SourceEditor/GameObjectTemplateManager.h"
#include "../SourceEditor/Interfaces/EditorInterface.h"
#include "../SourceEditor/NodeGraph/MyNodeGraph.h"
#include "../SourceEditor/NodeGraph/VisualScriptNodes.h"
#include "../SourceEditor/Prefs/EditorKeyBindings.h"
#include "../SourceEditor/TransformGizmo.h"
//====================================================================================================
// Various enums and matching strings (some unused)
//====================================================================================================
const char* g_DefaultEditorWindowTypeMenuLabels[EditorWindow_NumTypes] =
{
"Game View",
"Editor View",
"Object List",
"Watch",
"Resources",
"Log",
"Grid Settings",
"Material Editor",
"2D Animation Editor",
"Debug: Mouse Picker",
"Debug: Stuff",
"Debug: Memory Allocations",
"Debug: Undo/Redo Stacks",
"Debug: ImGui Demo",
};
enum PanelMemoryPages
{
PanelMemoryPage_Materials,
PanelMemoryPage_Textures,
PanelMemoryPage_ShaderGroups,
PanelMemoryPage_SoundCues,
PanelMemoryPage_Files,
PanelMemoryPage_Buffers,
PanelMemoryPage_DrawCalls,
PanelMemoryPage_NumTypes
};
const char* g_PanelMemoryPagesMenuLabels[PanelMemoryPage_NumTypes] =
{
"Materials",
"Textures",
"Shaders",
"Sound Cues",
"Files",
"Buffers",
"Draw Calls",
};
//====================================================================================================
// Public methods
//====================================================================================================
EditorMainFrame_ImGui::EditorMainFrame_ImGui(EngineCore* pEngineCore)
{
m_pEngineCore = pEngineCore;
// Documents.
m_pActiveDocument = nullptr;
m_pLastActiveDocument = nullptr;
// Layouts.
m_pLayoutManager = MyNew EditorLayoutManager_ImGui( this );
m_pCurrentLayout = nullptr;
// Warnings.
m_ShowWarning_NewScene = false;
m_ShowWarning_LoadScene = false;
m_ShowWarning_CloseDocument = false;
m_DocumentIndexToCloseAfterWarning = -1;
m_ShowWarning_CloseEditor = false;
// Main Dock Node
m_CentralNodeDockID = 0;
// Render surfaces.
m_pGameFBO = m_pEngineCore->GetManagers()->GetTextureManager()->CreateFBO( 1024, 1024, MyRE::MinFilter_Nearest, MyRE::MagFilter_Nearest, FBODefinition::FBOColorFormat_RGBA_UByte, 32, true );
m_pEditorFBO = m_pEngineCore->GetManagers()->GetTextureManager()->CreateFBO( 1024, 1024, MyRE::MinFilter_Nearest, MyRE::MagFilter_Nearest, FBODefinition::FBOColorFormat_RGBA_UByte, 32, true );
m_pMaterialPreviewFBO = m_pEngineCore->GetManagers()->GetTextureManager()->CreateFBO( 1024, 1024, MyRE::MinFilter_Nearest, MyRE::MagFilter_Nearest, FBODefinition::FBOColorFormat_RGBA_UByte, 32, true );
#if MYFW_EDITOR
m_pGameFBO->MemoryPanel_Hide();
m_pEditorFBO->MemoryPanel_Hide();
m_pMaterialPreviewFBO->MemoryPanel_Hide();
#endif
// Material Preview and Editor.
m_pMaterialToPreview = nullptr;
m_pMaterialBeingEdited = nullptr;
// 2D Animation Editor.
m_FullPathToLast2DAnimInfoBeingEdited[0] = '\0';
m_p2DAnimInfoBeingEdited = nullptr;
m_Current2DAnimationIndex = 0;
m_pAnimPlayerComponent = MyNew ComponentAnimationPlayer2D( pEngineCore, pEngineCore->GetComponentSystemManager() );
m_pAnimPlayerComponent->SetType( ComponentType_AnimationPlayer2D );
m_pAnimPlayerComponent->SetSceneID( SCENEID_AllScenes );
// Log Window.
m_pLogWindow = MyNew EditorLogWindow_ImGui( m_pEngineCore, true );
m_pMemoryWindow = MyNew EditorMemoryWindow_ImGui();
// Object list.
m_pGameObjectToDrawReorderLineAfter = nullptr;
m_SetObjectListFilterBoxInFocus = false;
m_ObjectListFilter[0] = '\0';
// Memory panel.
m_CurrentMemoryPanelPage = PanelMemoryPage_Materials;
m_SetMemoryPanelFilterBoxInFocus = false;
m_MemoryPanelFilter[0] = '\0';
// For renaming things.
m_RenamePressedThisFrame = false;
m_ConfirmCurrentRenameOp = false;
m_RenameTimerForSlowDoubleClick = 0.0f;
m_RenameOp_LastObjectClicked = nullptr;
m_pGameObjectWhoseNameIsBeingEdited = nullptr;
m_pMaterialWhoseNameIsBeingEdited = nullptr;
m_NameBeingEdited[0] = '\0';
// Draw call debugger.
m_SelectedDrawCallCanvas = -1;
m_SelectedDrawCallIndex = -1;
// Game and Editor windows.
m_GameWindowPos.Set( -1, -1 );
m_EditorWindowPos.Set( -1, -1 );
m_GameWindowSize.Set( 0, 0 );
m_EditorWindowSize.Set( 0, 0 );
m_GameWindowFocused = false;
m_GameWindowVisible = false;
m_EditorWindowHovered = false;
m_EditorWindowFocused = false;
m_EditorWindowVisible = false;
m_CurrentMouseInEditorWindow_X = -1;
m_CurrentMouseInEditorWindow_Y = -1;
// Misc.
m_pLastGameObjectInteractedWithInObjectPanel = nullptr;
m_UndoStackDepthAtLastSave = 0;
// Modifier key states.
m_KeyDownCtrl = false;
m_KeyDownAlt = false;
m_KeyDownShift = false;
m_KeyDownCommand = false;
// Master Undo/Redo Stack for ImGui editor builds.
m_pCommandStack = MyNew EngineCommandStack();
m_pEngineCore->SetCommandStack( m_pCommandStack );
}
EditorMainFrame_ImGui::~EditorMainFrame_ImGui()
{
m_pAnimPlayerComponent->SetEnabled( false );
SAFE_DELETE( m_pAnimPlayerComponent );
SAFE_DELETE( m_pCommandStack );
m_pEngineCore->SetCommandStack( nullptr );
SAFE_DELETE( m_pLogWindow );
SAFE_DELETE( m_pMemoryWindow );
SAFE_RELEASE( m_pGameFBO );
SAFE_RELEASE( m_pEditorFBO );
SAFE_RELEASE( m_pMaterialPreviewFBO );
delete m_pLayoutManager;
}
Vector2 EditorMainFrame_ImGui::GetEditorWindowCenterPosition()
{
return m_EditorWindowPos + m_EditorWindowSize/2;
}
void EditorMainFrame_ImGui::StoreCurrentUndoStackSize()
{
m_UndoStackDepthAtLastSave = m_pCommandStack->GetUndoStackSize();
}
bool EditorMainFrame_ImGui::HandleInput(int keyAction, int keyCode, int mouseAction, int id, float x, float y, float pressure)
{
ImGuiIO& io = ImGui::GetIO();
if( keyAction == GCBA_Down )
{
if( keyCode == MYKEYCODE_LCTRL || keyCode == MYKEYCODE_RCTRL )
m_KeyDownCtrl = true;
if( keyCode == MYKEYCODE_LALT || keyCode == MYKEYCODE_RALT )
m_KeyDownAlt = true;
if( keyCode == MYKEYCODE_LSHIFT || keyCode == MYKEYCODE_RSHIFT )
m_KeyDownShift = true;
}
if( keyAction == GCBA_Up )
{
if( keyCode == MYKEYCODE_LCTRL || keyCode == MYKEYCODE_RCTRL )
m_KeyDownCtrl = false;
if( keyCode == MYKEYCODE_LALT || keyCode == MYKEYCODE_RALT )
m_KeyDownAlt = false;
if( keyCode == MYKEYCODE_LSHIFT || keyCode == MYKEYCODE_RSHIFT )
m_KeyDownShift = false;
}
if( mouseAction == GCBA_Down && id == 0 )
{
// For renaming, if the mouse is clicked anywhere, end/confirm the current rename operation.
if( m_pGameObjectWhoseNameIsBeingEdited || m_pMaterialWhoseNameIsBeingEdited )
{
m_ConfirmCurrentRenameOp = true;
}
// When binding new keys, if the mouse is clicked anywhere, cancel the operation.
EditorKeyBindings* pKeyBindings = m_pEngineCore->GetEditorPrefs()->GetKeyBindings();
pKeyBindings->CancelBindingAction();
}
// For keyboard and other non-mouse events, localx/y will be -1.
float localx = -1;
float localy = -1;
if( mouseAction == GCBA_RelativeMovement )
{
// localx/y will hold relative movement in this case.
localx = x;
localy = y;
}
// Read the absolute x/y from the ImGui structure, since non-mouse messages will have x,y of -1,-1.
float mouseabsx = io.MousePos.x;
float mouseabsy = io.MousePos.y;
// Deal with sending input events to the active document.
for( uint32 i=0; i<m_pEngineCore->GetEditorState()->m_pOpenDocuments.size(); i++ )
{
EditorDocument* pDocument = m_pEngineCore->GetEditorState()->m_pOpenDocuments[i];
if( pDocument->IsWindowVisible() )
{
// If the right or middle mouse buttons were clicked on this window, set it as having focus.
// Needed since those buttons don't focus ImGui window directly.
if( pDocument->IsWindowHovered() && mouseAction == GCBA_Down && id != 0 )
{
const uint32 tempTitleAllocationSize = MAX_PATH*2+5;
static char tempTitle[tempTitleAllocationSize];
pDocument->GetWindowTitle( tempTitle, tempTitleAllocationSize );
ImGui::SetWindowFocus( tempTitle );
}
// Always send keyboard actions to window in focus, only send mouse messages if in focus and hovered.
// Pass keyboard and mouse events to the editor under various conditions.
if( ( pDocument->IsWindowFocused() && keyAction != -1 ) ||
( pDocument->IsWindowFocused() && (mouseAction == GCBA_Up || mouseAction == GCBA_Held || mouseAction == GCBA_RelativeMovement) ) ||
( pDocument->IsWindowHovered() )
)
{
Vector2 pos = pDocument->GetWindowPosition();
Vector2 size = pDocument->GetWindowSize();
// If this is an absolute mouse input over the document window.
if( ( mouseAction != -1 && mouseAction != GCBA_RelativeMovement &&
mouseabsx >= pos.x && mouseabsx < pos.x + size.x &&
mouseabsy >= pos.y && mouseabsy < pos.y + size.y ) )
{
// Calculate mouse x/y relative to this window.
localx = x - pos.x;
localy = size.y - (y - pos.y);
}
// Set modifier key and mouse button states.
m_pEngineCore->GetEditorState()->SetModifierKeyStates( keyAction, keyCode, mouseAction, id, localx, localy, pressure );
//LOGInfo( "Mouse Bug", "Document Set: %0.0f, %0.0f", localx, localy );
if( pDocument->HandleInput( keyAction, keyCode, mouseAction, id, localx, localy, pressure ) )
{
return true;
}
// Clear modifier key and mouse button states.
m_pEngineCore->GetEditorState()->ClearModifierKeyStates( keyAction, keyCode, mouseAction, id, localx, localy, pressure );
//LOGInfo( "Mouse Bug", "Document Clear: %0.0f, %0.0f", localx, localy );
}
}
}
// Deal with sending input events to the game window.
{
// If this is a keyAction and the game window is in focus.
if( keyAction != -1 && m_GameWindowFocused )
{
// Check for Ctrl-Space keypress while the game is running and in focus to return to editor mode.
// TODO: Set this as an option, since some games might actually want to use the ctrl-space combination.
if( m_KeyDownCtrl && keyCode == ' ' && keyAction == GCBA_Down )
{
EditorMenuCommand( EditorMenuCommand_Mode_TogglePlayStop );
return true;
}
return false; // Let event continue to the game window.
}
// If this is an absolute mouse input over the game window.
if( ( mouseAction != -1 && mouseAction != GCBA_RelativeMovement &&
mouseabsx >= m_GameWindowPos.x && mouseabsx < m_GameWindowPos.x + m_GameWindowSize.x &&
mouseabsy >= m_GameWindowPos.y && mouseabsy < m_GameWindowPos.y + m_GameWindowSize.y ) )
{
// Calculate mouse x/y relative to this window.
localx = x - m_GameWindowPos.x;
localy = y - m_GameWindowPos.y;
if( mouseAction == GCBA_Down )
m_GameWindowFocused = true;
m_pEngineCore->OnTouchGameWindow( mouseAction, id, localx, localy, pressure, 1 );
// Input was used.
return true;
}
// Pass relative x/y to the game window if it's in focus.
if( mouseAction == GCBA_RelativeMovement && m_GameWindowFocused )
{
m_pEngineCore->OnTouchGameWindow( mouseAction, id, localx, localy, pressure, 1 );
// Input was used.
return true;
}
}
// Deal with sending input events to the editor window.
if( io.WantTextInput == false )
{
// Pass keyboard and mouse events to the editor under various conditions.
if( ( m_EditorWindowFocused && keyAction != -1 ) ||
( m_EditorWindowFocused && (mouseAction == GCBA_Up || mouseAction == GCBA_Held || mouseAction == GCBA_RelativeMovement) ) ||
( m_EditorWindowHovered )
)
{
// If this is a mouse message and not a relative movement,
// calculate mouse x/y relative to this window.
if( mouseAction != -1 && mouseAction != GCBA_RelativeMovement )
{
localx = x - m_EditorWindowPos.x;
localy = m_EditorWindowSize.y - (y - m_EditorWindowPos.y);
}
// Set modifier key and mouse button states.
m_pEngineCore->GetEditorState()->SetModifierKeyStates( keyAction, keyCode, mouseAction, id, localx, localy, pressure );
//LOGInfo( "Mouse Bug", "Editor Set: %0.0f, %0.0f", localx, localy );
m_CurrentMouseInEditorWindow_X = (unsigned int)localx;
m_CurrentMouseInEditorWindow_Y = (unsigned int)localy;
// If the right or middle mouse buttons were clicked on this window, set it as having focus.
// Needed since those buttons don't focus ImGui window directly.
if( mouseAction == GCBA_Down && id != 0 )
{
ImGui::SetWindowFocus( "Editor" );
}
// First, pass the input into the current editor interface.
if( m_pEngineCore->GetCurrentEditorInterface()->HandleInput( keyAction, keyCode, mouseAction, id, localx, localy, pressure ) )
return true;
// If it wasn't used, pass it to the transform gizmo.
if( m_pEngineCore->GetEditorState()->m_pTransformGizmo->HandleInput( m_pEngineCore, -1, -1, mouseAction, id, localx, localy, pressure ) )
return true;
// Clear modifier key and mouse button states.
m_pEngineCore->GetEditorState()->ClearModifierKeyStates( keyAction, keyCode, mouseAction, id, localx, localy, pressure );
//LOGInfo( "Mouse Bug", "Editor Clear: %0.0f, %0.0f", localx, localy );
}
}
// If neither the game or editor windows used the input, then check for global hotkeys or cancel certain ops.
if( keyAction != -1 )
{
EditorKeyBindings* pKeyBindings = m_pEngineCore->GetEditorPrefs()->GetKeyBindings();
// EditorKeyBindings will catch this input and change a hotkey if it's waiting to register one.
if( pKeyBindings->HandleInput( keyAction, keyCode ) )
{
// If a hotkey was pressed, unset that key so 'held' and 'up' messages won't get sent.
m_pEngineCore->ForceKeyRelease( keyCode );
return true;
}
else if( io.WantTextInput == false )
{
if( CheckForHotkeys( keyAction, keyCode ) )
{
// If a hotkey was pressed, unset that key so 'held' and 'up' messages won't get sent.
m_pEngineCore->ForceKeyRelease( keyCode );
return true;
}
}
else
{
// Cancel rename operation if an ImGui input box has focus and escape is pressed.
if( keyCode == MYKEYCODE_ESC )
{
m_pGameObjectWhoseNameIsBeingEdited = nullptr;
m_pMaterialWhoseNameIsBeingEdited = nullptr;
return true;
}
}
// Cancel any drag/drop ops when escape is pressed.
if( keyCode == MYKEYCODE_ESC )
{
ImGuiExt::ClearDragDrop();
}
}
// Absorb the message, even if we didn't do anything with it.
return true;
}
bool EditorMainFrame_ImGui::CheckForHotkeys(int keyAction, int keyCode)
{
if( keyAction == GCBA_Down )
{
bool N = !m_KeyDownCtrl && !m_KeyDownAlt && !m_KeyDownShift && !m_KeyDownCommand; // No modifiers held
bool C = m_KeyDownCtrl && !m_KeyDownAlt && !m_KeyDownShift && !m_KeyDownCommand; // Ctrl
bool A = !m_KeyDownCtrl && m_KeyDownAlt && !m_KeyDownShift && !m_KeyDownCommand; // Alt
bool S = !m_KeyDownCtrl && !m_KeyDownAlt && m_KeyDownShift && !m_KeyDownCommand; // Shift
bool CS = m_KeyDownCtrl && !m_KeyDownAlt && m_KeyDownShift && !m_KeyDownCommand; // Ctrl-Shift
// Handle GameObject renaming, not the best idea to do this here, but okay for a start.
// TODO: Check if F2 or Enter was pressed when menuitem has focus.
if( N && keyCode == VK_F2 || N && keyCode == MYKEYCODE_ENTER )
{
m_RenamePressedThisFrame = true;
m_ConfirmCurrentRenameOp = false;
return true;
}
if( N && keyCode == MYKEYCODE_DELETE )
{
m_pEngineCore->GetEditorState()->DeleteSelectedObjects();
return true;
}
EditorPrefs* pEditorPrefs = m_pEngineCore->GetEditorPrefs();
EditorKeyBindings* pKeys = m_pEngineCore->GetEditorPrefs()->GetKeyBindings();
uint8 modifiers = static_cast<uint8>( m_pEngineCore->GetEditorState()->m_ModifierKeyStates );
// Check all hotkeys and execute their actions if required.
for( int i=0; i<(int)HotkeyAction::Num; i++ )
{
HotkeyAction action = static_cast<HotkeyAction>( i );
// Check if this is a global hotkey.
if( pKeys->KeyMatches( action, pKeys->GetModifiersHeld(), keyCode ) )
{
if( ExecuteHotkeyAction( action ) )
{
return true;
}
}
else if( m_pActiveDocument )
{
if( pKeys->KeyMatches( action, pKeys->GetModifiersHeld(), keyCode, m_pActiveDocument->GetHotkeyContext() ) )
{
if( m_pActiveDocument->ExecuteHotkeyAction( action ) )
{
return true;
}
}
}
else
{
//HotkeyContext context = m_pEngineCore->GetCurrentEditorInterface()->GetHotkeyContext();
//if( pKeys->KeyMatches( action, pKeys->GetModifiersHeld(), keyCode, context ) )
//{
// if( m_pEngineCore->GetCurrentEditorInterface()->ExecuteHotkeyAction( action ) )
// {
// return true;
// }
//}
}
}
#if _DEBUG
// Dump current layout to output window, so it can be cut & pasted to g_DefaultLayouts in the EditorLayoutManager.
if( CS && keyCode == 'D' ) { m_pLayoutManager->DumpCurrentLayoutToOutputWindow(); return true; }
#endif
}
return false;
}
bool EditorMainFrame_ImGui::ExecuteHotkeyAction(HotkeyAction action)
{
EditorPrefs* pEditorPrefs = m_pEngineCore->GetEditorPrefs();
switch( action )
{
case HotkeyAction::Global_Find: { ImGui::SetWindowFocus( "Objects" ); m_SetObjectListFilterBoxInFocus = true; return true; }
case HotkeyAction::File_SaveScene: { EditorMenuCommand( EditorMenuCommand_File_SaveScene ); return true; }
case HotkeyAction::File_SaveAll: { EditorMenuCommand( EditorMenuCommand_File_SaveAll ); return true; }
#if MYFW_USING_BOX2D
case HotkeyAction::File_ExportBox2D: { EditorMenuCommand( EditorMenuCommand_File_Export_Box2DScene ); return true; }
#endif
case HotkeyAction::File_Preferences: { pEditorPrefs->Display(); return true; }
case HotkeyAction::Edit_Undo: { EditorMenuCommand( EditorMenuCommand_Edit_Undo ); return true; }
case HotkeyAction::Edit_Redo: { EditorMenuCommand( EditorMenuCommand_Edit_Redo ); return true; }
case HotkeyAction::View_ShowEditorCamProperties: { EditorMenuCommand( EditorMenuCommand_View_ShowEditorCamProperties ); return true; }
case HotkeyAction::View_ShowEditorIcons: { EditorMenuCommand( EditorMenuCommand_View_ShowEditorIcons ); return true; }
case HotkeyAction::View_ToggleEditorCamDeferred: { EditorMenuCommand( EditorMenuCommand_View_ToggleEditorCamDeferred ); return true; }
case HotkeyAction::View_Full: { pEditorPrefs->Set_Aspect_GameAspectRatio( GLView_Full ); return true; }
case HotkeyAction::View_Tall: { pEditorPrefs->Set_Aspect_GameAspectRatio( GLView_Tall ); return true; }
case HotkeyAction::View_Square: { pEditorPrefs->Set_Aspect_GameAspectRatio( GLView_Square ); return true; }
case HotkeyAction::View_Wide: { pEditorPrefs->Set_Aspect_GameAspectRatio( GLView_Wide ); return true; }
case HotkeyAction::Grid_Visible: { EditorMenuCommand( EditorMenuCommand_Grid_Visible ); return true; }
case HotkeyAction::Grid_SnapEnabled: { EditorMenuCommand( EditorMenuCommand_Grid_SnapEnabled ); return true; }
case HotkeyAction::Grid_Settings: { m_pCurrentLayout->m_IsWindowOpen[EditorWindow_GridSettings] = true; return true; }
case HotkeyAction::Mode_TogglePlayStop: { EditorMenuCommand( EditorMenuCommand_Mode_TogglePlayStop ); return true; }
case HotkeyAction::Mode_Pause: { EditorMenuCommand( EditorMenuCommand_Mode_Pause ); return true; }
case HotkeyAction::Mode_AdvanceOneFrame: { EditorMenuCommand( EditorMenuCommand_Mode_AdvanceOneFrame ); return true; }
case HotkeyAction::Mode_AdvanceOneSecond: { EditorMenuCommand( EditorMenuCommand_Mode_AdvanceOneSecond ); return true; }
case HotkeyAction::Mode_LaunchGame: { EditorMenuCommand( EditorMenuCommand_Mode_LaunchGame ); return true; }
case HotkeyAction::Debug_DrawWireframe: { EditorMenuCommand( EditorMenuCommand_Debug_DrawWireframe ); return true; }
case HotkeyAction::Debug_ShowPhysicsShapes: { EditorMenuCommand( EditorMenuCommand_Debug_ShowPhysicsShapes ); return true; }
case HotkeyAction::Debug_ShowStats: { EditorMenuCommand( EditorMenuCommand_Debug_ShowStats ); return true; }
case HotkeyAction::Lua_RunLuaScript: { EditorMenuCommand( EditorMenuCommand_Lua_RunLuaScript ); return true; }
case HotkeyAction::Objects_MergeIntoFolder: { EditorMenuCommand( EditorMenuCommand_Objects_MergeIntoFolder ); return true; }
// Handled elsewhere, and will return false so the key states won't be affected.
case HotkeyAction::Camera_Forward: { return false; }
case HotkeyAction::Camera_Back: { return false; }
case HotkeyAction::Camera_Left: { return false; }
case HotkeyAction::Camera_Right: { return false; }
case HotkeyAction::Camera_Up: { return false; }
case HotkeyAction::Camera_Down: { return false; }
case HotkeyAction::Camera_Focus: { return false; }
case HotkeyAction::HeightmapEditor_Tool_Raise: { return false; }
case HotkeyAction::HeightmapEditor_Tool_Lower: { return false; }
case HotkeyAction::HeightmapEditor_Tool_Level: { return false; }
case HotkeyAction::Num:
break;
}
return false;
}
void EditorMainFrame_ImGui::RequestCloseWindow()
{
m_ShowWarning_CloseEditor = false;
// If any Editor Document has unsaved changes, then pop up a warning.
if( m_pEngineCore->GetEditorState()->DoAnyOpenDocumentsHaveUnsavedChanges() )
{
m_ShowWarning_CloseEditor = true;
}
// If the Scene command stack isn't clear, then pop up a warning.
if( m_ShowWarning_CloseEditor || m_pCommandStack->GetUndoStackSize() != m_UndoStackDepthAtLastSave )
{
m_ShowWarning_CloseEditor = true;
}
else
{
g_pGameCore->SetGameConfirmedCloseIsOkay();
}
}
void EditorMainFrame_ImGui::OnModeTogglePlayStop(bool nowInEditorMode)
{
if( nowInEditorMode )
{
m_pLayoutManager->RequestEditorLayout();
}
else
{
m_pLayoutManager->RequestGameLayout();
}
}
void EditorMainFrame_ImGui::Update(float deltaTime)
{
m_RenameTimerForSlowDoubleClick += deltaTime;
m_pAnimPlayerComponent->TickCallback( deltaTime );
}
void EditorMainFrame_ImGui::AddEverything()
{
EditorPrefs* pEditorPrefs = m_pEngineCore->GetEditorPrefs();
m_pCurrentLayout = m_pLayoutManager->GetCurrentLayout();
ImGuiWindowFlags flags = ImGuiWindowFlags_MenuBar | ImGuiWindowFlags_NoDocking;
ImGuiViewport* viewport = ImGui::GetMainViewport();
ImGui::SetNextWindowPos( viewport->Pos );
ImGui::SetNextWindowSize( viewport->Size );
ImGui::SetNextWindowViewport( viewport->ID );
ImGui::PushStyleVar( ImGuiStyleVar_WindowRounding, 0.0f );
flags |= ImGuiWindowFlags_NoTitleBar | ImGuiWindowFlags_NoCollapse | ImGuiWindowFlags_NoResize | ImGuiWindowFlags_NoMove;
flags |= ImGuiWindowFlags_NoBringToFrontOnFocus | ImGuiWindowFlags_NoNavFocus;
ImGui::PushStyleVar( ImGuiStyleVar_WindowPadding, ImVec2(0.0f, 0.0f) );
ImGui::Begin( "Main Dock", nullptr, flags );
ImGui::PopStyleVar();
AddMainMenuBar();
ImGuiID dockspaceID = ImGui::GetID( "MyDockspace" );
ImGui::DockSpace( dockspaceID );
ImGuiDockNode* pCentralNode = ImGui::DockBuilderGetCentralNode( dockspaceID );
m_CentralNodeDockID = pCentralNode->ID;
ImGui::End();
ImGui::PopStyleVar();
AddGameAndEditorWindows();
AddObjectList();
AddWatchPanel();
AddLogWindow();
AddMemoryWindow();
AddCommandStacksWindow();
AddMemoryPanel();
AddDebug_MousePicker();
if( m_pCurrentLayout->m_IsWindowOpen[EditorWindow_MaterialEditor] )
{
AddMaterialEditor();
}
Add2DAnimationEditor();
AddLoseChangesWarningPopups();
pEditorPrefs->AddCustomizationDialog();
#if _DEBUG
ImGuiIO& io = ImGui::GetIO();
if( m_pCurrentLayout->m_IsWindowOpen[EditorWindow_Debug_Stuff] )
{
if( ImGui::Begin( "Stuff", &m_pCurrentLayout->m_IsWindowOpen[EditorWindow_Debug_Stuff] ) )
{
ImGui::Text( "WantCaptureKeyboard %d", io.WantCaptureKeyboard );
ImGui::Text( "WantCaptureMouse %d", io.WantCaptureMouse );
//ImGui::Text( "WantMoveMouse %d", io.WantMoveMouse );
ImGui::Text( "WantTextInput %d", io.WantTextInput );
ImGui::Text( "m_GameWindowFocused %d", m_GameWindowFocused );
ImGui::Text( "m_EditorWindowHovered %d", m_EditorWindowHovered );
ImGui::Text( "m_EditorWindowFocused %d", m_EditorWindowFocused );
ImGui::Text( "MouseWheel %0.2f", io.MouseWheel );
ImGui::Text( "m_CurrentMouseInEditorWindow_X %d", m_CurrentMouseInEditorWindow_X );
ImGui::Text( "m_CurrentMouseInEditorWindow_Y %d", m_CurrentMouseInEditorWindow_Y );
GameObject* pGO = g_pComponentSystemManager->FindGameObjectByName( "Player" );
if( pGO && pGO->GetTransform() )
{
ImGui::Text( "PlayerX %0.2f", pGO->GetTransform()->GetWorldTransform()->m41 );
}
}
ImGui::End();
}
if( m_pCurrentLayout->m_IsWindowOpen[EditorWindow_Debug_ImGuiDemo] )
{
ImGui::ShowDemoWindow( &m_pCurrentLayout->m_IsWindowOpen[EditorWindow_Debug_ImGuiDemo] );
}
#endif //_DEBUG
if( m_pCurrentLayout->m_IsWindowOpen[EditorWindow_GridSettings] )
{
ImGui::SetNextWindowSize( ImVec2(308, 60), ImGuiCond_FirstUseEver );
ImGui::SetNextWindowBgAlpha( 1.0f );
if( ImGui::Begin( "Grid Settings", &m_pCurrentLayout->m_IsWindowOpen[EditorWindow_GridSettings] ) )
{
// Create a context menu only available from the title bar.
if( ImGui::BeginPopupContextItem() )
{
if( ImGui::MenuItem( "Close" ) )
m_pCurrentLayout->m_IsWindowOpen[EditorWindow_GridSettings] = false;
ImGui::EndPopup();
}
pEditorPrefs->FillGridSettingsWindow();
}
ImGui::End();
}
// Clear m_pActiveDocument, a new one will be set if a document is in focus.
m_pActiveDocument = nullptr;
m_pVisibleDocuments.clear();
std::vector<EditorDocument*>* pOpenDocuments = &m_pEngineCore->GetEditorState()->m_pOpenDocuments;
for( uint32 i=0; i<pOpenDocuments->size(); i++ )
{
EditorDocument* pDocument = (*pOpenDocuments)[i];
ImGui::SetNextWindowDockID( m_CentralNodeDockID, ImGuiCond_FirstUseEver );
ImGui::SetNextWindowSize( ImVec2(400, 400), ImGuiCond_FirstUseEver );
bool documentStillOpen = true;
pDocument->CreateWindowAndUpdate( &documentStillOpen );
if( pDocument->IsWindowFocused() )
{
m_pActiveDocument = pDocument;
m_pLastActiveDocument = pDocument;
}
if( pDocument->IsWindowVisible() )
{
m_pVisibleDocuments.push_back( pDocument );
}
if( documentStillOpen == false )
{
if( pDocument->HasUnsavedChanges() )
{
m_ShowWarning_CloseDocument = true;
m_DocumentIndexToCloseAfterWarning = i;
}
else
{
m_pActiveDocument = nullptr;
m_pLastActiveDocument = nullptr;
m_pVisibleDocuments.clear();
pOpenDocuments->erase( pOpenDocuments->begin() + i );
delete pDocument;
}
}
}
m_RenamePressedThisFrame = false;
m_pLayoutManager->FinishFocusChangeIfNeeded();
}
void EditorMainFrame_ImGui::DrawGameAndEditorWindows(EngineCore* pEngineCore)
{
// Only refresh visible document windows.
for( EditorDocument* pDocument : m_pVisibleDocuments )
{
pDocument->OnDrawFrame();
}
if( m_GameWindowVisible && m_GameWindowSize.LengthSquared() != 0 )
{
if( m_pGameFBO->GetColorTexture( 0 ) )
{
g_GLStats.NewCanvasFrame( 0 );
// Draw game view.
uint32 previousFBO = g_GLStats.m_CurrentFramebuffer;
m_pGameFBO->Bind( false );
uint32 x = 0;
uint32 y = 0;
uint32 w = (uint32)m_GameWindowSize.x;
uint32 h = (uint32)m_GameWindowSize.y;
EditorPrefs* pEditorPrefs = m_pEngineCore->GetEditorPrefs();
if( pEditorPrefs->Get_Aspect_GameAspectRatio() == GLView_Full )
{
}
else if( pEditorPrefs->Get_Aspect_GameAspectRatio() == GLView_Tall )
{
if( w - h/1.5f >= 0 )
{
x = (uint32)( (w - h/1.5f) / 2.0f );
w = (uint32)( h/1.5f );
}
else
{
}
}
else if( pEditorPrefs->Get_Aspect_GameAspectRatio() == GLView_Square )
{
if( w < h )
{
y = (h-w)/2;
h = w;
}
else
{
x = (w-h)/2;
w = h;
}
}
else if( pEditorPrefs->Get_Aspect_GameAspectRatio() == GLView_Wide )
{
if( h - w/1.5f >= 0 )
{
y = (uint32)( ( h - w/1.5f ) / 2.0f );
h = (uint32)( w/1.5f );
}
else
{
}
}
// Reset the viewport sizes of the game or editor cameras.
ComponentSystemManager* pComponentSystemManager = pEngineCore->GetComponentSystemManager();
if( pComponentSystemManager )
{
pComponentSystemManager->OnSurfaceChanged( x, y, w, h, (uint32)m_pEngineCore->m_GameWidth, (uint32)m_pEngineCore->m_GameHeight );
pComponentSystemManager->OnDrawFrame();
}
g_pRenderer->BindFramebuffer( previousFBO );
g_GLStats.EndCanvasFrame();
}
}
if( m_EditorWindowVisible && m_EditorWindowSize.LengthSquared() != 0 )
{
if( m_pEditorFBO->GetColorTexture( 0 ) )
{
EditorPrefs* pEditorPrefs = m_pEngineCore->GetEditorPrefs();
g_GLStats.NewCanvasFrame( 1 );
// Draw editor view.
g_GLCanvasIDActive = 1;
pEngineCore->Editor_OnSurfaceChanged( 0, 0, (unsigned int)m_EditorWindowSize.x, (unsigned int)m_EditorWindowSize.y );
uint32 previousFBO = g_GLStats.m_CurrentFramebuffer;
m_pEditorFBO->Bind( false );
m_pEngineCore->GetEditorState()->GetEditorCamera()->SetDeferred( pEditorPrefs->Get_View_EditorCamDeferred() );
pEngineCore->GetCurrentEditorInterface()->OnDrawFrame( 1 );
g_pRenderer->BindFramebuffer( previousFBO );
g_GLCanvasIDActive = 0;
g_GLStats.EndCanvasFrame();
}
}
// Render material preview onto a sphere, if requested.
if( m_pMaterialToPreview != nullptr && m_pMaterialToPreview->GetPreviewType() == MaterialDefinition::PreviewType_Sphere )
{
if( m_pMaterialPreviewFBO->GetColorTexture( 0 ) )
{
MyMesh* pMeshBall = m_pEngineCore->GetMesh_MaterialBall();
if( pMeshBall )
{
m_pMaterialPreviewFBO->Bind( true );
MyViewport viewport( 0, 0, m_pMaterialPreviewFBO->GetWidth(), m_pMaterialPreviewFBO->GetHeight() );
g_pRenderer->EnableViewport( &viewport, true );
g_pRenderer->SetClearColor( ColorFloat( 0.0f, 0.0f, 0.2f, 1.0f ) );
g_pRenderer->ClearBuffers( true, true, false );
pMeshBall->SetMaterial( m_pMaterialToPreview, 0 );
MyMatrix matview;
matview.SetIdentity();
#if MYFW_RIGHTHANDED
matview.Translate( 0, 0, -4 );
#else
matview.Translate( 0, 0, 4 );
#endif
float aspect = (float)m_pMaterialPreviewFBO->GetWidth() / m_pMaterialPreviewFBO->GetHeight();
MyMatrix matproj;
matproj.CreatePerspectiveVFoV( 45, aspect, 0.01f, 100 );
MyMatrix matviewproj = matproj * matview;
Vector3 campos = matview.GetTranslation() * -1;
Vector3 camrot( 0, 0, 0 );
float time = (float)MyTime_GetRunningTime();
// Create 2 rotating lights for material render.
MyLight light1;
light1.m_Attenuation.Set( 5, 0.1f, 0.01f ); // x is a radius/range, yz not used.
light1.m_Color.Set( 1, 1, 1, 1 );
light1.m_LightType = LightType_Point;
light1.m_Position.Set( 2*cosf(time), 1, 2*sinf(time) );
MyLight light2;
light2.m_Attenuation.Set( 5, 0.1f, 0.01f ); // x is a radius/range, yz not used.
light2.m_Color.Set( 1, 1, 1, 1 );
light2.m_LightType = LightType_Point;
light2.m_Position.Set( 2*cosf(PI+time), 1, 2*sinf(PI+time) );
MyLight* lights[] = { &light1, &light2 };
pMeshBall->Draw( &matproj, &matview, nullptr, &campos, &camrot, lights, 2, nullptr, nullptr, nullptr, nullptr );
// Unset the material to avoid holding a ref that prevents the material from unloading.
pMeshBall->SetMaterial( nullptr, 0 );
m_pMaterialPreviewFBO->Unbind( true );
}
// Unset the material to preview, it will be reset every frame by the code that needs it.
m_pMaterialToPreview = nullptr;
}
}
}
void EditorMainFrame_ImGui::EditMaterial(MaterialDefinition* pMaterial)
{
m_pMaterialBeingEdited = pMaterial;
ImGui::SetWindowFocus( "Material Editor" );
m_pCurrentLayout->m_IsWindowOpen[EditorWindow_MaterialEditor] = true;
}
void EditorMainFrame_ImGui::Edit2DAnimInfo(My2DAnimInfo* pAnimInfo)
{
m_p2DAnimInfoBeingEdited = pAnimInfo;
ImGui::SetWindowFocus( "2D Animation Editor" );
m_pCurrentLayout->m_IsWindowOpen[EditorWindow_2DAnimationEditor] = true;
m_Current2DAnimationIndex = 0;
}
void EditorMainFrame_ImGui::AddInlineMaterial(MaterialDefinition* pMaterial)
{
// Show Exposed Uniforms.
if( pMaterial->m_pShaderGroup )
{
MyFileObjectShader* pShaderFile = pMaterial->m_pShaderGroup->GetFile();
if( pShaderFile )
{
for( unsigned int i=0; i<pShaderFile->m_NumExposedUniforms; i++ )
{
char tempname[32];
// Hardcoding to remove the 'u_' I like to stick at the start of my uniform names.
if( pShaderFile->m_ExposedUniforms[i].m_Name[1] == '_' )
strcpy_s( tempname, 32, &pShaderFile->m_ExposedUniforms[i].m_Name[2] );
else
strcpy_s( tempname, 32, pShaderFile->m_ExposedUniforms[i].m_Name );
switch( pShaderFile->m_ExposedUniforms[i].m_Type )
{
case ExposedUniformType_Float:
ImGui::DragFloat( tempname, &pMaterial->m_UniformValues[i].m_Float, 0.01f, 0, 1 );
break;
case ExposedUniformType_Vec2:
ImGui::DragFloat2( tempname, pMaterial->m_UniformValues[i].m_Vec2, 0.01f, 0, 1 );
break;
case ExposedUniformType_Vec3:
ImGui::DragFloat3( tempname, pMaterial->m_UniformValues[i].m_Vec3, 0.01f, 0, 1 );
break;
case ExposedUniformType_Vec4:
ImGui::DragFloat4( tempname, pMaterial->m_UniformValues[i].m_Vec4, 0.01f, 0, 1 );
break;
case ExposedUniformType_ColorByte:
{
ColorByte* pColorByte = (ColorByte*)pMaterial->m_UniformValues[i].m_ColorByte;
ColorFloat colorFloat = pColorByte->AsColorFloat();
if( ImGui::ColorEdit4( "Ambient Color", &colorFloat.r ) )
{
pColorByte->SetFromColorFloat( colorFloat );
}
}
break;
case ExposedUniformType_Sampler2D:
{
const char* desc = "no texture";
EditorPrefs* pEditorPrefs = m_pEngineCore->GetEditorPrefs();
Vector4 buttonColor = pEditorPrefs->GetImGuiStylePrefs()->GetColor( ImGuiStylePrefs::StylePref_Color_UnsetObjectButton );
Vector4 textColor = pEditorPrefs->GetImGuiStylePrefs()->GetColor( ImGuiStylePrefs::StylePref_Color_UnsetObjectText );
TextureDefinition* pTextureColor = pMaterial->m_UniformValues[i].m_pTexture;
if( pTextureColor )
{
desc = pTextureColor->GetFilename();
buttonColor = pEditorPrefs->GetImGuiStylePrefs()->GetColor( ImGuiStylePrefs::StylePref_Color_Button );
textColor = pEditorPrefs->GetImGuiStylePrefs()->GetColor( ImGuiStylePrefs::StylePref_Color_Text );
}
ImGui::PushStyleColor( ImGuiCol_Button, buttonColor );
ImGui::PushStyleColor( ImGuiCol_Text, textColor );
ImGui::Button( desc, ImVec2( ImGui::GetWindowWidth() * 0.65f, 0 ) );
ImGui::PopStyleColor( 2 );
if( ImGui::BeginDragDropTarget() )
{
if( const ImGuiPayload* payload = ImGui::AcceptDragDropPayload( "Texture" ) )
{
TextureDefinition* pNewTexture = (TextureDefinition*)*(void**)payload->Data;
if( pNewTexture )
pNewTexture->AddRef();
SAFE_RELEASE( pMaterial->m_UniformValues[i].m_pTexture );
pMaterial->m_UniformValues[i].m_pTexture = pNewTexture;
}
ImGui::EndDragDropTarget();
}
if( ImGui::IsItemHovered() )
{
if( pTextureColor )
{
ImGui::BeginTooltip();
//ImGui::Text( "%s", pTex->GetFilename() );
AddTexturePreview( pTextureColor, false, ImVec2( 100, 100 ), ImVec4( 1, 1, 1, 1 ) );
ImGui::EndTooltip();
}
if( ImGui::IsMouseDoubleClicked( 0 ) )
{
SAFE_RELEASE( pMaterial->m_UniformValues[i].m_pTexture );
pMaterial->m_UniformValues[i].m_pTexture = 0;
}
}
ImGui::SameLine();
ImGui::Text( tempname );
}
break;
case ExposedUniformType_NotSet:
default:
MyAssert( false );
break;
}
}
}
}
}
My2DAnimInfo* EditorMainFrame_ImGui::Get2DAnimInfoBeingEdited()
{
if( m_pCurrentLayout && m_pCurrentLayout->m_IsWindowOpen[EditorWindow_2DAnimationEditor] )
{
return m_p2DAnimInfoBeingEdited;
}
return nullptr;
}
void EditorMainFrame_ImGui::SetFullPathToLast2DAnimInfoBeingEdited(const char* fullPath)
{
strcpy_s( m_FullPathToLast2DAnimInfoBeingEdited, MAX_PATH, fullPath );
}
//====================================================================================================
// Internal methods
//====================================================================================================
void EditorMainFrame_ImGui::StartRenameOp(GameObject* pGameObject, MaterialDefinition* pMaterial, const char* name)
{
m_pGameObjectWhoseNameIsBeingEdited = pGameObject;
m_pMaterialWhoseNameIsBeingEdited = pMaterial;
strncpy_s( m_NameBeingEdited, 100, name, 99 );
m_ConfirmCurrentRenameOp = false;
}
bool EditorMainFrame_ImGui::WasItemSlowDoubleClicked(void* pObjectClicked)
{
MyAssert( pObjectClicked != nullptr );
if( ImGui::IsItemClicked( 0 ) )
{
if( ImGuiExt::IsMouseHoveringOverItemExpansionArrow() )
{
// Clear the timer if the arrow was clicked.
m_RenameTimerForSlowDoubleClick = 9999.0f;
}
else if( ImGui::IsMouseDoubleClicked( 0 ) )
{
// Clear the timer if there was a double-click.
m_RenameTimerForSlowDoubleClick = 9999.0f;
}
else if( pObjectClicked != m_RenameOp_LastObjectClicked )
{
// Restart the timer if a different object was selected.
m_RenameTimerForSlowDoubleClick = 0.0f;
m_RenameOp_LastObjectClicked = pObjectClicked;
}
else
{
// If we're in the slow double click window, return true.
if( m_RenameTimerForSlowDoubleClick > ImGui::GetIO().MouseDoubleClickTime && m_RenameTimerForSlowDoubleClick < 1.0f )
{
m_RenameTimerForSlowDoubleClick = 0.0f;
return true;
}
// Restart the timer.
m_RenameTimerForSlowDoubleClick = 0.0f;
}
}
return false;
}
void EditorMainFrame_ImGui::AddMenuItemWithHotkeyCheck(const char* string, HotkeyAction action, bool selected)
{
EditorKeyBindings* pKeys = m_pEngineCore->GetEditorPrefs()->GetKeyBindings();
if( ImGui::MenuItem( string, pKeys->GetStringForKey( action ), selected ) )
{
ExecuteHotkeyAction( action );
}
}
void EditorMainFrame_ImGui::AddMainMenuBar()
{
EditorPrefs* pEditorPrefs = m_pEngineCore->GetEditorPrefs();
bool wasInEditorMode = true;
if( m_pEngineCore->IsInEditorMode() == false )
{
Vector4 gameRunningMenuBarColor = pEditorPrefs->GetImGuiStylePrefs()->GetColor( ImGuiStylePrefs::StylePref_Color_GameRunningMenuBarColor );
ImGui::PushStyleColor( ImGuiCol_MenuBarBg, gameRunningMenuBarColor );
wasInEditorMode = false;
}
if( ImGui::BeginMainMenuBar() )
{
if( ImGui::BeginMenu( "Scene" ) )
{
if( ImGui::MenuItem( "New Scene" ) )
{
if( m_pCommandStack->GetUndoStackSize() != m_UndoStackDepthAtLastSave )
m_ShowWarning_NewScene = true;
else
EditorMenuCommand( EditorMenuCommand_File_NewScene );
}
if( ImGui::MenuItem( "Load Scene..." ) )
{
if( m_pCommandStack->GetUndoStackSize() != m_UndoStackDepthAtLastSave )
m_ShowWarning_LoadScene = true;
else
EditorMenuCommand( EditorMenuCommand_File_LoadScene );
}
if( ImGui::BeginMenu( "Load Recent Scene..." ) )
{
uint32 numRecentScenes = pEditorPrefs->Get_File_NumRecentScenes();
if( numRecentScenes == 0 )
{
ImGui::Text( "no recent scenes..." );
}
for( uint32 i=0; i<numRecentScenes; i++ )
{
std::string recentFilename = pEditorPrefs->Get_File_RecentScene( i );
if( ImGui::MenuItem( recentFilename.c_str() ) )
{
if( m_pCommandStack->GetUndoStackSize() != m_UndoStackDepthAtLastSave )
{
m_ShowWarning_LoadScene = true;
m_SceneToLoadAfterWarning = recentFilename;
}
else
{
// TODO: Handle files that no longer exist.
EditorMenuCommand( EditorMenuCommand_File_LoadPreselectedScene, recentFilename );
}
}
}
ImGui::EndMenu();
}
ImGui::Separator();
if( ImGui::MenuItem( "Create Additional Scene" ) )
{
EditorMenuCommand( EditorMenuCommand_File_CreateAdditionalScene );
}
if( ImGui::MenuItem( "Load Additional Scene..." ) )
{
EditorMenuCommand( EditorMenuCommand_File_LoadAdditionalScene );
}
ImGui::Separator();
AddMenuItemWithHotkeyCheck( "Save Scene", HotkeyAction::File_SaveScene );
if( ImGui::MenuItem( "Save Scene As..." ) )
{
EditorMenuCommand( EditorMenuCommand_File_SaveSceneAs );
}
AddMenuItemWithHotkeyCheck( "Save All", HotkeyAction::File_SaveAll );
ImGui::Separator();
#if MYFW_USING_BOX2D
if( ImGui::BeginMenu( "Export" ) )
{
AddMenuItemWithHotkeyCheck( "Box2D Scene...", HotkeyAction::File_ExportBox2D );
ImGui::EndMenu();
}
#endif //MYFW_USING_BOX2D
ImGui::Separator();
AddMenuItemWithHotkeyCheck( "Preferences...", HotkeyAction::File_Preferences );
if( ImGui::MenuItem( "Quit" ) ) { RequestCloseWindow(); }
ImGui::EndMenu(); // "Scene"
}
// Add a menu for editor documents.
EditorDocument* pNewDocument = m_pEngineCore->GetEditorDocumentManager()->AddDocumentMenu( m_pEngineCore, m_pLastActiveDocument );
if( pNewDocument != nullptr )
{
m_pEngineCore->GetEditorState()->OpenDocument( pNewDocument );
}
if( ImGui::BeginMenu( "Edit" ) )
{
AddMenuItemWithHotkeyCheck( "Undo", HotkeyAction::Edit_Undo );
AddMenuItemWithHotkeyCheck( "Redo", HotkeyAction::Edit_Redo );
ImGui::EndMenu();
}
if( ImGui::BeginMenu( "View" ) )
{
//if( ImGui::MenuItem( "Save window layout (TODO)" ) ) {} // { EditorMenuCommand( myID_View_SavePerspective ); }
//if( ImGui::MenuItem( "Load window layout (TODO)" ) ) {} // { EditorMenuCommand( myID_View_LoadPerspective ); }
if( ImGui::MenuItem( "Reset window layout" ) ) { m_pLayoutManager->ResetCurrentLayout(); };
if( ImGui::BeginMenu( "Editor Windows" ) )
{
for( int i=0; i<EditorWindow_NumTypes; i++ )
{
if( ImGui::MenuItem( g_DefaultEditorWindowTypeMenuLabels[i] ) )
{
m_pCurrentLayout->m_IsWindowOpen[i] = true;
}
// Add a separator between main window, secondary window and debug window groups.
if( i == 5 || i == 8 )
{
ImGui::Separator();
}
}
//for( int i=0; i<EngineEditorWindow_NumTypes; i++ )
//{
// if( ImGui::MenuItem( g_DefaultEngineEditorWindowTypeMenuLabels[i] ) ) {}
//}
ImGui::EndMenu();
}
if( ImGui::BeginMenu( "Editor Window Layouts" ) )
{
for( unsigned int i=0; i<EditorLayout_NumLayouts; i++ )
{
if( ImGui::MenuItem( g_EditorLayoutMenuLabels[i], nullptr, m_pLayoutManager->GetSelectedLayout_EditorMode() == (EditorLayoutTypes)i ) )
{
m_pLayoutManager->SetSelectedLayout_EditorMode( (EditorLayoutTypes)i );
if( m_pEngineCore->IsInEditorMode() == true )
{
m_pLayoutManager->RequestEditorLayout();
}
}
}
ImGui::EndMenu();
}
if( ImGui::BeginMenu( "Gameplay Window Layouts" ) )
{
for( int i=0; i<EditorLayout_NumLayouts; i++ )
{
if( ImGui::MenuItem( g_EditorLayoutMenuLabels[i], nullptr, m_pLayoutManager->GetSelectedLayout_GameMode() == (EditorLayoutTypes)i ) )
{
m_pLayoutManager->SetSelectedLayout_GameMode( (EditorLayoutTypes)i );
if( m_pEngineCore->IsInEditorMode() == false )
{
m_pLayoutManager->RequestGameLayout();
}
}
}
ImGui::EndMenu();
}
ImGui::Separator();
if( ImGui::BeginMenu( "Selected Objects" ) )
{
if( ImGui::MenuItem( "Show Wireframe", 0, pEditorPrefs->Get_View_SelectedObjects_ShowWireframe() ) ) { EditorMenuCommand( EditorMenuCommand_View_SelectedObjects_ShowWireframe ); }
if( ImGui::MenuItem( "Show Effect", 0, pEditorPrefs->Get_View_SelectedObjects_ShowEffect() ) ) { EditorMenuCommand( EditorMenuCommand_View_SelectedObjects_ShowEffect ); }
ImGui::EndMenu();
}
if( ImGui::BeginMenu( "Editor Camera" ) )
{
AddMenuItemWithHotkeyCheck( "Show Properties", HotkeyAction::View_ShowEditorCamProperties );
AddMenuItemWithHotkeyCheck( "Show Icons", HotkeyAction::View_ShowEditorIcons, pEditorPrefs->Get_View_ShowEditorIcons() );
AddMenuItemWithHotkeyCheck( "Deferred Render", HotkeyAction::View_ToggleEditorCamDeferred, pEditorPrefs->Get_View_EditorCamDeferred() );
if( ImGui::MenuItem( "Show Deferred G-Buffer", "" ) ) { EditorMenuCommand( EditorMenuCommand_View_ShowEditorCamDeferredGBuffer ); }
if( ImGui::BeginMenu( "Editor Camera Layers (TODO)" ) )
{
for( int i=0; i<g_NumberOfVisibilityLayers; i++ )
{
char label[100];
char hotkey[100];
sprintf_s( label, 100, "(%d) %s", i, g_pVisibilityLayerStrings[i] );
sprintf_s( hotkey, 100, "Ctrl-Alt-%d", i );
if( i < 9 )
{
if( ImGui::MenuItem( label, hotkey ) ) {}
}
else
{
if( ImGui::MenuItem( label ) ) {}
}
}
ImGui::EndMenu();
}
// {
// m_SubMenu_View_EditorCameraLayers = MyNew wxMenu;
// for( int i=0; i<g_NumberOfVisibilityLayers; i++ )
// {
// wxString label;
// if( i < 9 )
// label << "(&" << i+1 << ") " << g_pVisibilityLayerStrings[i] << "\tCtrl-Alt-" << i+1;
// else
// label << "(&" << i+1 << ") " << g_pVisibilityLayerStrings[i];
// m_MenuItem_View_EditorCameraLayerOptions[i] = m_SubMenu_View_EditorCameraLayers->AppendCheckItem( EditorMenuCommand_View_EditorCameraLayer + i, label, wxEmptyString );
// Connect( EditorMenuCommand_View_EditorCameraLayer + i, wxEVT_COMMAND_MENU_SELECTED, wxCommandEventHandler(EngineMainFrame::OnMenu_Engine) );
// }
//
// m_MenuItem_View_EditorCameraLayerOptions[0]->Check();
// }
ImGui::EndMenu();
}
ImGui::Separator();
ImGui::MenuItem( "Fullscreen Editor (TODO)", "F11" );
ImGui::MenuItem( "Fullscreen Game (TODO)", "Ctrl-F11" );
ImGui::EndMenu();
}
if( ImGui::BeginMenu( "Aspect" ) )
{
unsigned int w = (unsigned int)m_EditorWindowSize.x;
unsigned int h = (unsigned int)m_EditorWindowSize.y;
EditorPrefs* pEditorPrefs = m_pEngineCore->GetEditorPrefs();
AddMenuItemWithHotkeyCheck( "Fill", HotkeyAction::View_Full, pEditorPrefs->Get_Aspect_GameAspectRatio() == GLView_Full );
AddMenuItemWithHotkeyCheck( "Tall", HotkeyAction::View_Tall, pEditorPrefs->Get_Aspect_GameAspectRatio() == GLView_Tall );
AddMenuItemWithHotkeyCheck( "Square", HotkeyAction::View_Square, pEditorPrefs->Get_Aspect_GameAspectRatio() == GLView_Square );
AddMenuItemWithHotkeyCheck( "Wide", HotkeyAction::View_Wide, pEditorPrefs->Get_Aspect_GameAspectRatio() == GLView_Wide );
ImGui::EndMenu();
}
if( ImGui::BeginMenu( "Grid" ) )
{
AddMenuItemWithHotkeyCheck( "Grid Visible", HotkeyAction::Grid_Visible, pEditorPrefs->Get_Grid_Visible() );
AddMenuItemWithHotkeyCheck( "Grid Snap Enabled", HotkeyAction::Grid_SnapEnabled, pEditorPrefs->Get_Grid_SnapEnabled() );
AddMenuItemWithHotkeyCheck( "Grid Settings", HotkeyAction::Grid_Settings );
ImGui::EndMenu();
}
if( ImGui::BeginMenu( "Mode" ) )
{
if( ImGui::MenuItem( "Switch Focus on Play/Stop", nullptr, pEditorPrefs->Get_Mode_SwitchFocusOnPlayStop() ) ) { EditorMenuCommand( EditorMenuCommand_Mode_SwitchFocusOnPlayStop ); }
// Since Command-Space is "Spotlight Search" on OSX, use the actual control key on OSX as well as Windows/Linux.
AddMenuItemWithHotkeyCheck( "Play/Stop", HotkeyAction::Mode_TogglePlayStop );
AddMenuItemWithHotkeyCheck( "Pause", HotkeyAction::Mode_Pause );
AddMenuItemWithHotkeyCheck( "Advance 1 Frame", HotkeyAction::Mode_AdvanceOneFrame );
AddMenuItemWithHotkeyCheck( "Advance 1 Second", HotkeyAction::Mode_AdvanceOneSecond );
if( ImGui::BeginMenu( "Launch Platforms" ) )
{
for( int i=0; i<LaunchPlatform_NumPlatforms; i++ )
{
bool isSelected = (pEditorPrefs->Get_Mode_LaunchPlatform() == i);
if( ImGui::MenuItem( g_LaunchPlatformsMenuLabels[i], nullptr, isSelected ) ) { EditorMenuCommand( (EditorMenuCommands)(EditorMenuCommand_Mode_LaunchPlatforms + i) ); }
}
ImGui::EndMenu();
}
AddMenuItemWithHotkeyCheck( "Launch Game", HotkeyAction::Mode_LaunchGame );
ImGui::EndMenu();
}
if( ImGui::BeginMenu( "Data" ) )
{
if( ImGui::MenuItem( "Load Datafiles" ) ) { EditorMenuCommand( EditorMenuCommand_Data_LoadDatafiles ); }
ImGui::EndMenu();
}
if( ImGui::BeginMenu( "Hackery" ) )
{
if( ImGui::MenuItem( "Record (TODO)", "Ctrl-R" ) ) {} // { EditorMenuCommand( EditorMenuCommand_Hackery_RecordMacro ); }
if( ImGui::MenuItem( "Stop recording and Execute (TODO)", "Ctrl-E" ) ) {} // { EditorMenuCommand( EditorMenuCommand_Hackery_ExecuteMacro ); }
ImGui::EndMenu();
}
if( ImGui::BeginMenu( "Debug views" ) )
{
if( ImGui::MenuItem( "Show Animated Debug View for Selection (TODO)", "F8" ) ) {} // { EditorMenuCommand( EditorMenuCommand_Debug_ShowSelectedAnimatedMesh ); }
if( ImGui::MenuItem( "Show GL Stats (TODO)", "Shift-F9" ) ) {} // { EditorMenuCommand( EditorMenuCommand_Debug_ShowGLStats ); }
AddMenuItemWithHotkeyCheck( "Draw Wireframe", HotkeyAction::Debug_DrawWireframe, m_pEngineCore->GetDebug_DrawWireframe() );
AddMenuItemWithHotkeyCheck( "Show Physics Debug Shapes", HotkeyAction::Debug_ShowPhysicsShapes, pEditorPrefs->Get_Debug_DrawPhysicsDebugShapes() );
AddMenuItemWithHotkeyCheck( "Show Basic Stats", HotkeyAction::Debug_ShowStats, pEditorPrefs->Get_Debug_DrawStats() );
if( ImGui::MenuItem( "Show profiling Info (TODO)", "Ctrl-F8" ) ) {} // { EditorMenuCommand( EditorMenuCommand_Debug_ShowProfilingInfo ); }
ImGui::EndMenu();
}
if( ImGui::BeginMenu( "Lua" ) )
{
AddMenuItemWithHotkeyCheck( "Run Lua Script...", HotkeyAction::Lua_RunLuaScript );
if( pEditorPrefs->Get_Lua_NumRecentScripts() > 0 )
{
int fileIndex = 0;
if( ImGui::MenuItem( pEditorPrefs->Get_Lua_RecentScript( fileIndex ).c_str() ) ) { EditorMenuCommand( (EditorMenuCommands)(EditorMenuCommand_Lua_RunRecentLuaScript + fileIndex) ); }
}
ImGui::EndMenu();
}
ImGui::EndMainMenuBar();
}
if( wasInEditorMode == false )
{
ImGui::PopStyleColor();
}
}
void EditorMainFrame_ImGui::AddLoseChangesWarningPopups()
{
if( m_ShowWarning_NewScene )
{
m_ShowWarning_NewScene = false;
ImGui::OpenPopup( "New Scene Warning" );
}
if( ImGui::BeginPopupModal( "New Scene Warning" ) )
{
ImGui::Text( "Some changes aren't saved." );
ImGui::Dummy( ImVec2( 0, 10 ) );
if( ImGui::Button( "Create new scene anyway / Lose changes" ) )
{
EditorMenuCommand( EditorMenuCommand_File_NewScene );
ImGui::CloseCurrentPopup();
}
if( ImGui::Button( "Cancel / Return to editor" ) )
{
ImGui::CloseCurrentPopup();
}
ImGui::EndPopup();
}
if( m_ShowWarning_LoadScene )
{
m_ShowWarning_LoadScene = false;
ImGui::OpenPopup( "Load Scene Warning" );
}
if( ImGui::BeginPopupModal( "Load Scene Warning" ) )
{
ImGui::Text( "Some changes aren't saved." );
ImGui::Dummy( ImVec2( 0, 10 ) );
if( ImGui::Button( "Load anyway / Lose changes" ) )
{
if( m_SceneToLoadAfterWarning.empty() == true )
{
EditorMenuCommand( EditorMenuCommand_File_LoadScene );
}
else
{
EditorMenuCommand( EditorMenuCommand_File_LoadPreselectedScene, m_SceneToLoadAfterWarning );
}
ImGui::CloseCurrentPopup();
}
if( ImGui::Button( "Cancel / Return to editor" ) )
{
ImGui::CloseCurrentPopup();
}
ImGui::EndPopup();
}
if( m_ShowWarning_CloseDocument )
{
m_ShowWarning_CloseDocument = false;
ImGui::OpenPopup( "Close Document Warning" );
}
if( ImGui::BeginPopupModal( "Close Document Warning" ) )
{
ImGui::Text( "Some changes aren't saved." );
ImGui::Dummy( ImVec2( 0, 10 ) );
if( ImGui::Button( "Close / Lose changes" ) )
{
m_pActiveDocument = nullptr;
m_pLastActiveDocument = nullptr;
m_pVisibleDocuments.clear();
std::vector<EditorDocument*>* pOpenDocuments = &m_pEngineCore->GetEditorState()->m_pOpenDocuments;
delete (*pOpenDocuments)[m_DocumentIndexToCloseAfterWarning];
pOpenDocuments->erase( pOpenDocuments->begin() + m_DocumentIndexToCloseAfterWarning );
ImGui::CloseCurrentPopup();
}
if( ImGui::Button( "Cancel / Return to editor" ) )
{
ImGui::CloseCurrentPopup();
}
ImGui::EndPopup();
}
if( m_ShowWarning_CloseEditor )
{
m_ShowWarning_CloseEditor = false;
ImGui::OpenPopup( "Close Editor Warning" );
}
if( ImGui::BeginPopupModal( "Close Editor Warning" ) )
{
ImGui::Text( "Some changes aren't saved." );
ImGui::Dummy( ImVec2( 0, 10 ) );
if( ImGui::Button( "Quit / Lose changes" ) )
{
g_pGameCore->SetGameConfirmedCloseIsOkay();
}
if( ImGui::Button( "Cancel / Return to editor" ) )
{
ImGui::CloseCurrentPopup();
}
ImGui::EndPopup();
}
}
void EditorMainFrame_ImGui::AddGameAndEditorWindows()
{
m_GameWindowFocused = m_GameWindowVisible = false;
if( m_pCurrentLayout->m_IsWindowOpen[EditorWindow_Game] )
{
ImGui::SetNextWindowPos( ImVec2(9, 302), ImGuiCond_FirstUseEver );
ImGui::SetNextWindowSize( ImVec2(256, 171), ImGuiCond_FirstUseEver );
if( ImGui::Begin( "Game", &m_pCurrentLayout->m_IsWindowOpen[EditorWindow_Game] ) )
{
m_GameWindowFocused = ImGui::IsWindowFocused();
m_GameWindowVisible = true;
ImVec2 min = ImGui::GetWindowContentRegionMin();
ImVec2 max = ImGui::GetWindowContentRegionMax();
float w = max.x - min.x;
float h = max.y - min.y;
if( w <= 0 || h <= 0 )
{
m_GameWindowPos.Set( -1, -1 );
m_GameWindowSize.Set( 0, 0 );
}
else
{
ImVec2 pos = ImGui::GetWindowPos();
m_GameWindowPos.Set( pos.x + min.x, pos.y + min.y );
m_GameWindowSize.Set( w, h );
if( w > 4096 ) w = 4096;
if( h > 4096 ) h = 4096;
// This will resize our FBO if the window is larger than it ever was.
m_pEngineCore->GetManagers()->GetTextureManager()->ReSetupFBO( m_pGameFBO, (unsigned int)w, (unsigned int)h, MyRE::MinFilter_Nearest, MyRE::MagFilter_Nearest, FBODefinition::FBOColorFormat_RGBA_UByte, 32, false );
if( m_pGameFBO->GetColorTexture( 0 ) )
{
TextureDefinition* tex = m_pGameFBO->GetColorTexture( 0 );
ImGui::ImageButton( (void*)tex, ImVec2( w, h ), ImVec2(0,h/m_pGameFBO->GetTextureHeight()), ImVec2(w/m_pGameFBO->GetTextureWidth(),0), 0 );
}
}
}
else
{
m_GameWindowVisible = false;
}
ImGui::End();
}
m_EditorWindowFocused = m_EditorWindowHovered = m_EditorWindowVisible = false;
if( m_pCurrentLayout->m_IsWindowOpen[EditorWindow_Editor] )
{
ImGui::SetNextWindowPos( ImVec2(269, 24), ImGuiCond_FirstUseEver );
ImGui::SetNextWindowSize( ImVec2(579, 397), ImGuiCond_FirstUseEver );
if( ImGui::Begin( "Editor", &m_pCurrentLayout->m_IsWindowOpen[EditorWindow_Editor] ) )
{
m_EditorWindowFocused = ImGui::IsWindowFocused();
m_EditorWindowHovered = ImGui::IsWindowHovered( ImGuiHoveredFlags_AllowWhenBlockedByActiveItem );
m_EditorWindowVisible = true;
ImVec2 min = ImGui::GetWindowContentRegionMin();
ImVec2 max = ImGui::GetWindowContentRegionMax();
float w = max.x - min.x;
float h = max.y - min.y;
if( w <= 0 || h <= 0 )
{
m_EditorWindowPos.Set( -1, -1 );
m_EditorWindowSize.Set( 0, 0 );
}
else
{
ImVec2 pos = ImGui::GetWindowPos();
m_EditorWindowPos.Set( pos.x + min.x, pos.y + min.y );
m_EditorWindowSize.Set( w, h );
if( w > 4096 ) w = 4096;
if( h > 4096 ) h = 4096;
// This will resize our FBO if the window is larger than it ever was.
m_pEngineCore->GetManagers()->GetTextureManager()->ReSetupFBO( m_pEditorFBO, (unsigned int)w, (unsigned int)h, MyRE::MinFilter_Nearest, MyRE::MagFilter_Nearest, FBODefinition::FBOColorFormat_RGBA_UByte, 32, false );
if( m_pEditorFBO->GetColorTexture( 0 ) )
{
TextureDefinition* tex = m_pEditorFBO->GetColorTexture( 0 );
ImGui::ImageButton( (void*)tex, ImVec2( w, h ), ImVec2(0,h/m_pEditorFBO->GetTextureHeight()), ImVec2(w/m_pEditorFBO->GetTextureWidth(),0), 0 );
if( ImGui::BeginDragDropTarget() )
{
OnDropEditorWindow();
ImGui::EndDragDropTarget();
}
}
// Allow the current editor interface to add some overlay items to the window.
{
ImGui::SetCursorPos( ImVec2( 8, 28 ) );
m_pEngineCore->GetCurrentEditorInterface()->AddImGuiOverlayItems();
#if MYFW_USING_MONO
if( m_pEngineCore->GetMonoGameState() )
{
if( m_pEngineCore->GetMonoGameState()->IsRebuilding() )
{
ImGui::Text( "Recompiling C# files..." );
}
}
#endif //MYFW_USING_MONO
}
}
}
else
{
m_EditorWindowVisible = false;
}
ImGui::End();
}
}
void EditorMainFrame_ImGui::AddObjectList()
{
if( m_pCurrentLayout->m_IsWindowOpen[EditorWindow_ObjectList] == false )
return;
ImGuiTreeNodeFlags baseNodeFlags = ImGuiTreeNodeFlags_OpenOnArrow | ImGuiTreeNodeFlags_OpenOnDoubleClick;
ImGui::SetNextWindowPos( ImVec2(4, 28), ImGuiCond_FirstUseEver );
ImGui::SetNextWindowSize( ImVec2(258, 266), ImGuiCond_FirstUseEver );
if( ImGui::Begin( "Objects", &m_pCurrentLayout->m_IsWindowOpen[EditorWindow_ObjectList] ) )
{
// Add an input box for object list filter.
// For now, it will always auto-select the text when given focus.
// TODO: Only auto-select when Ctrl-F is pressed, not if clicked by mouse.
{
ImGuiInputTextFlags inputTextFlags = ImGuiInputTextFlags_AutoSelectAll;
if( m_SetObjectListFilterBoxInFocus )
{
//inputTextFlags |= ImGuiInputTextFlags_AutoSelectAll;
ImGui::SetKeyboardFocusHere();
m_SetObjectListFilterBoxInFocus = false;
}
ImGui::InputText( "Filter", m_ObjectListFilter, 100, inputTextFlags );
ImGui::SameLine();
if( ImGui::Button( "X" ) )
{
m_ObjectListFilter[0] = '\0';
}
}
bool forceOpen = false;
if( m_ObjectListFilter[0] != '\0' )
{
ImGui::PushID( "FilteredList" );
forceOpen = true;
}
ImGui::BeginChild( "GameObject List" );
if( ImGui::CollapsingHeader( "All scenes", ImGuiTreeNodeFlags_DefaultOpen ) || forceOpen )
{
// Add all active scenes.
for( int i=0; i<MAX_SCENES_LOADED_INCLUDING_UNMANAGED; i++ )
{
// Show Unmanaged scene first.
unsigned int sceneindex;
if( i == 0 )
sceneindex = SCENEID_Unmanaged;
else
sceneindex = i-1;
SceneInfo* pSceneInfo = g_pComponentSystemManager->GetSceneInfo( (SceneID)sceneindex );
if( pSceneInfo->m_InUse == true )
{
static char* pUnmanagedName = "Runtime";
static char* pUnsavedName = "Unsaved scene";
char* scenename = pUnmanagedName;
if( sceneindex != SCENEID_Unmanaged )
scenename = pUnsavedName;
if( pSceneInfo->m_FullPath[0] != '\0' )
{
int i;
for( i=(int)strlen(pSceneInfo->m_FullPath)-1; i>=0; i-- )
{
if( pSceneInfo->m_FullPath[i] == '\\' || pSceneInfo->m_FullPath[i] == '/' )
break;
}
scenename = &pSceneInfo->m_FullPath[i+1];
}
ImGuiTreeNodeFlags nodeFlags = baseNodeFlags;
//if( sceneindex != SCENEID_Unmanaged )
nodeFlags |= ImGuiTreeNodeFlags_DefaultOpen;
if( forceOpen )
{
ImGui::SetNextItemOpen( true );
}
bool treeNodeIsOpen = ImGui::TreeNodeEx( scenename, nodeFlags );
// Right-click menu, don't show for the unmanaged scene.
if( sceneindex != SCENEID_Unmanaged )
{
ImGui::PushID( scenename );
if( ImGui::BeginPopupContextItem( "ContextPopup", 1 ) )
{
AddContextMenuOptionsForCreatingGameObjects( nullptr, (SceneID)sceneindex );
if( ImGui::MenuItem( "Unload scene (TODO)" ) )
{
ImGui::CloseCurrentPopup();
}
ImGui::EndPopup();
}
ImGui::PopID();
}
if( treeNodeIsOpen )
{
// Add GameObjects that are in root.
GameObject* pGameObject = pSceneInfo->m_GameObjects.GetHead();
while( pGameObject )
{
// Add GameObjects, their children and their components.
AddGameObjectToObjectList( pGameObject, nullptr );
pGameObject = pGameObject->GetNext();
}
ImGui::TreePop();
}
}
}
}
AddPrefabFiles( forceOpen );
float cursorScreenPositionY = ImGui::GetCursorScreenPos().y;
float mousePositionY = ImGui::GetMousePos().y;
ImGui::EndChild();
// Clear the "reorder" line each frame.
// Done here after all gameobjects and the reorder line were drawn.
m_pGameObjectToDrawReorderLineAfter = nullptr;
// If GameObject is moved into blank area of object list, move it as last object in last scene.
if( mousePositionY > cursorScreenPositionY )
{
// Find the last scene.
int sceneIndex = 0;
for( sceneIndex=MAX_SCENES_LOADED-1; sceneIndex>=0; sceneIndex-- )
{
if( g_pComponentSystemManager->GetSceneInfo( (SceneID)sceneIndex )->m_InUse )
break;
}
// Check for dropped object and pretend we're hovering over last gameobject in that scene.
if( sceneIndex >= 0 )
{
SceneInfo* pSceneInfo = g_pComponentSystemManager->GetSceneInfo( (SceneID)sceneIndex );
GameObject* pGameObject = pSceneInfo->m_GameObjects.GetTail();
if( pGameObject )
{
OnDropObjectList( pGameObject, true );
}
}
}
if( m_ObjectListFilter[0] != '\0' )
{
ImGui::PopID(); // "FilteredList"
}
}
ImGui::End();
}
void EditorMainFrame_ImGui::AddPrefabFiles(bool forceOpen)
{
ImGuiTreeNodeFlags baseNodeFlags = ImGuiTreeNodeFlags_OpenOnArrow | ImGuiTreeNodeFlags_OpenOnDoubleClick;
unsigned int numPrefabFiles = g_pComponentSystemManager->m_pPrefabManager->GetNumberOfFiles();
if( numPrefabFiles > 0 )
{
if( ImGui::CollapsingHeader( "Prefab Files", ImGuiTreeNodeFlags_DefaultOpen ) || forceOpen )
{
for( unsigned int prefabFileIndex=0; prefabFileIndex<numPrefabFiles; prefabFileIndex++ )
{
ImGuiTreeNodeFlags nodeFlags = baseNodeFlags;
nodeFlags |= ImGuiTreeNodeFlags_DefaultOpen;
if( forceOpen )
{
ImGui::SetNextItemOpen( true );
}
PrefabFile* pPrefabFile = g_pComponentSystemManager->m_pPrefabManager->GetLoadedPrefabFileByIndex( prefabFileIndex );
MyAssert( pPrefabFile != nullptr );
const char* pPrefabFilename = pPrefabFile->GetFile()->GetFilename();
MyAssert( pPrefabFilename != nullptr );
bool treeNodeIsOpen = ImGui::TreeNodeEx( pPrefabFilename, nodeFlags );
ImGui::PushID( pPrefabFilename );
if( ImGui::BeginPopupContextItem( "ContextPopup", 1 ) )
{
//if( ImGui::MenuItem( "Add GameObject" ) )
//{
// pGameObjectCreated = g_pComponentSystemManager->CreateGameObject( true, (SceneID)sceneindex );
// pGameObjectCreated->SetName( "New Game Object" );
// ImGui::CloseCurrentPopup();
//}
ImGui::EndPopup();
}
ImGui::PopID();
if( treeNodeIsOpen )
{
// Add Prefab objects from this file.
PrefabObject* pPrefab = pPrefabFile->GetFirstPrefab();
while( pPrefab )
{
GameObject* pGameObject = pPrefab->GetGameObject();
if( pGameObject )
{
// Add GameObjects, their children and their components.
AddGameObjectToObjectList( pGameObject, pPrefab );
}
pPrefab = (PrefabObject*)pPrefab->GetNext();
}
ImGui::TreePop();
}
}
}
}
}
void EditorMainFrame_ImGui::AddGameObjectToObjectList(GameObject* pGameObject, PrefabObject* pPrefab)
{
if( pGameObject->IsManaged() == false && pPrefab == nullptr )
return;
float startCursorPositionX = ImGui::GetCursorPosX();
// If we're renaming the GameObject, show an edit box instead of a tree node.
if( pGameObject == m_pGameObjectWhoseNameIsBeingEdited )
{
ImGui::PushID( pGameObject );
ImGui::SetKeyboardFocusHere();
bool confirmed = ImGui::InputText( "New name", m_NameBeingEdited, 100, ImGuiInputTextFlags_AutoSelectAll|ImGuiInputTextFlags_EnterReturnsTrue );
// Any click will confirm the rename op, but cancel the confirmation if the click was in the edit box.
if( ImGui::IsItemClicked() )
{
m_ConfirmCurrentRenameOp = false;
}
// If 'enter' was pressed or another mouse click confirmed the change.
if( confirmed || m_ConfirmCurrentRenameOp )
{
m_pGameObjectWhoseNameIsBeingEdited->SetName( m_NameBeingEdited );
m_pGameObjectWhoseNameIsBeingEdited = nullptr;
m_RenamePressedThisFrame = false;
}
ImGui::PopID();
}
else
{
// If the object list filter has any characters in it.
if( m_ObjectListFilter[0] != '\0' )
{
// Check if this GameObject's name contains the substrings.
if( CheckIfMultipleSubstringsAreInString( pGameObject->GetName(), m_ObjectListFilter ) == false )
{
// Substrings weren't found, but might be in child GameObjects, so check/add those.
GameObject* pChildGameObject = pGameObject->GetFirstChild();
while( pChildGameObject )
{
AddGameObjectToObjectList( pChildGameObject, pPrefab );
pChildGameObject = pChildGameObject->GetNext();
}
// Substrings weren't found, so kick out.
return;
}
}
EditorState* pEditorState = m_pEngineCore->GetEditorState();
ImGuiTreeNodeFlags baseNodeFlags = ImGuiTreeNodeFlags_OpenOnArrow | ImGuiTreeNodeFlags_OpenOnDoubleClick;
ImGuiTreeNodeFlags nodeFlags = baseNodeFlags;
if( pEditorState->IsGameObjectSelected( pGameObject ) )
{
nodeFlags |= ImGuiTreeNodeFlags_Selected;
}
// If the gameobject is derived from a prefab or if it's disabled, change the color of the name.
int pushedColors = 0;
if( pGameObject->IsPrefabInstance() )
{
// TODO: put these colors into the preferences files.
if( pGameObject->IsEnabled() )
ImGui::PushStyleColor( ImGuiCol_Text, ImVec4( 0, 0.8f, 0, 1 ) );
else
ImGui::PushStyleColor( ImGuiCol_Text, ImVec4( 0, 0.5f, 0, 1 ) );
pushedColors++;
}
else if( pGameObject->IsEnabled() == false )
{
ImGui::PushStyleColor( ImGuiCol_Text, ImVec4( 0.5f, 0.5f, 0.5f, 1 ) );
pushedColors++;
}
// Add the GameObject itself to the tree.
char* icon = EditorIconString_GameObject;
if( pGameObject->IsFolder() )
icon = EditorIconString_Folder;
if( pGameObject->IsPrefabInstance() )
icon = EditorIconString_Prefab;
bool treeNodeIsOpen = ImGui::TreeNodeEx( pGameObject, nodeFlags, "%s %s", icon, pGameObject->GetName() );
ImGui::PopStyleColor( pushedColors );
ImGui::PushID( pGameObject );
// Start rename process on the first selected GameObject.
// Since 'enter' is a rename key, make sure the object wasn't already being renamed.
if( pEditorState->m_pSelectedObjects.size() > 0 )
{
if( ImGui::IsWindowFocused(ImGuiFocusedFlags_RootAndChildWindows) && m_RenamePressedThisFrame &&
pEditorState->m_pSelectedObjects[0] != m_pGameObjectWhoseNameIsBeingEdited )
{
StartRenameOp( pEditorState->m_pSelectedObjects[0], nullptr, pEditorState->m_pSelectedObjects[0]->GetName() );
}
}
if( ImGui::BeginPopupContextItem( "ContextPopup", 1 ) )
{
EditorState* pEditorState = m_pEngineCore->GetEditorState();
// If the right-clicked object isn't selected, then unselect what is and select just this one.
if( pEditorState->IsGameObjectSelected( pGameObject ) == false )
{
pEditorState->ClearSelectedObjectsAndComponents();
pEditorState->SelectGameObject( pGameObject );
}
if( pPrefab != nullptr )
{
int numselected = (int)m_pEngineCore->GetEditorState()->m_pSelectedObjects.size();
if( numselected > 1 )
{
if( ImGui::MenuItem( "Delete prefabs" ) )
{
g_pComponentSystemManager->m_pPrefabManager->DeleteSelectedPrefabs();
}
}
else
{
if( ImGui::MenuItem( "Delete prefab" ) )
{
g_pComponentSystemManager->m_pPrefabManager->DeleteSelectedPrefabs();
}
}
}
else
{
int numselected = (int)m_pEngineCore->GetEditorState()->m_pSelectedObjects.size();
// If multiple objects are selected, show these options first.
if( numselected > 1 )
{
if( ImGui::MenuItem( "Duplicate GameObjects (TODO)" ) ) { ImGui::CloseCurrentPopup(); }
if( ImGui::MenuItem( "Create Child GameObjects (TODO)" ) ) { ImGui::CloseCurrentPopup(); }
if( ImGui::MenuItem( "Delete GameObjects (TODO)" ) ) { ImGui::CloseCurrentPopup(); }
if( ImGui::MenuItem( "Clear Parents/Prefabs" ) ) { pGameObject->OnPopupClick( pGameObject, GameObject::RightClick_ClearParent ); ImGui::CloseCurrentPopup(); }
ImGui::Separator();
ImGui::Text( pGameObject->GetName() );
}
// Show options for the single item right-clicked.
{
// Menu options to add new components to a GameObject, don't allow components to be added to a folder.
if( pGameObject->IsFolder() == false )
{
if( ImGui::BeginMenu( "Add Component" ) )
{
AddContextMenuOptionsForAddingComponents( pGameObject );
ImGui::EndMenu();
}
}
// Menu options to add child GameObjects.
if( ImGui::BeginMenu( "Add Child" ) )
{
AddContextMenuOptionsForCreatingGameObjects( pGameObject, pGameObject->GetSceneID() );
ImGui::EndMenu();
}
if( ImGui::MenuItem( "Duplicate GameObject" ) ) { pGameObject->OnPopupClick( pGameObject, GameObject::RightClick_DuplicateGameObject ); ImGui::CloseCurrentPopup(); }
if( ImGui::MenuItem( "Create Child GameObject" ) ) { pGameObject->OnPopupClick( pGameObject, GameObject::RightClick_CreateChild ); ImGui::CloseCurrentPopup(); }
if( pGameObject->GetGameObjectThisInheritsFrom() )
{
if( ImGui::MenuItem( "Clear Parent/Prefab" ) ) { pGameObject->OnPopupClick( pGameObject, GameObject::RightClick_ClearParent ); ImGui::CloseCurrentPopup(); }
}
if( ImGui::BeginMenu( "Create prefab in" ) )
{
unsigned int numprefabfiles = g_pComponentSystemManager->m_pPrefabManager->GetNumberOfFiles();
for( unsigned int i=0; i<numprefabfiles; i++ )
{
PrefabFile* pPrefabFile = g_pComponentSystemManager->m_pPrefabManager->GetLoadedPrefabFileByIndex( i );
MyFileObject* pFile = pPrefabFile->GetFile();
MyAssert( pFile != nullptr );
if( ImGui::MenuItem( pFile->GetFilenameWithoutExtension() ) )
{
pGameObject->OnPopupClick( pGameObject, GameObject::RightClick_CreatePrefab + i );
ImGui::CloseCurrentPopup();
}
}
if( ImGui::MenuItem( "New/Load Prefab file... (TODO)" ) )
{
//pGameObject->OnPopupClick( pGameObject, GameObject::RightClick_CreatePrefab + numprefabfiles );
ImGui::CloseCurrentPopup();
}
ImGui::EndMenu();
}
if( ImGui::MenuItem( "Delete GameObject" ) )
{
// If the object isn't selected, delete just the one object, otherwise delete all selected objects.
if( pEditorState->IsGameObjectSelected( pGameObject ) )
{
pEditorState->DeleteSelectedObjects();
}
else
{
// Create a temp vector to pass into command.
std::vector<GameObject*> gameobjects;
gameobjects.push_back( pGameObject );
g_pGameCore->GetCommandStack()->Do( MyNew EditorCommand_DeleteObjects( gameobjects ) );
}
}
if( ImGui::MenuItem( "Rename" ) )
{
StartRenameOp( pGameObject, nullptr, pGameObject->GetName() );
ImGui::CloseCurrentPopup();
}
}
}
ImGui::EndPopup();
}
// Handle start of dragging either GameObjects or Prefabs.
if( ImGui::BeginDragDropSource() )
{
if( pPrefab != nullptr )
{
ImGui::SetDragDropPayload( "Prefab", &pPrefab, sizeof(pPrefab), ImGuiCond_Once );
}
else
{
ImGui::SetDragDropPayload( "GameObject", &pGameObject, sizeof(pGameObject), ImGuiCond_Once );
}
ImGui::Text( "%s", pGameObject->GetName() );
ImGui::EndDragDropSource();
}
// Handle dropping things on GameObjects or Prefabs.
bool dragDropPayloadAcceptedOnRelease = OnDropObjectList( pGameObject, false );
ImGui::PopID(); // ImGui::PushID( pGameObject );
bool hoveringOverArrow = ImGuiExt::IsMouseHoveringOverItemExpansionArrow();
// Select the GameObject if it's clicked.
// The code selects on mouse release so items can be dragged without changing selection.
// Also handles Ctrl and Shift clicks for multiple selections.
// Expand the item without selecting it if the arrow is clicked.
if( ImGui::IsMouseReleased( 0 ) && ImGui::IsItemHovered() &&
hoveringOverArrow == false && dragDropPayloadAcceptedOnRelease == false )
{
if( ImGui::GetIO().KeyShift == true )
{
// Select all GameObjects between last interacted object in list and this one.
pEditorState->ClearSelectedObjectsAndComponents();
SceneInfo* pSceneInfo = g_pComponentSystemManager->GetSceneInfo( pGameObject->GetSceneID() );
GameObject* pFirstGameObjectInScene = pSceneInfo->m_GameObjects.GetHead();
// If there was no item previously interacted with, set it to the first object in the scene.
if( m_pLastGameObjectInteractedWithInObjectPanel == nullptr )
{
m_pLastGameObjectInteractedWithInObjectPanel = pFirstGameObjectInScene;
}
// Loop through the gameobjects moving forward looking for the selected one.
// TODO: recurse through children (if visible?)
// TODO: select all object inside folders?
bool found = false;
GameObject* pCurrentGameObject = m_pLastGameObjectInteractedWithInObjectPanel;
while( true )
{
pEditorState->SelectGameObject( pCurrentGameObject );
// If we hit the selected object.
if( pCurrentGameObject == pGameObject )
{
found = true;
break;
}
pCurrentGameObject = pCurrentGameObject->GetNext();
if( pCurrentGameObject == nullptr )
break;
}
// If we didn't find it going forward, clear the list and try in reverse.
if( found == false )
{
pEditorState->ClearSelectedObjectsAndComponents();
GameObject* pCurrentGameObject = m_pLastGameObjectInteractedWithInObjectPanel;
while( true )
{
pEditorState->SelectGameObject( pCurrentGameObject );
// If we hit the selected object.
if( pCurrentGameObject == pGameObject )
{
found = true;
break;
}
pCurrentGameObject = pCurrentGameObject->GetPrev();
if( pCurrentGameObject == nullptr )
break;
}
}
}
else
{
// If control isn't held, clear the selected objects.
if( ImGui::GetIO().KeyCtrl == false )
{
pEditorState->ClearSelectedObjectsAndComponents();
}
// If there are any selected items and there's a mix of gameobjects and prefabs, then unselect all.
if( pEditorState->m_pSelectedObjects.size() > 0 )
{
bool gameObjectIsMasterPrefab = pGameObject->GetPrefabRef()->IsMasterPrefabGameObject();
bool firstSelectedGameObjectIsMasterPrefab = pEditorState->m_pSelectedObjects[0]->GetPrefabRef()->IsMasterPrefabGameObject();
if( gameObjectIsMasterPrefab == true && firstSelectedGameObjectIsMasterPrefab == false )
pEditorState->ClearSelectedObjectsAndComponents();
if( gameObjectIsMasterPrefab == false && firstSelectedGameObjectIsMasterPrefab == true )
pEditorState->ClearSelectedObjectsAndComponents();
}
if( pEditorState->IsGameObjectSelected( pGameObject ) )
{
m_pLastGameObjectInteractedWithInObjectPanel = pGameObject;
pEditorState->UnselectGameObject( pGameObject );
}
else
{
m_pLastGameObjectInteractedWithInObjectPanel = pGameObject;
pEditorState->SelectGameObject( pGameObject );
// If this is a folder and it's the only selection, then select all objects inside the folder as well.
if( pGameObject->IsFolder() && pEditorState->m_pSelectedObjects.size() == 1 )
{
for( GameObject* pChildGameObject = pGameObject->GetChildList()->GetHead(); pChildGameObject; pChildGameObject = pChildGameObject->GetNext() )
{
if( pChildGameObject->IsManaged() )
{
pChildGameObject->AddToList( &pEditorState->m_pSelectedObjects );
}
}
}
}
}
}
// Deal with slow double-click for renaming GameObjects.
if( WasItemSlowDoubleClicked( pGameObject ) )
{
StartRenameOp( pGameObject, nullptr, pGameObject->GetName() );
}
bool forceOpen = false;
if( treeNodeIsOpen == false && pEditorState->IsGameObjectAParentOfASelectedObjectOrComponent( pGameObject ) )
{
ImGui::Indent();
forceOpen = true;
}
if( treeNodeIsOpen || forceOpen )
{
// Add Child GameObjects.
GameObject* pChildGameObject = pGameObject->GetFirstChild();
while( pChildGameObject )
{
AddGameObjectToObjectList( pChildGameObject, pPrefab );
pChildGameObject = pChildGameObject->GetNext();
}
// Don't show components, deleted prefab children or deleted prefab components if forced open.
if( forceOpen == false )
{
// Add Components.
for( unsigned int ci=0; ci<pGameObject->GetComponentCountIncludingCore(); ci++ )
{
ComponentBase* pComponent = pGameObject->GetComponentByIndexIncludingCore( ci );
if( pComponent )
{
if( pComponent->IsA( "GameObjectPropertiesComponent" ) )
continue;
ImGuiTreeNodeFlags nodeFlags = ImGuiTreeNodeFlags_Leaf;
if( pEditorState->IsComponentSelected( pComponent ) )
{
nodeFlags |= ImGuiTreeNodeFlags_Selected;
}
if( ImGui::TreeNodeEx( pComponent, nodeFlags, pComponent->GetClassname() ) )
{
if( ImGui::BeginPopupContextItem( "ContextPopup", 1 ) )
{
// If the right-clicked object isn't selected, then unselect what is and select just this one.
if( pEditorState->IsComponentSelected( pComponent ) == false )
{
pEditorState->ClearSelectedObjectsAndComponents();
pEditorState->SelectComponent( pComponent );
}
char* label = "Delete Component";
if( pEditorState->m_pSelectedComponents.size() > 1 )
{
label = "Delete Selected Components";
}
if( ImGui::MenuItem( label ) )
{
pComponent->OnRightClickAction( ComponentBase::RightClick_DeleteComponent );
ImGui::CloseCurrentPopup();
}
ImGui::EndPopup();
}
// Handle start of dragging of Components.
if( ImGui::BeginDragDropSource() )
{
ImGui::SetDragDropPayload( "Component", &pComponent, sizeof(pComponent), ImGuiCond_Once );
ImGui::Text( "%s:%s", pGameObject->GetName(), pComponent->GetClassname() );
ImGui::EndDragDropSource();
}
ImGui::TreePop();
}
if( ImGui::IsItemClicked() )
{
if( ImGui::GetIO().KeyCtrl == false )
{
pEditorState->ClearSelectedObjectsAndComponents();
}
if( ImGui::GetIO().KeyShift == false )
{
// TODO: select all Components between last object in list and this one.
}
if( pEditorState->IsComponentSelected( pComponent ) )
{
pEditorState->UnselectComponent( pComponent );
}
else
{
pEditorState->SelectComponent( pComponent );
}
}
}
}
// Add List of deleted Prefab Children.
for( unsigned int dpci=0; dpci<pGameObject->m_DeletedPrefabChildIDs.size(); dpci++ )
{
uint32 deletedPrefabChildID = pGameObject->m_DeletedPrefabChildIDs[dpci];
GameObject* pChildGameObject = pGameObject->GetPrefabRef()->GetPrefab()->FindChildGameObject( deletedPrefabChildID );
ImGuiTreeNodeFlags nodeFlags = ImGuiTreeNodeFlags_Leaf;
if( ImGui::TreeNodeEx( pChildGameObject, nodeFlags, "Deleted: %s", pChildGameObject->GetName() ) )
{
// if( ImGui::BeginPopupContextItem( "ContextPopup", 1 ) )
// {
// char* label = "Restore Component";
// if( pEditorState->m_pSelectedComponents.size() > 1 )
// {
// label = "Restore Selected Components";
// }
// if( ImGui::MenuItem( label ) )
// {
// g_pGameCore->GetCommandStack()->Do( MyNew EditorCommand_RestorePrefabComponent( pGameObject, deletedPrefabComponentID ) );
// ImGui::CloseCurrentPopup();
// }
// ImGui::EndPopup();
// }
ImGui::TreePop();
}
}
// Add List of deleted Prefab Components.
for( unsigned int dpci=0; dpci<pGameObject->m_DeletedPrefabComponentIDs.size(); dpci++ )
{
uint32 deletedPrefabComponentID = pGameObject->m_DeletedPrefabComponentIDs[dpci];
ComponentBase* pComponent = pGameObject->GetPrefabRef()->GetGameObject()->FindComponentByPrefabComponentID( deletedPrefabComponentID );
ImGuiTreeNodeFlags nodeFlags = ImGuiTreeNodeFlags_Leaf;
if( ImGui::TreeNodeEx( pComponent, nodeFlags, "Deleted: %s", pComponent->GetClassname() ) )
{
if( ImGui::BeginPopupContextItem( "ContextPopup", 1 ) )
{
char* label = "Restore Component";
if( pEditorState->m_pSelectedComponents.size() > 1 )
{
label = "Restore Selected Components";
}
if( ImGui::MenuItem( label ) )
{
g_pGameCore->GetCommandStack()->Do( MyNew EditorCommand_RestorePrefabComponent( pGameObject, deletedPrefabComponentID ) );
ImGui::CloseCurrentPopup();
}
ImGui::EndPopup();
}
ImGui::TreePop();
}
}
}
if( treeNodeIsOpen )
ImGui::TreePop();
if( forceOpen )
ImGui::Unindent();
}
}
// Draw a horizontal line to indicate the drag/drop will do a reorder and not a reparent.
if( m_pGameObjectToDrawReorderLineAfter == pGameObject )
{
ImGuiExt::DrawBlock( startCursorPositionX - 5.0f, -3.0f, 8888.0f, 2.0f, ImGuiCol_DragDropTarget );
}
}
void EditorMainFrame_ImGui::AddWatchPanel()
{
EditorPrefs* pEditorPrefs = m_pEngineCore->GetEditorPrefs();
if( m_pCurrentLayout->m_IsWindowOpen[EditorWindow_Watch] == false )
return;
ImGui::SetNextWindowPos( ImVec2(852, 25), ImGuiCond_FirstUseEver );
ImGui::SetNextWindowSize( ImVec2(333, 395), ImGuiCond_FirstUseEver );
if( ImGui::Begin( "Watch", &m_pCurrentLayout->m_IsWindowOpen[EditorWindow_Watch] ) )
{
EditorState* pEditorState = m_pEngineCore->GetEditorState();
int numGameObjectsSelected = (int)pEditorState->m_pSelectedObjects.size();
// If multiple objects are selected, show their shared components.
// If only one object is selected, just show it's components (will show nothing for empty folders).
if( numGameObjectsSelected > 0 )
{
// Pick the first game object, even it it's a folder.
GameObject* pFirstGameObject = pEditorState->m_pSelectedObjects[0];
int firstGameObjectIndex = 0;
// Find the first non-folder object if there is one, since folders shouldn't have components.
int numNonFoldersSelected = 0;
for( unsigned int i=0; i<pEditorState->m_pSelectedObjects.size(); i++ )
{
if( pEditorState->m_pSelectedObjects[i]->IsFolder() == false )
{
if( numNonFoldersSelected == 0 )
{
pFirstGameObject = pEditorState->m_pSelectedObjects[i];
firstGameObjectIndex = i;
}
numNonFoldersSelected++;
}
}
if( numNonFoldersSelected > 1 )
{
ImGui::Text( "%d objects selected.", numNonFoldersSelected );
}
else
{
GameObject* pGameObjectThisInheritsFrom = pFirstGameObject->GetGameObjectThisInheritsFrom();
if( pGameObjectThisInheritsFrom == nullptr )
{
ImGui::Text( "%s", pFirstGameObject->GetName() );
}
else
{
ImGui::Text( "%s (%s)", pFirstGameObject->GetName(), pGameObjectThisInheritsFrom->GetName() );
}
ImGui::SameLine();
if( pFirstGameObject->IsEnabled() )
{
if( ImGui::Button( "Disable" ) )
g_pGameCore->GetCommandStack()->Do( MyNew EditorCommand_EnableObject( pFirstGameObject, false, true ) );
}
else
{
if( ImGui::Button( "Enable" ) )
g_pGameCore->GetCommandStack()->Do( MyNew EditorCommand_EnableObject( pFirstGameObject, true, true ) );
}
}
// Only show components for non-folder objects.
if( pFirstGameObject->IsFolder() == false )
{
// Show common components of all selected Gameobjects:
{
// Search all components including GameObject properties and transform.
for( unsigned int foci=0; foci<pFirstGameObject->GetComponentCountIncludingCore(); foci++ )
{
ComponentBase* pComponentToLookFor = pFirstGameObject->GetComponentByIndexIncludingCore( foci );
MyAssert( pComponentToLookFor );
pComponentToLookFor->m_MultiSelectedComponents.clear();
// Loop through selected gameobjects and check if they all have to least one of this component type on them.
bool allGameObjectsHaveComponent = true;
for( unsigned int soi=firstGameObjectIndex+1; soi<pEditorState->m_pSelectedObjects.size(); soi++ )
{
GameObject* pGameObject = pEditorState->m_pSelectedObjects[soi];
MyAssert( pGameObject != pFirstGameObject );
// Skip folders, since they shouldn't have components.
if( pGameObject->IsFolder() )
continue;
bool hasComponent = false;
for( unsigned int soci=0; soci<pGameObject->GetComponentCountIncludingCore(); soci++ )
{
ComponentBase* pOtherComponent = pGameObject->GetComponentByIndexIncludingCore( soci );
if( pOtherComponent && pOtherComponent->IsA( pComponentToLookFor->GetClassname() ) == true )
{
pComponentToLookFor->m_MultiSelectedComponents.push_back( pOtherComponent );
hasComponent = true;
break;
}
}
if( hasComponent == false )
{
allGameObjectsHaveComponent = false;
break;
}
}
if( allGameObjectsHaveComponent == true )
{
//ImGui::PushStyleColor( ImGuiCol_Header, (ImVec4)ImColor::ImColor(50,100,0,255) );
//ImGui::PushStyleColor( ImGuiCol_HeaderHovered, (ImVec4)ImColor::ImColor(50,70,0,255) );
//ImGui::PushStyleColor( ImGuiCol_HeaderActive, (ImVec4)ImColor::ImColor(50,30,0,255) );
ImGui::PushID( pComponentToLookFor );
Vector4 bgColor = pEditorPrefs->GetImGuiStylePrefs()->GetColor( ImGuiStylePrefs::StylePref_Color_Header );
Vector4 checkColor = pEditorPrefs->GetImGuiStylePrefs()->GetColor( ImGuiStylePrefs::StylePref_Color_CheckMark );
ImGui::PushStyleColor( ImGuiCol_FrameBg, bgColor );
ImGui::PushStyleColor( ImGuiCol_CheckMark, checkColor );
// Draw the enabled/disabled checkbox.
ComponentBase::EnabledState enabledState = pComponentToLookFor->GetEnabledState();
bool enabled = true;
if( enabledState == ComponentBase::EnabledState_Disabled_ManuallyDisabled )
{
enabled = false;
}
if( ImGui::Checkbox( "", &enabled ) )
{
pComponentToLookFor->SetEnabled( enabled );
}
ImGui::PopStyleColor( 2 );
ImGui::SameLine();
ImGui::SetCursorPosX( ImGui::GetCursorPosX() - 5 );
// Draw the component name in a collapsable block.
bool componentBlockIsOpen = ImGui::CollapsingHeader( pComponentToLookFor->GetClassname(), ImGuiTreeNodeFlags_DefaultOpen );
// Add context menu on the collapsingHeader.
if( ImGui::BeginPopupContextItem( "ContextPopup", 1 ) )
{
if( pComponentToLookFor->m_MultiSelectedComponents.size() == 0 )
{
if( ImGui::MenuItem( "Delete Component" ) )
{
std::vector<ComponentBase*> componentsToDelete;
componentsToDelete.push_back( pComponentToLookFor );
g_pEngineCore->GetCommandStack()->Do( MyNew EditorCommand_DeleteComponents( componentsToDelete ) );
ImGui::CloseCurrentPopup();
}
}
else
{
if( ImGui::MenuItem( "Delete Components" ) )
{
// Add pComponentToLookFor and pComponentToLookFor->m_MultiSelectedComponents to a vector and delete them.
std::vector<ComponentBase*> componentsToDelete;
componentsToDelete.push_back( pComponentToLookFor );
componentsToDelete.insert( componentsToDelete.end(), pComponentToLookFor->m_MultiSelectedComponents.begin(), pComponentToLookFor->m_MultiSelectedComponents.end() );
g_pEngineCore->GetCommandStack()->Do( MyNew EditorCommand_DeleteComponents( componentsToDelete ) );
ImGui::CloseCurrentPopup();
}
}
ImGui::EndPopup();
}
// Add contents of component if collapsingHeader is open.
if( componentBlockIsOpen )
{
pComponentToLookFor->AddAllVariablesToWatchPanel( m_pCommandStack );
}
ImGui::PopID();
//ImGui::PopStyleColor( 3 );
}
}
}
}
}
else
{
// No GameObjects selected, display components.
int numselected = (int)m_pEngineCore->GetEditorState()->m_pSelectedComponents.size();
if( numselected == 1 )
{
ImGui::Text( "%d component selected.", numselected );
ComponentBase* pComponent = m_pEngineCore->GetEditorState()->m_pSelectedComponents[0];
//ImGui::PushStyleColor( ImGuiCol_Header, (ImVec4)ImColor::ImColor(50,100,0,255) );
//ImGui::PushStyleColor( ImGuiCol_HeaderHovered, (ImVec4)ImColor::ImColor(50,70,0,255) );
//ImGui::PushStyleColor( ImGuiCol_HeaderActive, (ImVec4)ImColor::ImColor(50,30,0,255) );
if( ImGui::CollapsingHeader( pComponent->GetClassname(), ImGuiTreeNodeFlags_DefaultOpen ) )
{
//ImGui::Text( "TODO: Component Info." );
ImGui::PushID( pComponent );
pComponent->AddAllVariablesToWatchPanel( m_pCommandStack );
ImGui::PopID();
}
//ImGui::PopStyleColor( 3 );
}
else
{
ImGui::Text( "%d components selected.", numselected );
// Loop through all selected components:
for( unsigned int i=0; i<pEditorState->m_pSelectedComponents.size(); i++ )
{
ComponentBase* pInitialComponent = pEditorState->m_pSelectedComponents[i];
// Clear this components MultiSelected list.
pInitialComponent->m_MultiSelectedComponents.clear();
// Have we shown this type yet?
bool alreadyShowedThisType = false;
for( unsigned int j=0; j<i; j++ )
{
ComponentBase* pComponent = pEditorState->m_pSelectedComponents[j];
if( pComponent && pComponent->IsA( pInitialComponent->GetClassname() ) == true )
alreadyShowedThisType = true;
}
if( alreadyShowedThisType == false )
{
pInitialComponent->m_MultiSelectedComponents.push_back( pInitialComponent );
// Loop through the rest of the selected components again to find common ones:
for( unsigned int j=i+1; j<pEditorState->m_pSelectedComponents.size(); j++ )
{
ComponentBase* pComponent = pEditorState->m_pSelectedComponents[j];
MyAssert( pComponent );
// If they're the same type, fill the MultiSelected list with the other components.
if( pComponent && pComponent->IsA( pInitialComponent->GetClassname() ) == true )
{
pInitialComponent->m_MultiSelectedComponents.push_back( pComponent );
}
}
// Show all the components in the watch window.
//ImGui::PushStyleColor( ImGuiCol_Header, (ImVec4)ImColor::ImColor(50,100,0,255) );
//ImGui::PushStyleColor( ImGuiCol_HeaderHovered, (ImVec4)ImColor::ImColor(50,70,0,255) );
//ImGui::PushStyleColor( ImGuiCol_HeaderActive, (ImVec4)ImColor::ImColor(50,30,0,255) );
if( ImGui::CollapsingHeader( pInitialComponent->GetClassname(), ImGuiTreeNodeFlags_DefaultOpen ) )
{
ImGui::PushID( pInitialComponent );
pInitialComponent->AddAllVariablesToWatchPanel( m_pCommandStack );
ImGui::PopID();
}
//ImGui::PopStyleColor( 3 );
}
}
}
}
// Create dummy control in empty region to allow for context menu.
{
ImVec2 regionAvailable = ImGui::GetContentRegionAvail();
if( regionAvailable.y < 50 )
regionAvailable.y = 50;
ImGui::Dummy( regionAvailable );
// Only works when a single GameObject is selected. TODO: Make this work with multiple.
if( numGameObjectsSelected == 1 )
{
// Pick the first game object, even if it's a folder.
GameObject* pFirstGameObject = pEditorState->m_pSelectedObjects[0];
ImGui::PushID( pFirstGameObject );
if( ImGui::BeginPopupContextItem( "ContextPopup", 1 ) )
{
AddContextMenuOptionsForAddingComponents( pFirstGameObject );
ImGui::EndPopup();
}
ImGui::PopID();
}
}
}
ImGui::End();
}
void EditorMainFrame_ImGui::AddLogWindow()
{
ImGui::SetNextWindowSize( ImVec2(842, 167), ImGuiCond_FirstUseEver );
ImGui::SetNextWindowPos( ImVec2(6, 476), ImGuiCond_FirstUseEver );
if( m_pCurrentLayout->m_IsWindowOpen[EditorWindow_Log] )
{
m_pLogWindow->Draw( "Log", &m_pCurrentLayout->m_IsWindowOpen[EditorWindow_Log] );
}
}
void EditorMainFrame_ImGui::AddMemoryWindow()
{
#if MYFW_WINDOWS && MYFW_USE_MEMORY_TRACKER
ImGui::SetNextWindowSize( ImVec2(842, 167), ImGuiCond_FirstUseEver );
ImGui::SetNextWindowPos( ImVec2(6, 476), ImGuiCond_FirstUseEver );
if( m_pCurrentLayout->m_IsWindowOpen[EditorWindow_Debug_MemoryAllocations] )
{
m_pMemoryWindow->DrawStart( "Memory Allocations", &m_pCurrentLayout->m_IsWindowOpen[EditorWindow_Debug_MemoryAllocations] );
if( ImGui::Button( "Refresh" ) )
{
m_pMemoryWindow->Clear();
for( CPPListNode* pNode = MyMemory_GetFirstMemObject(); pNode; pNode = pNode->GetNext() )
{
MemObject* pMem = (MemObject*)pNode;
m_pMemoryWindow->AddEntry( pMem->m_File, pMem->m_Line, (uint32)pMem->m_Size );
}
}
char temp[32];
PrintNumberWithCommas( temp, 32, MyMemory_GetNumberOfMemoryAllocations() );
ImGui::Text( "Total Allocations: %s", temp );
PrintNumberWithCommas( temp, 32, MyMemory_GetNumberOfActiveMemoryAllocations() );
ImGui::Text( "Active Allocations: %s", temp );
PrintNumberWithCommas( temp, 32, (uint32)MyMemory_GetNumberOfBytesAllocated() );
ImGui::Text( "Active Bytes Allocated: %s", temp );
m_pMemoryWindow->DrawMid();
m_pMemoryWindow->DrawEnd();
}
#endif //MYFW_WINDOWS && MYFW_USE_MEMORY_TRACKER
}
void EditorMainFrame_ImGui::AddCommandStacksWindow()
{
if( m_pCurrentLayout->m_IsWindowOpen[EditorWindow_Debug_CommandStacks] == false )
return;
ImGui::SetNextWindowPos( ImVec2(6, 476), ImGuiCond_FirstUseEver );
ImGui::SetNextWindowSize( ImVec2(842, 167), ImGuiCond_FirstUseEver );
if( ImGui::Begin( "Undo/Redo", &m_pCurrentLayout->m_IsWindowOpen[EditorWindow_Resources] ) )
{
CommandStack* pCommandStack = m_pEngineCore->GetCommandStack();
if( pCommandStack )
{
if( ImGui::CollapsingHeader( "Undo Commands", nullptr, ImGuiTreeNodeFlags_DefaultOpen ) )
{
for( uint32 i=pCommandStack->GetUndoStackSize(); i>0; i-- )
{
EditorCommand* pCommand = pCommandStack->GetUndoCommandAtIndex( i-1 );
ImGui::Text( "%s", pCommand->GetName() );
}
}
if( ImGui::CollapsingHeader( "Redo Commands", nullptr, ImGuiTreeNodeFlags_DefaultOpen ) )
{
for( uint32 i=pCommandStack->GetRedoStackSize(); i>0; i-- )
{
EditorCommand* pCommand = pCommandStack->GetRedoCommandAtIndex( i-1 );
ImGui::Text( "%s", pCommand->GetName() );
}
}
}
}
ImGui::End();
}
void EditorMainFrame_ImGui::AddMemoryPanel()
{
if( m_pCurrentLayout->m_IsWindowOpen[EditorWindow_Resources] == false )
return;
ImGui::SetNextWindowPos( ImVec2(853, 424), ImGuiCond_FirstUseEver );
ImGui::SetNextWindowSize( ImVec2(334, 220), ImGuiCond_FirstUseEver );
if( ImGui::Begin( "Resources", &m_pCurrentLayout->m_IsWindowOpen[EditorWindow_Resources] ) )
{
// Add an input box for memory panel filter.
// For now, it will always auto-select the text when given focus.
{
ImGuiInputTextFlags inputTextFlags = ImGuiInputTextFlags_AutoSelectAll;
if( m_SetMemoryPanelFilterBoxInFocus )
{
//inputTextFlags |= ImGuiInputTextFlags_AutoSelectAll;
ImGui::SetKeyboardFocusHere();
m_SetMemoryPanelFilterBoxInFocus = false;
}
ImGui::InputText( "Filter", m_MemoryPanelFilter, 100, inputTextFlags );
ImGui::SameLine();
if( ImGui::Button( "X" ) )
{
m_MemoryPanelFilter[0] = '\0';
}
}
// If a filter is set, show all types.
if( m_MemoryPanelFilter[0] != '\0' )
{
ImGui::BeginChild( "Memory Details" );
AddMemoryPanel_Materials();
AddMemoryPanel_Textures();
AddMemoryPanel_ShaderGroups();
AddMemoryPanel_Files();
ImGui::EndChild();
}
else
{
if( ImGui::BeginTabBar( "MemoryPages" ) )
{
if( ImGui::BeginTabItem( "Materials" ) )
{
ImGui::EndTabItem();
ImGui::BeginChild( "Memory Details" );
AddMemoryPanel_Materials();
ImGui::EndChild();
}
if( ImGui::BeginTabItem( "Textures" ) )
{
ImGui::EndTabItem();
ImGui::BeginChild( "Memory Details" );
AddMemoryPanel_Textures();
ImGui::EndChild();
}
if( ImGui::BeginTabItem( "Shaders" ) )
{
ImGui::EndTabItem();
ImGui::BeginChild( "Memory Details" );
AddMemoryPanel_ShaderGroups();
ImGui::EndChild();
}
if( ImGui::BeginTabItem( "Sound Cues" ) )
{
ImGui::EndTabItem();
ImGui::BeginChild( "Memory Details" );
AddMemoryPanel_SoundCues();
ImGui::EndChild();
}
if( ImGui::BeginTabItem( "Files" ) )
{
ImGui::EndTabItem();
ImGui::BeginChild( "Memory Details" );
AddMemoryPanel_Files();
ImGui::EndChild();
}
if( ImGui::BeginTabItem( "Buffers" ) )
{
ImGui::EndTabItem();
ImGui::BeginChild( "Memory Details" );
ImGui::Text( "TODO" );
ImGui::EndChild();
}
if( ImGui::BeginTabItem( "Draw Calls" ) )
{
ImGui::EndTabItem();
ImGui::BeginChild( "Memory Details" );
AddMemoryPanel_DrawCalls();
ImGui::EndChild();
}
ImGui::EndTabBar();
}
}
}
ImGui::End();
}
void EditorMainFrame_ImGui::AddContextMenuOptionsForAddingComponents(GameObject* pGameObject)
{
int first = 0;
if( pGameObject->GetTransform() != nullptr )
first = 1;
const char* lastcategory = nullptr;
bool menuopen = false;
unsigned int numtypes = g_pComponentSystemManager->GetComponentTypeManager()->GetNumberOfComponentTypes();
for( unsigned int i=first; i<numtypes; i++ )
{
const char* currentcategory = g_pComponentSystemManager->GetComponentTypeManager()->GetTypeCategory( i );
const char* nextcategory = nullptr;
if( i < numtypes-1 )
nextcategory = g_pComponentSystemManager->GetComponentTypeManager()->GetTypeCategory( i+1 );
if( lastcategory != currentcategory )
{
menuopen = ImGui::BeginMenu( currentcategory );
}
if( menuopen )
{
if( i == ComponentType_Mesh )
{
// Don't include ComponentType_Mesh in the right-click menu.
// TODO: If more exceptions are made, improve this system.
}
else
{
if( ImGui::MenuItem( g_pComponentSystemManager->GetComponentTypeManager()->GetTypeName( i ) ) )
{
ComponentBase* pComponent = nullptr;
if( m_pEngineCore->IsInEditorMode() )
{
EditorCommand_CreateComponent* pCommand = MyNew EditorCommand_CreateComponent( pGameObject, i );
g_pGameCore->GetCommandStack()->Do( pCommand );
pComponent = pCommand->GetCreatedObject();
pComponent->OnLoad();
}
else
{
pComponent = pGameObject->AddNewComponent( i, SCENEID_Unmanaged, g_pComponentSystemManager );
}
ImGui::CloseCurrentPopup();
}
}
}
if( menuopen && currentcategory != nextcategory )
{
ImGui::EndMenu();
}
lastcategory = currentcategory;
}
}
void EditorMainFrame_ImGui::AddContextMenuOptionsForCreatingGameObjects(GameObject* pParentGameObject, SceneID sceneID)
{
GameObject* pGameObjectCreated = nullptr;
if( ImGui::MenuItem( "Add GameObject" ) )
{
pGameObjectCreated = g_pComponentSystemManager->CreateGameObject( true, sceneID );
pGameObjectCreated->SetName( "New Game Object" );
ImGui::CloseCurrentPopup();
}
if( ImGui::BeginMenu( "Add GameObject from Template" ) )
{
GameObjectTemplateManager* pManager = g_pComponentSystemManager->m_pGameObjectTemplateManager;
cJSON* jFirstParent = pManager->GetParentTemplateJSONObject( 0 );
unsigned int i = 0;
while( i < pManager->GetNumberOfTemplates() )
{
bool isFolder = pManager->IsTemplateAFolder( i );
const char* name = pManager->GetTemplateName( i );
if( isFolder == false )
{
if( ImGui::MenuItem( name ) )
{
pGameObjectCreated = g_pComponentSystemManager->CreateGameObjectFromTemplate( i, sceneID );
if( pGameObjectCreated )
{
EditorState* pEditorState = m_pEngineCore->GetEditorState();
pEditorState->ClearSelectedObjectsAndComponents();
pEditorState->SelectGameObject( pGameObjectCreated );
}
}
}
i++;
}
ImGui::EndMenu();
}
// Don't allow folders other than at root on as children to other folders.
if( pParentGameObject == nullptr || pParentGameObject->IsFolder() )
{
if( ImGui::MenuItem( "Add Folder" ) )
{
pGameObjectCreated = g_pComponentSystemManager->CreateGameObject( true, sceneID, true, false );
pGameObjectCreated->SetName( "New Folder" );
ImGui::CloseCurrentPopup();
}
}
if( ImGui::MenuItem( "Add Logical GameObject" ) )
{
pGameObjectCreated = g_pComponentSystemManager->CreateGameObject( true, sceneID, false, false );
pGameObjectCreated->SetName( "New Logical Game Object" );
ImGui::CloseCurrentPopup();
}
if( pGameObjectCreated )
{
if( pParentGameObject )
{
pGameObjectCreated->SetParentGameObject( pParentGameObject );
}
g_pGameCore->GetCommandStack()->Add( MyNew EditorCommand_CreateGameObject( pGameObjectCreated ) );
}
}
void EditorMainFrame_ImGui::AddContextMenuItemsForFiles(MyFileObject* pFile, void* pSelectedObject)
{
FileManager* pFileManager = m_pEngineCore->GetManagers()->GetFileManager();
const char* extension = pFile->GetExtensionWithDot();
if( strcmp( extension, ".my2daniminfo" ) == 0 )
{
if( ImGui::MenuItem( "Edit 2D Anim Info", nullptr, &m_pCurrentLayout->m_IsWindowOpen[EditorWindow_2DAnimationEditor] ) )
{
My2DAnimInfo* pAnim = g_pComponentSystemManager->GetFileInfoIfUsedByScene( pFile, SCENEID_Any )->Get2DAnimInfo();
Edit2DAnimInfo( pAnim );
ImGui::CloseCurrentPopup();
}
}
else if( pSelectedObject != nullptr && strcmp( extension, ".glsl" ) == 0 )
{
if( ImGui::MenuItem( "Create Material Using Shader" ) )
{
MaterialManager* pMaterialManager = m_pEngineCore->GetManagers()->GetMaterialManager();
MaterialDefinition* pMat = pMaterialManager->CreateMaterial( pFile->GetFilenameWithoutExtension(), "Data/Materials" );
pMat->SetShader( (ShaderGroup*)pSelectedObject );
ImGui::CloseCurrentPopup();
}
}
else
{
if( ImGui::MenuItem( "View in Watch Window (TODO)" ) ) { pFile->OnPopupClick( pFileManager, pFile, MyFileObject::RightClick_ViewInWatchWindow ); ImGui::CloseCurrentPopup(); }
}
if( ImGui::MenuItem( "Open File" ) ) { pFile->OnPopupClick( pFileManager, pFile, MyFileObject::RightClick_OpenFile ); ImGui::CloseCurrentPopup(); }
if( ImGui::MenuItem( "Open Containing Folder" ) ) { pFile->OnPopupClick( pFileManager, pFile, MyFileObject::RightClick_OpenContainingFolder ); ImGui::CloseCurrentPopup(); }
if( ImGui::MenuItem( "Unload File" ) ) { pFile->OnPopupClick( pFileManager, pFile, MyFileObject::RightClick_UnloadFile ); ImGui::CloseCurrentPopup(); }
if( ImGui::MenuItem( "Find References" ) ) { pFile->OnPopupClick( pFileManager, pFile, MyFileObject::RightClick_FindAllReferences ); ImGui::CloseCurrentPopup(); } // (%d)", pMat->GetRefCount() ) {}
}
void EditorMainFrame_ImGui::AddContextMenuItemsForMaterials(MaterialDefinition* pMaterial)
{
// Clear is handled in ComponentBase::AddVariableToWatchPanel.
if( ImGui::MenuItem( "Edit material" ) )
{
EditMaterial( pMaterial );
}
}
void EditorMainFrame_ImGui::AddMemoryPanel_Materials()
{
// Only show the headers if the filter is blank.
bool showHeaders = (m_MemoryPanelFilter[0] == '\0');
bool someMaterialsAreLoaded = false;
//unsigned int numMaterialsShown = 0;
for( int i=0; i<2; i++ )
{
MaterialManager* pMaterialManager = m_pEngineCore->GetManagers()->GetMaterialManager();
//MaterialDefinition* pMat = pMaterialManager->GetFirstMaterial();
MaterialDefinition* pMat = pMaterialManager->Editor_GetFirstMaterialStillLoading();
if( i == 1 )
pMat = pMaterialManager->Editor_GetFirstMaterialLoaded();
if( pMat == nullptr )
continue;
someMaterialsAreLoaded = true;
ImGuiTreeNodeFlags baseNodeFlags = ImGuiTreeNodeFlags_OpenOnArrow | ImGuiTreeNodeFlags_OpenOnDoubleClick;
char* label = "Materials - Loading";
ImGuiTreeNodeFlags nodeFlags = baseNodeFlags;
if( i == 1 )
{
label = "All Materials";
nodeFlags |= ImGuiTreeNodeFlags_DefaultOpen;
}
if( showHeaders == false || ImGui::TreeNodeEx( label, nodeFlags ) )
{
// TODO: Add folders for materials.
//const char* foldername = pMat->GetFile()->GetNameOfDeepestFolderPath();
if( ImGui::BeginPopupContextItem( "ContextPopup", 1 ) )
{
if( ImGui::MenuItem( "Create New Material" ) )
{
ImGui::CloseCurrentPopup();
MaterialDefinition* pMaterial = pMaterialManager->CreateMaterial( "new" );
// TODO: Fix path based on folders.
char tempstr[MAX_PATH];
sprintf_s( tempstr, MAX_PATH, "Data/Materials" );
pMaterial->SaveMaterial( tempstr );
pMaterialManager->Editor_MoveMaterialToFrontOfLoadedList( pMaterial );
// Essentially, tell the ComponentSystemManager that a new material was loaded.
// This will add it to the scene's file list, which will free the material.
pMaterialManager->CallMaterialCreatedCallbacks( pMaterial );
// Start a rename op on the new material.
StartRenameOp( nullptr, pMaterial, pMaterial->GetName() );
}
ImGui::EndPopup();
}
while( pMat )
{
MaterialDefinition* pNextMat = (MaterialDefinition*)pMat->GetNext();
if( pMat == m_pMaterialWhoseNameIsBeingEdited )
{
ImGui::SetKeyboardFocusHere();
if( ImGui::InputText( "New name", m_NameBeingEdited, 100, ImGuiInputTextFlags_AutoSelectAll|ImGuiInputTextFlags_EnterReturnsTrue ) ||
m_ConfirmCurrentRenameOp )
{
m_pMaterialWhoseNameIsBeingEdited->SetName( m_NameBeingEdited );
m_pMaterialWhoseNameIsBeingEdited = nullptr;
}
}
else
{
MyFileObject* pFile = pMat->GetFile();
if( pFile )
{
const char* matName = pFile->GetFilenameWithoutExtension();
//numMaterialsShown++;
bool showThisItem = true;
if( m_MemoryPanelFilter[0] != '\0' )
{
if( CheckIfMultipleSubstringsAreInString( matName, m_MemoryPanelFilter ) == false )
{
showThisItem = false;
}
}
if( showThisItem )
{
if( ImGui::TreeNodeEx( matName, baseNodeFlags | ImGuiTreeNodeFlags_Leaf ) )
{
// TODO: Find a better answer than IsItemHovered().
if( ImGui::IsItemHovered() && m_RenamePressedThisFrame )
{
StartRenameOp( nullptr, pMat, matName );
}
// Deal with slow double-click for renaming Materials.
if( WasItemSlowDoubleClicked( pMat ) )
{
StartRenameOp( nullptr, pMat, matName );
}
if( ImGui::BeginPopupContextItem( "ContextPopup", 1 ) )
{
if( ImGui::MenuItem( "Edit Material", nullptr, &m_pCurrentLayout->m_IsWindowOpen[EditorWindow_MaterialEditor] ) ) { EditMaterial( pMat ); ImGui::CloseCurrentPopup(); }
if( ImGui::MenuItem( "Unload File" ) ) { pMat->OnPopupClick( pMat, MaterialDefinition::RightClick_UnloadFile ); ImGui::CloseCurrentPopup(); pMat = nullptr; }
if( ImGui::MenuItem( "Find References" ) ) { pMat->OnPopupClick( pMat, MaterialDefinition::RightClick_FindAllReferences ); ImGui::CloseCurrentPopup(); } // (%d)", pMat->GetRefCount() ) {}
if( ImGui::MenuItem( "Rename" ) )
{
StartRenameOp( nullptr, pMat, matName );
ImGui::CloseCurrentPopup();
}
ImGui::EndPopup();
}
if( ImGui::IsItemHovered() )
{
if( ImGui::IsMouseDoubleClicked( 0 ) )
{
EditMaterial( pMat );
}
ImGui::BeginTooltip();
ImGui::Text( "%s", pMat->GetName() );
AddMaterialPreview( pMat, false, ImVec2( 100, 100 ), ImVec4( 1, 1, 1, 1 ) );
ImGui::EndTooltip();
}
if( ImGui::BeginDragDropSource() )
{
ImGui::SetDragDropPayload( "Material", &pMat, sizeof(pMat), ImGuiCond_Once );
ImGui::Text( "%s", pMat->GetName() );
AddMaterialPreview( pMat, false, ImVec2( 100, 100 ), ImVec4( 1, 1, 1, 0.5f ) );
ImGui::EndDragDropSource();
}
ImGui::TreePop();
}
}
}
}
pMat = pNextMat;
}
if( showHeaders )
{
ImGui::TreePop();
}
}
}
if( someMaterialsAreLoaded == false )
{
ImGui::TreeNodeEx( "No materials loaded.", ImGuiTreeNodeFlags_Leaf | ImGuiTreeNodeFlags_NoTreePushOnOpen );
}
}
void EditorMainFrame_ImGui::AddMemoryPanel_Textures()
{
// Only show the headers if the filter is blank.
bool showHeaders = (m_MemoryPanelFilter[0] == '\0');
bool someTexturesAreLoaded = false;
//unsigned int numTexturesShown = 0;
TextureManager* pTextureManager = m_pEngineCore->GetManagers()->GetTextureManager();
for( int i=0; i<2; i++ )
{
TextureDefinition* pTex = (TextureDefinition*)pTextureManager->m_TexturesStillLoading.GetHead();
if( i == 1 )
pTex = (TextureDefinition*)pTextureManager->m_LoadedTextures.GetHead();
if( pTex )
{
someTexturesAreLoaded = true;
ImGuiTreeNodeFlags baseNodeFlags = ImGuiTreeNodeFlags_OpenOnArrow | ImGuiTreeNodeFlags_OpenOnDoubleClick;
char* label = "Textures - Loading";
if( i == 1 )
label = "All Textures";
if( showHeaders == false || ImGui::TreeNodeEx( label, baseNodeFlags | ImGuiTreeNodeFlags_DefaultOpen ) )
{
while( pTex )
{
MyFileObject* pFile = pTex->GetFile();
if( pTex->m_ShowInMemoryPanel )
{
//numTexturesShown++;
bool showThisItem = true;
if( m_MemoryPanelFilter[0] != '\0' )
{
if( CheckIfMultipleSubstringsAreInString( pTex->GetFilename(), m_MemoryPanelFilter ) == false )
{
showThisItem = false;
}
}
if( showThisItem )
{
const char* filename = pTex->GetFilename();
if( filename == nullptr || filename[0] == '\0' )
filename = "No filename";
if( ImGui::TreeNodeEx( filename, ImGuiTreeNodeFlags_Leaf | baseNodeFlags ) )
{
if( ImGui::BeginPopupContextItem( "ContextPopup", 1 ) )
{
FileManager* pFileManager = m_pEngineCore->GetManagers()->GetFileManager();
if( ImGui::MenuItem( "Unload File (TODO)" ) ) { ImGui::CloseCurrentPopup(); }
if( ImGui::MenuItem( "Find References" ) ){ if( pFile ) pFileManager->Editor_FindAllReferences( pFile ); ImGui::CloseCurrentPopup(); } ;// (%d)", pMat->GetRefCount() ) {}
ImGui::EndPopup();
}
if( ImGui::IsItemHovered() )
{
ImGui::BeginTooltip();
//ImGui::Text( "%s", pTex->GetFilename() );
AddTexturePreview( pTex, false, ImVec2( 100, 100 ), ImVec4( 1, 1, 1, 1 ) );
ImGui::EndTooltip();
}
if( ImGui::BeginDragDropSource() )
{
ImGui::SetDragDropPayload( "Texture", &pTex, sizeof(pTex), ImGuiCond_Once );
//ImGui::Text( "%s", pTex->GetFilename() );
AddTexturePreview( pTex, false, ImVec2( 100, 100 ), ImVec4( 1, 1, 1, 1 ) );
ImGui::EndDragDropSource();
}
ImGui::TreePop();
}
}
}
pTex = (TextureDefinition*)pTex->GetNext();
}
if( showHeaders )
{
ImGui::TreePop();
}
}
}
}
if( someTexturesAreLoaded == false )
{
ImGui::TreeNodeEx( "No textures loaded.", ImGuiTreeNodeFlags_Leaf | ImGuiTreeNodeFlags_NoTreePushOnOpen );
}
// Add FBOs
{
TextureManager* pTextureManager = m_pEngineCore->GetManagers()->GetTextureManager();
FBODefinition* pFBO = pTextureManager->m_InitializedFBOs.GetHead();
if( pFBO )
{
ImGuiTreeNodeFlags baseNodeFlags = ImGuiTreeNodeFlags_OpenOnArrow | ImGuiTreeNodeFlags_OpenOnDoubleClick;
char* label = "FBOs";
if( showHeaders == false || ImGui::TreeNodeEx( label, baseNodeFlags | ImGuiTreeNodeFlags_DefaultOpen ) )
{
while( pFBO )
{
if( pFBO->m_ShowInMemoryPanel )
{
bool showThisItem = true;
//if( m_MemoryPanelFilter[0] != '\0' )
//{
// if( CheckIfMultipleSubstringsAreInString( pFBO->GetFilename(), m_MemoryPanelFilter ) == false )
// {
// showThisItem = false;
// }
//}
if( showThisItem )
{
TextureDefinition* pTex = pFBO->GetColorTexture( 0 );
if( pTex )
{
const char* filename = "Unnamed FBO";
if( ImGui::TreeNodeEx( filename, ImGuiTreeNodeFlags_Leaf | baseNodeFlags ) )
{
if( ImGui::IsItemHovered() )
{
ImGui::BeginTooltip();
AddTexturePreview( pTex, false, ImVec2( 100, 100 ), ImVec4( 1, 1, 1, 1 ) );
ImGui::EndTooltip();
}
if( ImGui::BeginDragDropSource() )
{
ImGui::SetDragDropPayload( "Texture", &pTex, sizeof(pTex), ImGuiCond_Once );
AddTexturePreview( pTex, false, ImVec2( 100, 100 ), ImVec4( 1, 1, 1, 1 ) );
ImGui::EndDragDropSource();
}
ImGui::TreePop();
}
}
}
}
pFBO = pFBO->GetNext();
}
if( showHeaders )
{
ImGui::TreePop();
}
}
}
}
}
void EditorMainFrame_ImGui::AddMemoryPanel_ShaderGroups()
{
// Only show the headers if the filter is blank.
bool showHeaders = (m_MemoryPanelFilter[0] == '\0');
bool someShadersAreLoaded = false;
//unsigned int numShadersShown = 0;
{
ShaderGroup* pShaderGroup = (ShaderGroup*)m_pEngineCore->GetManagers()->GetShaderGroupManager()->m_ShaderGroupList.GetHead();
if( pShaderGroup )
{
someShadersAreLoaded = true;
ImGuiTreeNodeFlags baseNodeFlags = ImGuiTreeNodeFlags_OpenOnArrow | ImGuiTreeNodeFlags_OpenOnDoubleClick;
if( showHeaders == false || ImGui::TreeNodeEx( "All Shaders", baseNodeFlags | ImGuiTreeNodeFlags_DefaultOpen ) )
{
while( pShaderGroup )
{
// Store the next shader in case this one gets unloaded.
ShaderGroup* pNextShaderGroup = (ShaderGroup*)pShaderGroup->GetNext();
MyFileObjectShader* pFile = pShaderGroup->GetFile();
if( pFile )
{
if( pFile->m_ShowInMemoryPanel )
{
bool showThisItem = true;
if( m_MemoryPanelFilter[0] != '\0' )
{
if( CheckIfMultipleSubstringsAreInString( pFile->GetFilenameWithoutExtension(), m_MemoryPanelFilter ) == false )
{
showThisItem = false;
}
}
if( showThisItem )
{
if( ImGui::TreeNodeEx( pFile->GetFilenameWithoutExtension(), ImGuiTreeNodeFlags_Leaf | baseNodeFlags ) )
{
if( ImGui::BeginPopupContextItem( "ContextPopup", 1 ) )
{
AddContextMenuItemsForFiles( pFile, pShaderGroup );
ImGui::EndPopup();
}
if( ImGui::BeginDragDropSource() )
{
ImGui::SetDragDropPayload( "ShaderGroup", &pShaderGroup, sizeof(pShaderGroup), ImGuiCond_Once );
ImGui::Text( "%s", pFile->GetFullPath() );
ImGui::EndDragDropSource();
}
ImGui::TreePop();
}
}
}
}
pShaderGroup = pNextShaderGroup;
}
if( showHeaders )
{
ImGui::TreePop();
}
}
}
}
if( someShadersAreLoaded == false)
{
ImGui::TreeNodeEx( "No shaders loaded.", ImGuiTreeNodeFlags_Leaf | ImGuiTreeNodeFlags_NoTreePushOnOpen );
}
}
void EditorMainFrame_ImGui::AddMemoryPanel_SoundCues()
{
// Only show the headers if the filter is blank.
bool showHeaders = (m_MemoryPanelFilter[0] == '\0');
bool someSoundCuesAreLoaded = false;
for( int i=0; i<2; i++ )
{
SoundCue* pSoundCue = (SoundCue*)g_pGameCore->GetSoundManager()->GetCuesStillLoading();
if( i == 1 )
pSoundCue = (SoundCue*)g_pGameCore->GetSoundManager()->GetCues();
if( pSoundCue )
{
someSoundCuesAreLoaded = true;
ImGuiTreeNodeFlags baseNodeFlags = ImGuiTreeNodeFlags_OpenOnArrow | ImGuiTreeNodeFlags_OpenOnDoubleClick;
char* label = "Sound Cues - Loading";
if( i == 1 )
label = "All Sound Cues";
if( showHeaders == false || ImGui::TreeNodeEx( label, baseNodeFlags | ImGuiTreeNodeFlags_DefaultOpen ) )
{
while( pSoundCue )
{
// Store the next shader in case this one gets unloaded.
SoundCue* pNextSoundCue = (SoundCue*)pSoundCue->GetNext();
MyFileObject* pFile = pSoundCue->GetFile();
if( pFile )
{
if( pFile->m_ShowInMemoryPanel )
{
bool showThisItem = true;
if( m_MemoryPanelFilter[0] != '\0' )
{
if( CheckIfMultipleSubstringsAreInString( pFile->GetFilenameWithoutExtension(), m_MemoryPanelFilter ) == false )
{
showThisItem = false;
}
}
if( showThisItem )
{
if( ImGui::TreeNodeEx( pFile->GetFilenameWithoutExtension(), ImGuiTreeNodeFlags_Leaf | baseNodeFlags ) )
{
if( ImGui::BeginPopupContextItem( "ContextPopup", 1 ) )
{
AddContextMenuItemsForFiles( pFile );
ImGui::EndPopup();
}
if( ImGui::BeginDragDropSource() )
{
ImGui::SetDragDropPayload( "SoundCue", &pSoundCue, sizeof(pSoundCue), ImGuiCond_Once );
ImGui::Text( "%s", pFile->GetFullPath() );
ImGui::EndDragDropSource();
}
ImGui::TreePop();
}
}
}
}
pSoundCue = pNextSoundCue;
}
if( showHeaders )
{
ImGui::TreePop();
}
}
}
}
if( someSoundCuesAreLoaded == false)
{
ImGui::TreeNodeEx( "No sound cues loaded.", ImGuiTreeNodeFlags_Leaf | ImGuiTreeNodeFlags_NoTreePushOnOpen );
}
}
void EditorMainFrame_ImGui::AddMemoryPanel_Files()
{
// Only show the headers if the filter is blank.
bool showHeaders = (m_MemoryPanelFilter[0] == '\0');
bool someFilesAreLoaded = false;
//unsigned int numFilesShown = 0;
// TODO: Don't do this every frame.
FileManager* pFileManager = m_pEngineCore->GetManagers()->GetFileManager();
pFileManager->SortFileLists();
for( int i=0; i<2; i++ )
{
MyFileObject* pFile = (MyFileObject*)pFileManager->GetFirstFileStillLoading();
if( i == 1 )
pFile = (MyFileObject*)pFileManager->GetFirstFileLoaded();
if( pFile )
{
someFilesAreLoaded = true;
ImGuiTreeNodeFlags baseNodeFlags = ImGuiTreeNodeFlags_OpenOnArrow | ImGuiTreeNodeFlags_OpenOnDoubleClick;
char* label = "Files - Loading";
if( i == 1 )
label = "All Files";
if( showHeaders == false || ImGui::TreeNodeEx( label, baseNodeFlags | ImGuiTreeNodeFlags_DefaultOpen ) )
{
const char* previousFileType = nullptr;
bool fileTypeOpen = false;
while( pFile )
{
MyFileObject* pNextFile = (MyFileObject*)pFile->GetNext();
if( pFile->m_ShowInMemoryPanel )
{
//numFilesShown++;
if( previousFileType == nullptr || strcmp( previousFileType, pFile->GetExtensionWithDot() ) != 0 )
{
if( fileTypeOpen && previousFileType != nullptr )
{
if( showHeaders )
{
ImGui::TreePop(); // "File Type"
}
}
previousFileType = pFile->GetExtensionWithDot();
if( showHeaders )
{
fileTypeOpen = ImGui::TreeNodeEx( previousFileType, baseNodeFlags );
}
}
if( fileTypeOpen )
{
bool showThisItem = true;
if( m_MemoryPanelFilter[0] != '\0' )
{
if( CheckIfMultipleSubstringsAreInString( pFile->GetFilenameWithoutExtension(), m_MemoryPanelFilter ) == false )
{
showThisItem = false;
}
}
if( showThisItem )
{
if( ImGui::TreeNodeEx( pFile->GetFilenameWithoutExtension(), ImGuiTreeNodeFlags_Leaf | baseNodeFlags ) )
{
if( ImGui::BeginPopupContextItem( "ContextPopup", 1 ) )
{
AddContextMenuItemsForFiles( pFile );
ImGui::EndPopup();
}
if( i == 1 )
{
if( ImGui::BeginDragDropSource() )
{
ImGui::SetDragDropPayload( "File", &pFile, sizeof(pFile), ImGuiCond_Once );
ImGui::Text( "%s", pFile->GetFullPath() );
ImGui::EndDragDropSource();
}
}
ImGui::TreePop();
}
}
}
}
pFile = pNextFile;
}
if( fileTypeOpen && previousFileType != nullptr )
{
if( showHeaders )
{
ImGui::TreePop(); // "File Type"
}
}
if( showHeaders )
{
ImGui::TreePop(); // "All Files"
}
}
}
}
if( someFilesAreLoaded == false )
{
ImGui::TreeNodeEx( "No files loaded.", ImGuiTreeNodeFlags_Leaf | ImGuiTreeNodeFlags_NoTreePushOnOpen );
}
}
void EditorMainFrame_ImGui::AddMemoryPanel_DrawCalls()
{
ImGuiTreeNodeFlags baseNodeFlags = ImGuiTreeNodeFlags_OpenOnArrow | ImGuiTreeNodeFlags_OpenOnDoubleClick | ImGuiTreeNodeFlags_DefaultOpen;
// Always reset draw call limiter to draw everything if one specific draw call isn't hovered.
if( ImGui::IsWindowHovered(ImGuiFocusedFlags_RootWindow | ImGuiFocusedFlags_ChildWindows) == false )
{
g_GLStats.m_DrawCallLimit_Canvas = -1;
g_GLStats.m_DrawCallLimit_Index = -1;
m_SelectedDrawCallCanvas = -1;
m_SelectedDrawCallIndex = -1;
}
ImGui::PushID( "DrawCallTree" );
if( ImGui::TreeNodeEx( "Draw Calls", baseNodeFlags ) )
{
for( int canvasIndex=0; canvasIndex<2; canvasIndex++ )
{
char* label = "Game Window";
if( canvasIndex == 1 )
label = "Editor Window";
if( ImGui::TreeNodeEx( label, baseNodeFlags ) )
{
for( int callIndex=0; callIndex<g_GLStats.m_NumDrawCallsLastFrame[canvasIndex]; callIndex++ )
{
ImGui::PushID( callIndex );
bool selected = (canvasIndex == m_SelectedDrawCallCanvas && callIndex == m_SelectedDrawCallIndex);
ImGuiTreeNodeFlags nodeFlags = ImGuiTreeNodeFlags_Leaf;
if( selected )
{
nodeFlags |= ImGuiTreeNodeFlags_Selected;
}
if( ImGui::TreeNodeEx( "Draw", nodeFlags ) )
{
if( ImGui::IsItemHovered() )
{
m_SelectedDrawCallCanvas = canvasIndex;
m_SelectedDrawCallIndex = callIndex;
selected = true;
}
if( selected )
{
g_GLStats.m_DrawCallLimit_Canvas = canvasIndex;
g_GLStats.m_DrawCallLimit_Index = callIndex;
}
#if _DEBUG && MYFW_WINDOWS
if( ImGui::BeginPopupContextItem( "ContextPopup", 1 ) )
{
if( ImGui::MenuItem( "Trigger breakpoint" ) )
{
g_GLStats.m_DrawCallLimit_BreakPointIndex = callIndex;
ImGui::CloseCurrentPopup();
}
ImGui::EndPopup();
}
#endif
ImGui::TreePop();
}
ImGui::PopID();
}
ImGui::TreePop();
}
}
ImGui::TreePop();
}
ImGui::PopID();
}
void EditorMainFrame_ImGui::AddMaterialEditor()
{
EditorPrefs* pEditorPrefs = m_pEngineCore->GetEditorPrefs();
if( m_pCurrentLayout->m_IsWindowOpen[EditorWindow_MaterialEditor] == false )
return;
ImGui::SetNextWindowPos( ImVec2(856, 71), ImGuiCond_FirstUseEver );
ImGui::SetNextWindowSize( ImVec2(339, 349), ImGuiCond_FirstUseEver );
if( ImGui::Begin( "Material Editor", &m_pCurrentLayout->m_IsWindowOpen[EditorWindow_MaterialEditor] ) )
{
if( m_pMaterialBeingEdited == nullptr )
{
ImGui::Text( "No material selected." );
ImGui::End();
return;
}
// Create a context menu only available from the title bar.
if( ImGui::BeginPopupContextItem() )
{
if( ImGui::MenuItem( "Close" ) )
m_pCurrentLayout->m_IsWindowOpen[EditorWindow_MaterialEditor] = false;
ImGui::EndPopup();
}
AddMaterialPreview( m_pMaterialBeingEdited, false, ImVec2( 100, 100 ), ImVec4(1,1,1,1) );
{
MaterialDefinition* pMat = m_pMaterialBeingEdited;
bool showBuiltInUniforms = true;
bool showExposedUniforms = true;
ShaderGroup* pShaderGroup = pMat->GetShader();
ShaderGroup* pShaderGroupInstanced = pMat->GetShaderInstanced();
{
ImGui::Text( "WORK IN PROGRESS - NO UNDO - MANUAL SAVE" );
if( ImGui::Button( "Save" ) )
{
pMat->SaveMaterial( nullptr );
}
ImGui::SameLine();
ImGui::Text( "<- MANUAL SAVE" );
ImGui::Separator();
}
ImGui::Text( pMat->GetName() );
if( showBuiltInUniforms )
{
//g_pPanelWatch->AddEnum( "Blend", (int*)&m_BlendType, MyRE::MaterialBlendType_NumTypes, MyRE::MaterialBlendTypeStrings );
const char** items = MyRE::MaterialBlendTypeStrings;
int currentItem = pMat->GetBlendType();
const char* currentItemStr = MyRE::MaterialBlendTypeStrings[currentItem];
if( ImGui::BeginCombo( "Blend", currentItemStr ) )
{
for( int n = 0; n < MyRE::MaterialBlendType_NumTypes; n++ )
{
bool is_selected = (n == currentItem);
if( ImGui::Selectable( items[n], is_selected ) )
{
//// Store the old value.
//ComponentVariableValue oldvalue( this, pVar );
//// Change the value.
pMat->SetBlendType( (MyRE::MaterialBlendTypes)n );
//// Store the new value.
//ComponentVariableValue newvalue( this, pVar );
//m_pEngineCore->GetCommandStack()->Do(
// MyNew EditorCommand_ImGuiPanelWatchNumberValueChanged(
// this, pVar, newvalue, oldvalue, true ),
// false );
}
if( is_selected )
{
// Set the initial focus when opening the combo (scrolling + for keyboard navigation support in the upcoming navigation branch)
ImGui::SetItemDefaultFocus();
}
}
ImGui::EndCombo();
}
if( ImGui::DragFloat2( "UVScale", &pMat->m_UVScale.x, 0.01f, 0, 1 ) )
{
pMat->MarkDirty();
}
if( ImGui::DragFloat2( "UVOffset", &pMat->m_UVOffset.x, 0.01f, 0, 1 ) )
{
pMat->MarkDirty();
}
// Deal with the shader attached to the material.
{
ImGui::PushID( "Material_Shader" );
const char* desc = "no shader";
Vector4 buttonColor = pEditorPrefs->GetImGuiStylePrefs()->GetColor( ImGuiStylePrefs::StylePref_Color_UnsetObjectButton );
Vector4 textColor = pEditorPrefs->GetImGuiStylePrefs()->GetColor( ImGuiStylePrefs::StylePref_Color_UnsetObjectText );
if( pShaderGroup && pShaderGroup->GetShader( ShaderPass_Main )->m_pFile )
{
desc = pShaderGroup->GetShader( ShaderPass_Main )->m_pFile->GetFilenameWithoutExtension();
buttonColor = pEditorPrefs->GetImGuiStylePrefs()->GetColor( ImGuiStylePrefs::StylePref_Color_Button );
textColor = pEditorPrefs->GetImGuiStylePrefs()->GetColor( ImGuiStylePrefs::StylePref_Color_Text );
}
ImGui::PushStyleColor( ImGuiCol_Button, buttonColor );
ImGui::PushStyleColor( ImGuiCol_Text, textColor );
ImGui::Button( desc, ImVec2( ImGui::GetWindowWidth() * 0.65f, 0 ) );
ImGui::PopStyleColor( 2 );
if( ImGui::BeginDragDropTarget() )
{
if( const ImGuiPayload* payload = ImGui::AcceptDragDropPayload( "ShaderGroup" ) )
{
pMat->SetShader( (ShaderGroup*)*(void**)payload->Data );
}
ImGui::EndDragDropTarget();
}
if( pShaderGroup )
{
MyFileObjectShader* pFile = pShaderGroup->GetFile();
if( pFile )
{
if( ImGui::BeginPopupContextItem( "ContextPopup", 1 ) )
{
FileManager* pFileManager = m_pEngineCore->GetManagers()->GetFileManager();
if( ImGui::MenuItem( "Open File" ) ) { pFile->OnPopupClick( pFileManager, pFile, MyFileObject::RightClick_OpenFile ); ImGui::CloseCurrentPopup(); }
if( ImGui::MenuItem( "Open containing folder" ) ) { pFile->OnPopupClick( pFileManager, pFile, MyFileObject::RightClick_OpenContainingFolder ); ImGui::CloseCurrentPopup(); }
if( ImGui::MenuItem( "Find References" ) ) { pFile->OnPopupClick( pFileManager, pFile, MyFileObject::RightClick_FindAllReferences ); ImGui::CloseCurrentPopup(); } // (%d)", pMat->GetRefCount() ) {}
ImGui::EndPopup();
}
}
}
if( ImGui::IsItemHovered() )
{
if( ImGui::IsMouseDoubleClicked( 0 ) )
{
pMat->SetShader( nullptr );
pShaderGroup = pMat->GetShader();
}
}
if( pShaderGroup && pShaderGroup->GetFile() && pShaderGroup->GetFile()->m_NumExposedUniforms )
{
ImGui::SameLine();
if( ImGui::CollapsingHeader( "Shader" ) )
{
ImGui::Indent( 20 );
AddInlineMaterial( pMat );
ImGui::Unindent( 20 );
}
}
else
{
ImGui::SameLine();
ImGui::Text( "Shader" );
}
ImGui::PopID();
}
// Deal with the instanced shader attached to the material.
{
ImGui::PushID( "Material_InstancedShader" );
const char* desc = "no instanced shader";
Vector4 buttonColor = pEditorPrefs->GetImGuiStylePrefs()->GetColor( ImGuiStylePrefs::StylePref_Color_UnsetObjectButton );
Vector4 textColor = pEditorPrefs->GetImGuiStylePrefs()->GetColor( ImGuiStylePrefs::StylePref_Color_UnsetObjectText );
if( pShaderGroupInstanced && pShaderGroupInstanced->GetShader( ShaderPass_Main )->m_pFile )
{
desc = pShaderGroupInstanced->GetShader( ShaderPass_Main )->m_pFile->GetFilenameWithoutExtension();
buttonColor = pEditorPrefs->GetImGuiStylePrefs()->GetColor( ImGuiStylePrefs::StylePref_Color_Button );
textColor = pEditorPrefs->GetImGuiStylePrefs()->GetColor( ImGuiStylePrefs::StylePref_Color_Text );
}
ImGui::PushStyleColor( ImGuiCol_Button, buttonColor );
ImGui::PushStyleColor( ImGuiCol_Text, textColor );
ImGui::Button( desc, ImVec2( ImGui::GetWindowWidth() * 0.65f, 0 ) );
ImGui::PopStyleColor( 2 );
if( ImGui::BeginDragDropTarget() )
{
if( const ImGuiPayload* payload = ImGui::AcceptDragDropPayload( "ShaderGroup" ) )
{
pMat->SetShaderInstanced( (ShaderGroup*)*(void**)payload->Data );
}
ImGui::EndDragDropTarget();
}
if( pShaderGroupInstanced )
{
MyFileObjectShader* pFile = pShaderGroupInstanced->GetFile();
if( pFile )
{
if( ImGui::BeginPopupContextItem( "ContextPopup", 1 ) )
{
FileManager* pFileManager = m_pEngineCore->GetManagers()->GetFileManager();
if( ImGui::MenuItem( "Open File" ) ) { pFile->OnPopupClick( pFileManager, pFile, MyFileObject::RightClick_OpenFile ); ImGui::CloseCurrentPopup(); }
if( ImGui::MenuItem( "Open containing folder" ) ) { pFile->OnPopupClick( pFileManager, pFile, MyFileObject::RightClick_OpenContainingFolder ); ImGui::CloseCurrentPopup(); }
if( ImGui::MenuItem( "Find References" ) ) { pFile->OnPopupClick( pFileManager, pFile, MyFileObject::RightClick_FindAllReferences ); ImGui::CloseCurrentPopup(); } // (%d)", pMat->GetRefCount() ) {}
ImGui::EndPopup();
}
}
}
if( ImGui::IsItemHovered() )
{
if( ImGui::IsMouseDoubleClicked( 0 ) )
{
pMat->SetShaderInstanced( nullptr );
pShaderGroupInstanced = pMat->GetShaderInstanced();
}
}
// TODO: Instanced shaders can't use exposed uniforms.
//if( pShaderGroupInstanced && pShaderGroupInstanced->GetFile() && pShaderGroupInstanced->GetFile()->m_NumExposedUniforms )
//{
// ImGui::SameLine();
// if( ImGui::CollapsingHeader( "InstancedShader" ) )
// {
// ImGui::Indent( 20 );
// AddInlineMaterial( pMat );
// ImGui::Unindent( 20 );
// }
//}
//else
{
ImGui::SameLine();
ImGui::Text( "InstancedShader" );
}
ImGui::PopID();
}
{
const char* desc = "no color texture";
Vector4 buttonColor = pEditorPrefs->GetImGuiStylePrefs()->GetColor( ImGuiStylePrefs::StylePref_Color_UnsetObjectButton );
Vector4 textColor = pEditorPrefs->GetImGuiStylePrefs()->GetColor( ImGuiStylePrefs::StylePref_Color_UnsetObjectText );
TextureDefinition* pTextureColor = pMat->GetTextureColor();
if( pTextureColor )
{
desc = pTextureColor->GetFilename();
buttonColor = pEditorPrefs->GetImGuiStylePrefs()->GetColor( ImGuiStylePrefs::StylePref_Color_Button );
textColor = pEditorPrefs->GetImGuiStylePrefs()->GetColor( ImGuiStylePrefs::StylePref_Color_Text );
}
ImGui::PushStyleColor( ImGuiCol_Button, buttonColor );
ImGui::PushStyleColor( ImGuiCol_Text, textColor );
ImGui::Button( desc, ImVec2( ImGui::GetWindowWidth() * 0.65f, 0 ) );
ImGui::PopStyleColor( 2 );
if( ImGui::BeginDragDropTarget() )
{
if( const ImGuiPayload* payload = ImGui::AcceptDragDropPayload( "Texture" ) )
{
pMat->SetTextureColor( (TextureDefinition*)*(void**)payload->Data );
}
ImGui::EndDragDropTarget();
}
if( ImGui::IsItemHovered() )
{
if( pTextureColor )
{
ImGui::BeginTooltip();
//ImGui::Text( "%s", pTex->GetFilename() );
AddTexturePreview( pTextureColor, false, ImVec2( 100, 100 ), ImVec4( 1, 1, 1, 1 ) );
ImGui::EndTooltip();
}
if( ImGui::IsMouseDoubleClicked( 0 ) )
{
pMat->SetTextureColor( nullptr );
}
}
ImGui::SameLine();
ImGui::Text( "Color Texture" );
//g_pPanelWatch->AddPointerWithDescription( "Color Texture", 0, desc, this, MaterialDefinition::StaticOnDropTexture, 0, MaterialDefinition::StaticOnRightClickTexture );
}
// TODO: Copies of these colors are changing, fix that.
ColorFloat ambientColorFloat = pMat->GetColorAmbient().AsColorFloat();
if( ImGui::ColorEdit4( "Ambient Color", &ambientColorFloat.r ) )
{
pMat->SetColorAmbient( ambientColorFloat.AsColorByte() );
}
ColorFloat diffuseColorFloat = pMat->GetColorDiffuse().AsColorFloat();
if( ImGui::ColorEdit4( "Diffuse Color", &diffuseColorFloat.r ) )
{
pMat->SetColorDiffuse( diffuseColorFloat.AsColorByte() );
}
ColorFloat specularColorFloat = pMat->GetColorSpecular().AsColorFloat();
if( ImGui::ColorEdit4( "Specular Color", &specularColorFloat.r ) )
{
pMat->SetColorSpecular( specularColorFloat.AsColorByte() );
}
if( ImGui::DragFloat( "Shininess", &pMat->m_Shininess ) )
{
pMat->MarkDirty();
}
}
// Preview settings.
{
ImGui::Separator();
MyAssert( MaterialDefinition::PreviewType_NumTypes == 2 );
const char* items[] = { "Sphere", "Flat" };
int currentItem = pMat->GetPreviewType();
const char* currentItemStr = items[currentItem];
if( ImGui::BeginCombo( "Preview Type", currentItemStr ) )
{
for( int n = 0; n < MaterialDefinition::PreviewType_NumTypes; n++ )
{
bool isSelected = (n == currentItem);
if( ImGui::Selectable( items[n], isSelected ) )
{
pMat->SetPreviewType( (MaterialDefinition::PreviewType)n );
}
if( isSelected )
{
// Set the initial focus when opening the combo (scrolling + for keyboard navigation support in the upcoming navigation branch)
ImGui::SetItemDefaultFocus();
}
}
ImGui::EndCombo();
}
}
{
ImGui::Separator();
ImGui::Text( "MANUAL SAVE" );
if( ImGui::Button( "Save" ) )
{
pMat->SaveMaterial( nullptr );
}
ImGui::SameLine();
ImGui::Text( "<- MANUAL SAVE" );
}
}
}
ImGui::End();
}
void EditorMainFrame_ImGui::Add2DAnimationEditor()
{
if( m_p2DAnimInfoBeingEdited != nullptr )
{
m_FullPathToLast2DAnimInfoBeingEdited[0] = '\0';
}
if( m_FullPathToLast2DAnimInfoBeingEdited[0] != '\0' )
{
MyFileInfo* pFileInfo = g_pComponentSystemManager->GetFileInfoIfUsedByScene( m_FullPathToLast2DAnimInfoBeingEdited, SCENEID_Any );
if( pFileInfo )
{
My2DAnimInfo* pAnimInfo = pFileInfo->Get2DAnimInfo();
m_pCurrentLayout->m_IsWindowOpen[EditorWindow_2DAnimationEditor] = true;
m_Current2DAnimationIndex = 0;
MyFileObject* pFile = pAnimInfo->GetSourceFile();
if( pFile && pFile->IsFinishedLoading() )
{
m_p2DAnimInfoBeingEdited = pAnimInfo;
m_FullPathToLast2DAnimInfoBeingEdited[0] = '\0';
}
}
}
if( m_pCurrentLayout->m_IsWindowOpen[EditorWindow_2DAnimationEditor] == false )
return;
ImGui::SetNextWindowPos( ImVec2(556, 71), ImGuiCond_FirstUseEver );
ImGui::SetNextWindowSize( ImVec2(339, 349), ImGuiCond_FirstUseEver );
if( ImGui::Begin( "2D Animation Editor", &m_pCurrentLayout->m_IsWindowOpen[EditorWindow_2DAnimationEditor] ) )
{
// Create a context menu only available from the title bar.
if( ImGui::BeginPopupContextItem() )
{
if( ImGui::MenuItem( "Close" ) )
{
m_p2DAnimInfoBeingEdited = nullptr;
m_pCurrentLayout->m_IsWindowOpen[EditorWindow_2DAnimationEditor] = false;
}
ImGui::EndPopup();
}
My2DAnimInfo* pAnimInfo = m_p2DAnimInfoBeingEdited;
if( pAnimInfo == nullptr )
{
if( m_FullPathToLast2DAnimInfoBeingEdited[0] == '\0' )
ImGui::Text( "No animation selected" );
else
ImGui::Text( "File still loading: %s", m_FullPathToLast2DAnimInfoBeingEdited );
}
else
{
m_pAnimPlayerComponent->SetAnimationFile( pAnimInfo->GetSourceFile() );
m_pAnimPlayerComponent->SetCurrentAnimation( m_Current2DAnimationIndex );
ImGui::Columns( 2, nullptr, false );
{
ImGui::Text( "WORK IN PROGRESS - NO UNDO - MANUAL SAVE" );
if( ImGui::Button( "Save" ) )
{
pAnimInfo->SaveAnimationControlFile();
}
ImGui::SameLine();
ImGui::Text( "<- MANUAL SAVE" );
}
ImGui::NextColumn();
if( pAnimInfo->GetNumberOfAnimations() > 0 )
{
uint32 frameIndex = m_pAnimPlayerComponent->GetCurrentFrameIndex();
My2DAnimation* pAnim = pAnimInfo->GetAnimationByIndex( m_Current2DAnimationIndex );
if( pAnim->GetFrameCount() > 0 )
{
My2DAnimationFrame* pFrame = pAnim->GetFrameByIndex( frameIndex );
MaterialDefinition* pMat = pFrame->m_pMaterial;
AddMaterialColorTexturePreview( pMat, false, ImVec2( 50, 50 ), ImVec4( 1, 1, 1, 1 ) );
ImGui::SameLine();
ImGui::Text( "FrameIndex: %d", frameIndex );
ImGui::SameLine();
if( ImGui::Button( "Remove Animation" ) )
{
pAnimInfo->OnRemoveAnimationPressed( m_Current2DAnimationIndex );
if( m_Current2DAnimationIndex > pAnimInfo->GetNumberOfAnimations() )
m_Current2DAnimationIndex--;
}
}
}
ImGui::Columns( 1 );
ImGui::Separator();
ImGui::BeginChild( "Animation Details" );
ImGui::Text( "%s Animations:", pAnimInfo->GetSourceFile()->GetFilenameWithoutExtension() );
ImGui::Columns( 3, nullptr, false );
// First Column: Animations.
{
for( unsigned int animIndex=0; animIndex<pAnimInfo->GetNumberOfAnimations(); animIndex++ )
{
My2DAnimation* pAnim = pAnimInfo->GetAnimationByIndex( animIndex );
if( ImGui::Selectable( pAnim->GetName(), m_Current2DAnimationIndex == animIndex ) )
{
m_Current2DAnimationIndex = animIndex;
}
}
if( pAnimInfo->GetNumberOfAnimations() < My2DAnimInfo::MAX_ANIMATIONS )
{
if( ImGui::Button( "Add Animation" ) )
{
pAnimInfo->OnAddAnimationPressed();
}
}
}
ImGui::NextColumn();
// Second Column: Frame durations of currently selected animation.
if( pAnimInfo->GetNumberOfAnimations() > 0 )
{
int animIndex = m_Current2DAnimationIndex;
My2DAnimation* pAnim = pAnimInfo->GetAnimationByIndex( animIndex );
//ImGui::Text( pAnim->GetName() );
unsigned int numframes = pAnim->GetFrameCount();
for( unsigned int frameIndex=0; frameIndex<numframes; frameIndex++ )
{
My2DAnimationFrame* pFrame = pAnim->GetFrameByIndex( frameIndex );
ImGui::PushID( pFrame );
ImGui::Text( "Frame %d", frameIndex );
ImGui::SliderFloat( "Duration", &pFrame->m_Duration, 0, 1 );
if( ImGui::Button( "Remove" ) )
{
pAnimInfo->OnRemoveFramePressed( animIndex, frameIndex );
numframes = pAnim->GetFrameCount();
}
ImGui::Spacing();
ImGui::Spacing();
ImGui::Spacing();
//ImGui::Text( "---------" );
ImGui::PopID();
}
if( pAnim->GetFrameCount() < My2DAnimInfo::MAX_FRAMES_IN_ANIMATION )
{
if( ImGui::Button( "Add Frame" ) )
{
pAnimInfo->OnAddFramePressed( animIndex );
}
}
}
ImGui::NextColumn();
// Third Column: Material texture previews.
if( pAnimInfo->GetNumberOfAnimations() > 0 )
{
int animindex = m_Current2DAnimationIndex;
My2DAnimation* pAnim = pAnimInfo->GetAnimationByIndex( animindex );
unsigned int numframes = pAnim->GetFrameCount();
for( unsigned int frameindex=0; frameindex<numframes; frameindex++ )
{
My2DAnimationFrame* pFrame = pAnim->GetFrameByIndex( frameindex );
ImGui::PushID( pFrame );
MaterialDefinition* pMat = pFrame->m_pMaterial;
if( pMat != nullptr )
{
ImGui::Text( "%s", pMat->GetName() );
}
else
{
ImGui::Text( "No Material Assigned" );
}
AddMaterialColorTexturePreview( pMat, false, ImVec2( 50, 50 ), ImVec4( 1, 1, 1, 1 ) );
if( ImGui::BeginDragDropTarget() )
{
if( const ImGuiPayload* payload = ImGui::AcceptDragDropPayload( "Material" ) )
{
pFrame->SetMaterial( (MaterialDefinition*)*(void**)payload->Data );
}
ImGui::EndDragDropTarget();
}
ImGui::Spacing();
ImGui::PopID();
}
}
ImGui::Columns( 1 );
{
ImGui::Separator();
ImGui::Text( "MANUAL SAVE" );
if( ImGui::Button( "Save" ) )
{
pAnimInfo->SaveAnimationControlFile();
}
ImGui::SameLine();
ImGui::Text( "<- MANUAL SAVE" );
}
ImGui::EndChild();
}
}
ImGui::End();
}
void EditorMainFrame_ImGui::AddMaterialPreview(MaterialDefinition* pMaterial, bool createWindow, ImVec2 requestedSize, ImVec4 tint)
{
m_pMaterialToPreview = pMaterial;
if( createWindow == true )
{
ImGui::SetNextWindowSize( ImVec2(requestedSize.x+50, requestedSize.y+50), ImGuiCond_FirstUseEver );
ImGui::SetNextWindowBgAlpha( 1.0f );
}
if( createWindow == false || ImGui::Begin( "Material", nullptr ) )
{
if( m_pMaterialToPreview->GetPreviewType() == MaterialDefinition::PreviewType_Sphere )
{
TextureDefinition* pTexture = pTexture = m_pMaterialPreviewFBO->GetColorTexture( 0 );
int texw = m_pMaterialPreviewFBO->GetTextureWidth();
int texh = m_pMaterialPreviewFBO->GetTextureHeight();
ImVec2 size = requestedSize;
if( size.x == 0 )
size = ImGui::GetContentRegionAvail();
if( size.x > size.y ) size.x = size.y;
if( size.y > size.x ) size.y = size.x;
if( pTexture )
{
int w = pTexture->GetWidth();
int h = pTexture->GetHeight();
//ImGui::ImageButton( (void*)pTexture, size, ImVec2(0,(float)h/texh), ImVec2((float)w/texw,0), -1, ImVec4(0,0,0,1) );
ImGui::Image( (void*)pTexture, size, ImVec2(0,(float)h/texh), ImVec2((float)w/texw,0), tint );
}
}
else //if( m_pMaterialToPreview->GetPreviewType() == MaterialDefinition::PreviewType_Flat )
{
AddMaterialColorTexturePreview( m_pMaterialToPreview, false, requestedSize, tint );
}
}
if( createWindow == true )
{
ImGui::End(); // ImGui::Begin( "Material"...
}
}
void EditorMainFrame_ImGui::AddMaterialColorTexturePreview(MaterialDefinition* pMaterial, bool createWindow, ImVec2 requestedSize, ImVec4 tint)
{
if( pMaterial == nullptr )
{
AddTexturePreview( nullptr, false, requestedSize, ImVec4( 1, 1, 1, 1 ), ImVec2( 0, 0 ), ImVec2( 0, 0 ) );
}
else
{
ImVec2 startUV( pMaterial->GetUVOffset() );
ImVec2 endUV( pMaterial->GetUVOffset() + pMaterial->GetUVScale() );
AddTexturePreview( pMaterial->GetTextureColor(), false, requestedSize, ImVec4( 1, 1, 1, 1 ), startUV, endUV );
}
}
void EditorMainFrame_ImGui::AddTexturePreview(TextureDefinition* pTexture, bool createWindow, ImVec2 requestedSize, ImVec4 tint, ImVec2 startUV, ImVec2 endUV)
{
if( createWindow == true )
{
ImGui::SetNextWindowSize( ImVec2(150, 150), ImGuiCond_FirstUseEver );
ImGui::SetNextWindowBgAlpha( 1.0f );
}
if( createWindow == false || ImGui::Begin( "Texture", nullptr ) )
{
ImVec2 size = requestedSize;
if( size.x == 0 )
size = ImGui::GetContentRegionAvail();
if( size.x > size.y ) size.x = size.y;
if( size.y > size.x ) size.y = size.x;
if( pTexture != nullptr )
{
ImGui::Image( (void*)pTexture, size, startUV, endUV, tint );
}
else
{
ImGui::Image( 0, size, startUV, endUV, tint );
}
}
if( createWindow == true )
{
ImGui::End(); // ImGui::Begin( "Texture"...
}
}
void EditorMainFrame_ImGui::AddDebug_MousePicker()
{
if( m_pCurrentLayout->m_IsWindowOpen[EditorWindow_Debug_MousePicker] == false )
return;
ImGui::SetNextWindowSize( ImVec2(150, 150), ImGuiCond_FirstUseEver );
ImGui::SetNextWindowBgAlpha( 1.0f );
if( ImGui::Begin( "Mouse Picker", &m_pCurrentLayout->m_IsWindowOpen[EditorWindow_Debug_MousePicker] ) )
{
TextureDefinition* pTexture = m_pEngineCore->GetEditorState()->m_pMousePickerFBO->GetColorTexture( 0 );
int texw = m_pEngineCore->GetEditorState()->m_pMousePickerFBO->GetTextureWidth();
int texh = m_pEngineCore->GetEditorState()->m_pMousePickerFBO->GetTextureHeight();
ImVec2 size = ImGui::GetContentRegionAvail();
if( size.x > size.y ) size.x = size.y;
if( size.y > size.x ) size.y = size.x;
if( pTexture )
{
//int w = pTexture->GetWidth();
//int h = pTexture->GetHeight();
int w = m_pEngineCore->GetEditorState()->m_pMousePickerFBO->GetWidth();
int h = m_pEngineCore->GetEditorState()->m_pMousePickerFBO->GetHeight();
ImGui::Image( (void*)pTexture, size, ImVec2(0,(float)h/texh), ImVec2((float)w/texw,0) );
}
}
ImGui::End();
}
void OnDropSoundCueOnEditorWindow(EngineCore* pEngineCore, SoundCue* pSoundCue)
{
if( pSoundCue )
{
// Create a new GameObject with an audio player component.
GameObject* pGameObjectCreated = g_pComponentSystemManager->CreateGameObject( false, SCENEID_MainScene );
pGameObjectCreated->SetName( pSoundCue->GetName() );
ComponentAudioPlayer* pComponent = (ComponentAudioPlayer*)pGameObjectCreated->AddNewComponent( ComponentType_AudioPlayer, SCENEID_MainScene, g_pComponentSystemManager );
pComponent->SetSoundCue( pSoundCue );
// Add it to the undo stack.
g_pGameCore->GetCommandStack()->Do( MyNew EditorCommand_CreateGameObject( pGameObjectCreated ) );
// Clear the selected objects and select the new one.
pEngineCore->GetEditorState()->ClearSelectedObjectsAndComponents();
pEngineCore->GetEditorState()->SelectGameObject( pGameObjectCreated );
}
}
bool EditorMainFrame_ImGui::OnDropObjectList(GameObject* pGameObject, bool forceReorder)
{
bool dragDropPayloadAcceptedOnRelease = false;
bool dragDropOfItemWillResultInAReorder = false;
EditorState* pEditorState = m_pEngineCore->GetEditorState();
if( ImGui::BeginDragDropTarget() )
{
if( const ImGuiPayload* payload = ImGui::AcceptDragDropPayload( "GameObject", ImGuiDragDropFlags_AcceptPeekOnly ) )
{
// Clear the "reorder" line.
m_pGameObjectToDrawReorderLineAfter = nullptr;
// If there's a drag/drop payload and it's a gameobject, then:
// if we're hovering over the top half of the item, reparent the dropped item.
// if we're hovering over the bottom half, reorder the dropped item after the hovered item.
if( forceReorder || (ImGui::GetMousePos().y > ImGui::GetItemRectMin().y + (ImGui::GetItemRectSize().y * 0.5f)) )
{
dragDropOfItemWillResultInAReorder = true;
m_pGameObjectToDrawReorderLineAfter = pGameObject;
}
}
ImGuiDragDropFlags dropFlags = 0;
if( dragDropOfItemWillResultInAReorder )
dropFlags = ImGuiDragDropFlags_AcceptNoDrawDefaultRect;
if( const ImGuiPayload* payload = ImGui::AcceptDragDropPayload( "GameObject", dropFlags ) )
{
// Releasing the mouse will drop the payload, but we need prevent this from selecting the item.
dragDropPayloadAcceptedOnRelease = true;
g_DragAndDropStruct.Clear();
GameObject* pDroppedGO = (GameObject*)*(void**)payload->Data;
if( pEditorState->IsGameObjectSelected( pDroppedGO ) == false )
{
// If this GameObject wasn't selected, then only move this one.
g_DragAndDropStruct.Add( DragAndDropType_GameObjectPointer, pDroppedGO );
}
else
{
// If it was selected, move all selected objects.
for( unsigned int i=0; i<pEditorState->m_pSelectedObjects.size(); i++ )
{
g_DragAndDropStruct.Add( DragAndDropType_GameObjectPointer, pEditorState->m_pSelectedObjects[i] );
}
}
if( dragDropOfItemWillResultInAReorder )
{
MyAssert( pGameObject != nullptr );
pGameObject->OnDrop( -1, -1, -1, GameObject::GameObjectOnDropAction_Reorder );
m_pGameObjectToDrawReorderLineAfter = nullptr;
}
else
{
pGameObject->OnDrop( -1, -1, -1, GameObject::GameObjectOnDropAction_Reparent );
}
}
if( const ImGuiPayload* payload = ImGui::AcceptDragDropPayload( "SoundCue", 0 ) )
{
SoundCue* pSoundCue = (SoundCue*)*(void**)payload->Data;
MyAssert( pSoundCue != nullptr );
if( pSoundCue )
{
// Create an audio player component.
EditorCommand_CreateComponent* pCommand = MyNew EditorCommand_CreateComponent( pGameObject, ComponentType_AudioPlayer );
g_pGameCore->GetCommandStack()->Do( pCommand );
ComponentAudioPlayer* pComponent = (ComponentAudioPlayer*)pCommand->GetCreatedObject();
// Attach the correct sound cue.
pComponent->SetSoundCue( pSoundCue );
}
}
ImGui::EndDragDropTarget();
}
return dragDropPayloadAcceptedOnRelease;
}
void EditorMainFrame_ImGui::OnDropEditorWindow()
{
unsigned int x = m_CurrentMouseInEditorWindow_X;
unsigned int y = m_CurrentMouseInEditorWindow_Y;
// Get the GameObject the mouse was hovering over.
ComponentCamera* pCamera = m_pEngineCore->GetEditorState()->GetEditorCamera();
//y = pCamera->m_WindowHeight - y; // prefer 0,0 at bottom left.
GameObject* pObjectDroppedOn = m_pEngineCore->GetCurrentEditorInterface()->GetObjectAtPixel( x, y, true, false );
if( const ImGuiPayload* payload = ImGui::AcceptDragDropPayload( "Material" ) )
{
//DragAndDropItem* pDropItem = g_DragAndDropStruct.GetItem( 0 );
//if( pDropItem->m_Type == DragAndDropType_MaterialDefinitionPointer )
{
MaterialDefinition* pMaterial = (MaterialDefinition*)*(void**)payload->Data; //pDropItem->m_Value;
if( pMaterial && pObjectDroppedOn )
{
pObjectDroppedOn->Editor_SetMaterial( pMaterial );
#if MYFW_USING_WX
pObjectDroppedOn->Editor_SetMaterial( pMaterial );
g_pPanelWatch->SetNeedsRefresh();
#endif
}
}
}
if( const ImGuiPayload* payload = ImGui::AcceptDragDropPayload( "Texture" ) )
{
//if( pDropItem->m_Type == DragAndDropType_TextureDefinitionPointer )
{
TextureDefinition* pTexture = (TextureDefinition*)*(void**)payload->Data; //pDropItem->m_Value;
if( pTexture && pObjectDroppedOn && pObjectDroppedOn->GetMaterial() )
{
g_pGameCore->GetCommandStack()->Do( MyNew EditorCommand_ChangeTextureOnMaterial( pObjectDroppedOn->GetMaterial(), pTexture ) );
}
}
}
if( const ImGuiPayload* payload = ImGui::AcceptDragDropPayload( "ShaderGroup" ) )
{
//if( pDropItem->m_Type == DragAndDropType_ShaderGroupPointer )
{
ShaderGroup* pShader = (ShaderGroup*)*(void**)payload->Data; //pDropItem->m_Value;
if( pShader && pObjectDroppedOn && pObjectDroppedOn->GetMaterial() )
{
g_pGameCore->GetCommandStack()->Do( MyNew EditorCommand_ChangeShaderOnMaterial( pObjectDroppedOn->GetMaterial(), pShader ) );
}
}
}
if( const ImGuiPayload* payload = ImGui::AcceptDragDropPayload( "SoundCue" ) )
{
SoundCue* pSoundCue = (SoundCue*)*(void**)payload->Data;
OnDropSoundCueOnEditorWindow( m_pEngineCore, pSoundCue );
}
if( const ImGuiPayload* payload = ImGui::AcceptDragDropPayload( "File" ) )
{
//if( pDropItem->m_Type == DragAndDropType_FileObjectPointer )
{
MyFileObject* pFile = (MyFileObject*)*(void**)payload->Data; //pDropItem->m_Value;
MyAssert( pFile );
if( pFile && strcmp( pFile->GetExtensionWithDot(), ".lua" ) == 0 )
{
if( pObjectDroppedOn )
{
g_pGameCore->GetCommandStack()->Do( MyNew EditorCommand_ChangeAllScriptsOnGameObject( pObjectDroppedOn, pFile ) );
}
}
if( pFile && strcmp( pFile->GetExtensionWithDot(), ".glsl" ) == 0 )
{
if( pObjectDroppedOn && pObjectDroppedOn->GetMaterial() )
{
ShaderGroup* pShader = m_pEngineCore->GetManagers()->GetShaderGroupManager()->FindShaderGroupByFile( pFile );
g_pGameCore->GetCommandStack()->Do( MyNew EditorCommand_ChangeShaderOnMaterial( pObjectDroppedOn->GetMaterial(), pShader ) );
}
}
if( pFile && strcmp( pFile->GetExtensionWithDot(), ".mycue" ) == 0 )
{
SoundCue* pSoundCue = g_pGameCore->GetSoundManager()->FindCueByFilename( pFile->GetFullPath() );
OnDropSoundCueOnEditorWindow( m_pEngineCore, pSoundCue );
}
if( pFile &&
( strcmp( pFile->GetExtensionWithDot(), ".obj" ) == 0 || strcmp( pFile->GetExtensionWithDot(), ".mymesh" ) == 0 )
)
{
// Create a new gameobject using this obj.
MaterialManager* pMaterialManager = m_pEngineCore->GetManagers()->GetMaterialManager();
MeshManager* pMeshManager = m_pEngineCore->GetManagers()->GetMeshManager();
MyMesh* pMesh = pMeshManager->FindMeshBySourceFile( pFile );
GameObject* pGameObject = g_pComponentSystemManager->CreateGameObject( true, SCENEID_MainScene );
pGameObject->SetName( "New mesh" );
ComponentMeshOBJ* pComponentMeshOBJ = (ComponentMeshOBJ*)pGameObject->AddNewComponent( ComponentType_MeshOBJ, SCENEID_MainScene, g_pComponentSystemManager );
pComponentMeshOBJ->SetSceneID( SCENEID_MainScene );
pComponentMeshOBJ->SetMaterial( pMaterialManager->GetFirstMaterial(), 0 );
pComponentMeshOBJ->SetMesh( pMesh );
pComponentMeshOBJ->SetLayersThisExistsOn( Layer_MainScene );
if( pObjectDroppedOn && pObjectDroppedOn->GetMaterial() )
{
// Place it just above of the object selected otherwise place it at 0,0,0... for now.
Vector3 pos = pObjectDroppedOn->GetTransform()->GetWorldPosition();
ComponentRenderable* pComponentMeshDroppedOn = (ComponentRenderable*)pObjectDroppedOn->GetFirstComponentOfBaseType( BaseComponentType_Renderable );
if( pComponentMeshDroppedOn && pComponentMeshDroppedOn->GetBounds() != nullptr )
{
pos.y += pComponentMeshDroppedOn->GetBounds()->GetHalfSize().y;
pos.y += pMesh->GetBounds()->GetHalfSize().y;
}
pGameObject->GetTransform()->SetWorldPosition( pos );
pGameObject->GetTransform()->UpdateTransform();
}
// Undo/redo.
g_pGameCore->GetCommandStack()->Add( MyNew EditorCommand_CreateGameObject( pGameObject ) );
}
}
}
if( const ImGuiPayload* payload = ImGui::AcceptDragDropPayload( "Prefab" ) )
{
PrefabObject* pPrefab = (PrefabObject*)*(void**)payload->Data;
// Default to drop into main scene, but prefer putting in same scene as the object dropped on.
SceneID sceneid = SCENEID_MainScene;
if( pObjectDroppedOn )
{
sceneid = pObjectDroppedOn->GetSceneID();
}
// Create the game object.
GameObject* pGameObjectCreated = g_pComponentSystemManager->CreateGameObjectFromPrefab( pPrefab, true, sceneid );
if( pGameObjectCreated )
{
// Undo/Redo.
g_pGameCore->GetCommandStack()->Add( MyNew EditorCommand_CreateGameObject( pGameObjectCreated ) );
// Select the object dropped.
m_pEngineCore->GetEditorState()->ClearSelectedObjectsAndComponents();
m_pEngineCore->GetEditorState()->SelectGameObject( pGameObjectCreated );
// Move the new object to the same spot as the one it was dropped on.
if( pObjectDroppedOn )
{
std::vector<GameObject*> selectedobjects;
selectedobjects.push_back( pGameObjectCreated );
Vector3 worldPos = pObjectDroppedOn->GetTransform()->GetWorldPosition();
g_pGameCore->GetCommandStack()->Do( MyNew EditorCommand_MoveObjects( worldPos, selectedobjects ), true );
}
}
}
if( const ImGuiPayload* payload = ImGui::AcceptDragDropPayload( "GameObject" ) )
{
//if( (int)pDropItem->m_Type == (int)DragAndDropType_GameObjectPointer )
//{
// GameObject* pGameObject = (GameObject*)*(void**)payload->Data; //pDropItem->m_Value;
// MyAssert( pGameObject );
// int id = g_DragAndDropStruct.GetControlID() - m_ControlIDOfFirstExtern;
//
// // TODO: this will make a mess of memory if different types of objects can be dragged in...
// m_ExposedVars[id]->pointer = pGameObject;
// // update the panel so new gameobject name shows up.
// g_pPanelWatch->GetVariableProperties( g_DragAndDropStruct.GetControlID() )->m_Description = pGameObject->GetName();
//}
}
}
|
48a6fccee4684b68bcc329da0a8d2ec79cd9e2e8 | 8fe2e38fd3f23f58dd0f35d1f351601f8a723e07 | /drape_frontend/watch/icon_info.hpp | 69918fe6f1f4922c39653b3672388a62415e7565 | [
"Apache-2.0"
] | permissive | ruilin/RLMap | cb139b7fb3020b163a6857cfa6b98f0c930f2a45 | e16b52f77d165e719b3af20b097f227959e8e374 | refs/heads/master | 2022-10-06T10:11:39.760428 | 2019-11-22T01:03:27 | 2019-11-22T01:03:27 | 97,201,756 | 2 | 1 | Apache-2.0 | 2022-10-04T23:29:25 | 2017-07-14T06:39:33 | C++ | UTF-8 | C++ | false | false | 202 | hpp | icon_info.hpp | #pragma once
#include "std/string.hpp"
namespace df
{
namespace watch
{
struct IconInfo
{
string m_name;
IconInfo() = default;
explicit IconInfo(string const & name) : m_name(name) {}
};
}
}
|
4236ba5788606144ddc94772f41a2bc5ecdf2d96 | db81540b3d817ddbc0c38fb0e0c44f16c574a94c | /spatiumgl/gfx3d/src/gfx3d/PointCloud.cpp | 291a56a32599435945e3bcbb5f90625a2eacbde5 | [] | no_license | Graphics-Physics-Libraries/SpatiumGL | 461fe595b08c83488e216ede8f54bd0dacf51268 | 8d191f5ff4b122e81368c0ef071ed59e5b4145a0 | refs/heads/master | 2020-08-01T04:06:11.302475 | 2019-09-25T12:26:56 | 2019-09-25T12:26:56 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 3,151 | cpp | PointCloud.cpp | /*
* Program: Spatium Graphics Library
*
* Copyright (C) Martijn Koopman
* All Rights Reserved
*
* This software is distributed WITHOUT ANY WARRANTY; without even
* the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
* PURPOSE.
*
*/
#include "spatiumgl/gfx3d/PointCloud.hpp"
namespace spatiumgl {
namespace gfx3d {
PointCloud::PointCloud()
: RenderObject()
, m_positions()
, m_colors()
, m_normals()
{}
PointCloud::PointCloud(const std::vector<Vector3>& positions,
const std::vector<Vector3>& colors,
const std::vector<Vector3>& normals)
: RenderObject()
, m_positions(positions)
, m_colors(colors)
, m_normals(normals)
{
// Update bounds
if (m_positions.size() > 0)
{
// First point
m_bounds.center() = m_positions[0];
m_bounds.radii() = Vector3();
for (size_t i = 1; i < m_positions.size(); i++)
{
// Second or later point
m_bounds.include(m_positions[i]);
}
}
}
PointCloud::PointCloud(const size_t count, const bool hasColors, const bool hasNormals)
: RenderObject()
, m_positions()
, m_colors()
, m_normals()
{
m_positions.reserve(count);
if (hasColors)
{
m_colors.reserve(count);
}
if (hasNormals)
{
m_normals.reserve(count);
}
}
size_t PointCloud::pointCount() const
{
return m_positions.size();
}
void PointCloud::addPoint(const Vector3& position)
{
if (m_positions.size() == 0)
{
// First point
m_bounds.center() = position;
m_bounds.radii() = Vector3();
}
else
{
// Second or later point
m_bounds.include(position);
}
m_positions.push_back(position);
}
void PointCloud::addPoint(const Vector3& position, const Vector3& color)
{
addPoint(position);
m_colors.push_back(color);
}
void PointCloud::addPoint(const Vector3& position, const Vector3& color, const Vector3& normal)
{
addPoint(position);
m_colors.push_back(color);
m_normals.push_back(normal);
}
// Positions
const Vector3& PointCloud::position(size_t index) const
{
// Check bounds?
return m_positions[index];
}
const std::vector<Vector3>& PointCloud::positions() const
{
return m_positions;
}
// Colors
bool PointCloud::hasColors() const
{
return m_colors.size() > 0 && m_colors.size() == m_positions.size();
}
Vector3& PointCloud::color(size_t index)
{
// Check bounds?
return m_colors[index];
}
const Vector3& PointCloud::color(size_t index) const
{
// Check bounds?
return m_colors[index];
}
const std::vector<Vector3>& PointCloud::colors() const
{
return m_colors;
}
// Normals
bool PointCloud::hasNormals() const
{
return m_normals.size() > 0 && m_normals.size() == m_normals.size();
}
Vector3& PointCloud::normal(size_t index)
{
// Check bounds?
return m_normals[index];
}
const Vector3& PointCloud::normal(size_t index) const
{
// Check bounds?
return m_normals[index];
}
const std::vector<Vector3>& PointCloud::normals() const
{
return m_normals;
}
} // namespace gfx3d
} // namespace spatiumgl |
9bf2d6060763337448ae5c441b871cbf9128535e | e1f3172d7a034930e4fbc66b2560868a0d18bbf2 | /ClassTraningAnimal/AnimalClass.cpp | 432206243784cf72e96958e22b8d000ee8049ff7 | [] | no_license | vallisneria/hknu2-programming-to-cpp | 1cace2d40de741ec0f94083f4910adda1cea8502 | 4c76f91cb349bb1c48cf8adf94cb7c174227ebd1 | refs/heads/master | 2023-03-08T09:59:02.282119 | 2019-08-31T13:40:08 | 2019-08-31T13:40:08 | 342,198,642 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 6,286 | cpp | AnimalClass.cpp | /*
고급프로그래밍1 실습
동물 클래스 만들기
- 고양이와 토끼와 사람은 동물에 포함되고 학생은 사람에 포함됨.
- 고양이와 사람과 학생 객체가 speak()메서드를 실행할 때 각각 meow, hello, I have a homework를 출력함.
토끼는 speak() 메서드가 없다.
- 객체에서 print()메서드를 실행하면 동물종류: (나이, 이름)을 출력함
- Animal 클래스 내에서 객체의 개수를 세는 static 변수를 만든다.
*/
#include <iostream>
class Animal {
protected:
int age; // Animal 클래스의 객체의 나이
const char* name; // Animal 클래스의 객체의 이름
// 객체의 개수를 세는 static 변수
// 생성자에서 ++, 소멸자에서 --
static unsigned int animalCount,
rabbitCount,
catCount,
personCount,
studentCount;
public:
// Animal 클래스의 생성자
Animal(const int age, const char* name) {
Animal::animalCount++;
this->setAge(age);
this->setName(name);
}
// Animal 클래스의 소멸자
// (소멸자는 나중에 사용할 예정)
~Animal() { Animal::animalCount--; }
// 나이를 변경하는 메서드
void setAge(const int age) { this->age = age; }
// 동물의 나이를 return 하는 메서드
int getAge() const { return this->age; }
// 동물의 이름을 변경하는 메서드
void setName(const char* name) { this->name = name; }
// 동물의 이름을 return하는 메서드
const char* getName() const { return this->name; }
// 동물의 정보(나이,이름)을 출력하는 메서드
void print() const {
std::cout << "Animal: (" << this->getAge() << "," << this->getName() << ")"
<< std::endl;
}
// 동물들의 개수를 출력하는 메서드
static void animalCountStatistics() {
std::cout << "*************************" << std::endl;
std::cout << " Statistics " << std::endl;
std::cout << "*************************" << std::endl;
std::cout << " # of Animal : " << Animal::animalCount << std::endl;
std::cout << " # of Rabbit : " << Animal::rabbitCount << std::endl;
std::cout << " # of Cat : " << Animal::catCount << std::endl;
std::cout << " # of Person : " << Animal::personCount << std::endl;
std::cout << " # of Student : " << Animal::studentCount << std::endl;
std::cout << "*************************" << std::endl;
}
};
class Rabbit : public Animal {
public:
// Rabbit 클래스의 생성자
Rabbit(const int age, const char* name) : Animal(age, name) { Animal::rabbitCount++; }
// Rabbit 클래스의 소멸자
~Rabbit() { Animal::rabbitCount--; }
// 토끼의 정보(나이, 이름)을 출력하는 메서드.
// 부모 클래스의 print 메서드 오버라이딩
void print() const {
std::cout << "Rabbit: (" << this->getAge() << "," << this->getName() << ")"
<< std::endl;
}
};
class Cat : public Animal {
public:
// Cat 클래스의 생성자
Cat(const int age, const char* name) : Animal(age, name) { Animal::catCount++; }
// Cat 클래스의 소멸자
~Cat() { Animal::catCount--; }
void speak() const { std::cout << "meow" << std::endl; }
// 고양이의 정보(나이, 이름)을 출력하는 메서드.
// 부모 클래스의 print 메서드 오버라이딩
void print() const {
std::cout << "Cat: (" << this->getAge() << "," << this->getName() << ")"
<< std::endl;
}
};
class Person : public Animal {
public:
Person(int age, const char* name) : Animal(age, name) { Animal::personCount++; }
~Person() { Animal::personCount--; }
// Person 클래스의 두 객체의 나이를 비교하는 메서드
int age_diff(const Person& other) const {
return (this->getAge()) - (other.getAge());
}
void speak() const { std::cout << "Hello" << std::endl; }
// 사람의 정보(나이, 이름)을 출력하는 메서드.
// 부모 클래스의 print 메서드 오버라이딩
void print() const {
std::cout << "Person: (" << this->getAge() << "," << this->getName() << ")"
<< std::endl;
}
};
class Student : public Person {
protected:
const char* major;
public:
Student(const int age, const char* name, const char* major) : Person(age, name) {
Animal::studentCount++;
setMajor(major);
}
~Student() { Animal::studentCount--; }
// Student 클래스의 속성 중 하나인 전공을 변경하는 메서드
void setMajor(const char* major) { this->major = major; }
// Student 클래스의 속성 중 하나인 전공을 return하는 메서드
const char* getMajor() const { return this->major; }
void speak() const { std::cout << "I have a homework" << std::endl; }
// 학생의 정보(나이, 이름, 전공)을 출력하는 메서드.
// 부모 클래스의 print 메서드 오버라이딩
void print() const {
std::cout << "Student: (" << this->getAge() << "," << this->getName() << "," << this->getMajor() << ")"
<< std::endl;
}
};
unsigned int Animal::animalCount = 0,
Animal::rabbitCount = 0,
Animal::catCount = 0,
Animal::personCount = 0,
Animal::studentCount = 0;
int main(void) {
// 미리 제공된 main 메서드
Animal a1(2, "animal1");
Animal a2(3, "animal2");
Rabbit r1(4, "rabbit1");
Rabbit r2(5, "rabbit2");
Cat c1(6, "cat1");
Cat c2(7, "cat2");
Person p1(6, "person1");
Person p2(7, "person2");
Student s1(8, "student1", "CS");
Student s2(9, "student2", "EE");
a1.print();
a2.print();
r1.print();
r2.print();
c1.print();
c2.print();
c1.speak();
c2.speak();
p1.print();
p2.print();
p1.speak();
p2.speak();
std::cout << p1.age_diff(p2) << std::endl;
s1.print();
s2.print();
s1.speak();
s2.speak();
std::cout << s1.age_diff(s2) << std::endl;
Animal::animalCountStatistics();
return 0;
} |
2f83b0ac0cf7d916eccc8d3c16dd3115b9b63d15 | f61816a8c62b51160b02a77fb14418173f59edfa | /Input Combos/Motor2D/j1Printer.cpp | 38e55397f802ab8799c859a9085d986f2a71f9e2 | [
"MIT"
] | permissive | EggBitsTeam/King_Hackaton2k18 | e3a3d8c14222a0892591cbb03334a7e094888570 | d3ad526745f177cdf1364ad6001af33af885650b | refs/heads/master | 2020-03-16T23:39:42.977663 | 2018-05-13T03:26:22 | 2018-05-13T03:26:22 | 133,086,101 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 2,804 | cpp | j1Printer.cpp | #include "j1Printer.h"
#include "ctRender.h"
//#include "Brofiler\Brofiler.h"
bool j1Printer::Awake(pugi::xml_node&)
{
return true;
}
bool j1Printer::Start()
{
return true;
}
bool j1Printer::PreUpdate()
{
return true;
}
bool j1Printer::Update(float dt)
{
return true;
}
bool j1Printer::PostUpdate()
{
while (!drawingQueue.empty())
{
DrawingElem* delem = drawingQueue.top();
switch (delem->type)
{
case DrawingElem::DElemType::SPRITE:
{
Sprite* sprite = (Sprite*)delem;
int alpha = sprite->color.a;
if (!sprite->flip)
App->render->Blit(sprite->texture, sprite->pos.x, sprite->pos.y, &sprite->squareToBlit, 1.0f, SDL_FLIP_NONE, sprite->degAngle, alpha);
else
App->render->Blit(sprite->texture, sprite->pos.x, sprite->pos.y, &sprite->squareToBlit, 1.0f, SDL_FLIP_HORIZONTAL, sprite->degAngle, alpha);
//SDL_SetTextureColorMod(sprite->texture, 255, 255, 255);
break;
}
case DrawingElem::DElemType::QUAD:
{
Quad* quad = (Quad*)delem;
App->render->DrawQuad(quad->rect, quad->color.r, quad->color.g, quad->color.b, quad->color.a, quad->filled, quad->useCamera);
break;
}
case DrawingElem::DElemType::CIRCLE:
{
Circle* circle = (Circle*)delem;
App->render->DrawCircle(circle->pos.x, circle->pos.y, circle->radius, circle->color.r, circle->color.g, circle->color.b, circle->color.a, circle->useCamera);
break;
}
case DrawingElem::DElemType::LINE:
{
Line* line = (Line*)delem;
App->render->DrawLine(line->pointA.x, line->pointA.y, line->pointB.x, line->pointB.y, line->color.r, line->color.g, line->color.b, line->color.a, line->useCamera);
break;
}
default:
break;
}
drawingQueue.pop();
delete delem;
}
return true;
}
bool j1Printer::CleanUp()
{
while (!drawingQueue.empty())
{
DrawingElem* delem = drawingQueue.top();
drawingQueue.pop();
delete delem;
}
return drawingQueue.empty();
}
bool j1Printer::PrintSprite(iPoint pos, SDL_Texture* texture, SDL_Rect squareToBlit, int layer, bool flip, float degAngle, SDL_Color color)
{
Sprite* sprite = new Sprite(pos, texture, squareToBlit, layer, flip, degAngle, color);
drawingQueue.push(sprite);
return true;
}
bool j1Printer::PrintQuad(SDL_Rect rect, SDL_Color color, bool filled, bool useCamera, int layer)
{
Quad* quad = new Quad(rect, color, filled, useCamera, layer);
drawingQueue.push(quad);
return true;
}
bool j1Printer::PrintCircle(iPoint pos, int radius, SDL_Color color, bool useCamera, int layer)
{
Circle* circle = new Circle(pos, radius, color, useCamera, layer);
drawingQueue.push(circle);
return true;
}
bool j1Printer::PrintLine(iPoint pointA, iPoint pointB, SDL_Color color, bool useCamera, int layer)
{
Line* line = new Line(pointA, pointB, color, useCamera, layer);
drawingQueue.push(line);
return true;
} |
db4bad575b75ac4b2627193f068ae38ebe73000b | 030646c52a7833baac9d58d39c825d90b2f5619c | /ast-compile.cc | 2ebaeb7f8762487e3f16e5f9c992acdd41453335 | [] | no_license | pranavrao870/compiler-cs316 | 47251bf00efc7c415eedd48c319c8bd1349464fd | 5acb993e4100f93494d3cc85b35965d61f0e9a53 | refs/heads/master | 2020-07-03T01:34:12.791006 | 2019-08-11T09:18:38 | 2019-08-11T09:18:38 | 201,743,033 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 22,940 | cc | ast-compile.cc | #include <string.h>
#include <string>
#include <sstream>
#include "icode.hh"
#include "reg-alloc.hh"
using namespace std;
template class Number_Ast<double>;
template class Number_Ast<int>;
//////////////////////////////////////////////////////////////////////
Code_For_Ast & Ast::create_store_stmt(Register_Descriptor * store_register){}
//////////////////////////////////////////////////////////////////////
Code_For_Ast & Assignment_Ast::compile(){
Code_For_Ast r = rhs->compile();
list<Icode_Stmt *> y = r.get_icode_list();
Code_For_Ast * a = new Code_For_Ast();
for(list<Icode_Stmt *>::iterator it = y.begin();it!=y.end();it++){
a->append_ics(*(*it));
}
Ics_Opd *r2 = new Register_Addr_Opd(r.get_reg());
a->set_reg(NULL);
if(node_data_type == int_data_type){
Ics_Opd *r3 = new Mem_Addr_Opd(lhs->get_symbol_entry());
Icode_Stmt * i = new Move_IC_Stmt(store,r3,r2);
a->append_ics(*i);
}
else{
Ics_Opd *r3 = new Mem_Addr_Opd(lhs->get_symbol_entry());
Icode_Stmt * i = new Move_IC_Stmt(store_d,r3,r2);
a->append_ics(*i);
}
r.get_reg()->reset_use_for_expr_result();
return *a;
}
Code_For_Ast & Assignment_Ast::compile_and_optimize_ast(Lra_Outcome & lra){
}
//////////////////////////////////////////////////////////////////////
Code_For_Ast & Name_Ast::compile(){
Code_For_Ast * a = new Code_For_Ast();
Ics_Opd *r1 = new Mem_Addr_Opd(get_symbol_entry());
if(node_data_type == int_data_type){
Register_Descriptor * temp = machine_desc_object.get_new_register<int_reg>();
a->set_reg(temp);
Ics_Opd *r2 = new Register_Addr_Opd(temp);
Icode_Stmt * i = new Move_IC_Stmt(load,r1,r2);
a->append_ics(*i);
}
else{
Register_Descriptor * temp = machine_desc_object.get_new_register<float_reg>();
a->set_reg(temp);
Ics_Opd *r2 = new Register_Addr_Opd(temp);
Icode_Stmt * i = new Move_IC_Stmt(load_d,r1,r2);
a->append_ics(*i);
}
return *a;
}
Code_For_Ast & Name_Ast::compile_and_optimize_ast(Lra_Outcome & lra){
}
Code_For_Ast & Name_Ast::create_store_stmt(Register_Descriptor * store_register){
}
//////////////////////////////////////////////////////////////////////
template<class T>
Code_For_Ast & Number_Ast<T>::compile(){
Code_For_Ast * a = new Code_For_Ast();
if(node_data_type == int_data_type){
Ics_Opd *r1 = new Const_Opd<int>(constant);
Register_Descriptor * temp = machine_desc_object.get_new_register<int_reg>();
a->set_reg(temp);
Ics_Opd *r2 = new Register_Addr_Opd(temp);
Icode_Stmt * i = new Move_IC_Stmt(imm_load,r1,r2);
a->append_ics(*i);
}
else{
Ics_Opd *r1 = new Const_Opd<double>(constant);
Register_Descriptor * temp = machine_desc_object.get_new_register<float_reg>();
a->set_reg(temp);
Ics_Opd *r2 = new Register_Addr_Opd(temp);
Icode_Stmt * i = new Move_IC_Stmt(imm_load_d,r1,r2);
a->append_ics(*i);
}
return *a;
}
template<class T>
Code_For_Ast & Number_Ast<T>::compile_and_optimize_ast(Lra_Outcome & lra){
}
//////////////////////////////////////////////////////////////////////
Code_For_Ast & Plus_Ast::compile_and_optimize_ast(Lra_Outcome & lra){
}
Code_For_Ast & Plus_Ast::compile(){
Code_For_Ast l = lhs->compile();
Code_For_Ast r = rhs->compile();
list<Icode_Stmt *> x = l.get_icode_list();
list<Icode_Stmt *> y = r.get_icode_list();
Code_For_Ast * a = new Code_For_Ast();
for(list<Icode_Stmt *>::iterator it = x.begin();it!=x.end();it++){
a->append_ics(*(*it));
}
for(list<Icode_Stmt *>::iterator it = y.begin();it!=y.end();it++){
a->append_ics(*(*it));
}
Ics_Opd *r1 = new Register_Addr_Opd(l.get_reg());
Ics_Opd *r2 = new Register_Addr_Opd(r.get_reg());
if(node_data_type == int_data_type){
Register_Descriptor * temp = machine_desc_object.get_new_register<int_reg>();
a->set_reg(temp);
Ics_Opd *r3 = new Register_Addr_Opd(temp);
Icode_Stmt * i = new Compute_IC_Stmt(add,r1,r2,r3);
a->append_ics(*i);
}
else{
Register_Descriptor * temp = machine_desc_object.get_new_register<float_reg>();
a->set_reg(temp);
Ics_Opd *r3 = new Register_Addr_Opd(temp);
Icode_Stmt * i = new Compute_IC_Stmt(add_d,r1,r2,r3);
a->append_ics(*i);
}
l.get_reg()->reset_use_for_expr_result();
r.get_reg()->reset_use_for_expr_result();
return *a;
}
//////////////////////////////////////////////////////////////////////
Code_For_Ast & Minus_Ast::compile_and_optimize_ast(Lra_Outcome & lra){
}
Code_For_Ast & Minus_Ast::compile(){
Code_For_Ast l = lhs->compile();
Code_For_Ast r = rhs->compile();
list<Icode_Stmt *> x = l.get_icode_list();
list<Icode_Stmt *> y = r.get_icode_list();
Code_For_Ast * a = new Code_For_Ast();
for(list<Icode_Stmt *>::iterator it = x.begin();it!=x.end();it++){
a->append_ics(*(*it));
}
for(list<Icode_Stmt *>::iterator it = y.begin();it!=y.end();it++){
a->append_ics(*(*it));
}
Ics_Opd *r1 = new Register_Addr_Opd(l.get_reg());
Ics_Opd *r2 = new Register_Addr_Opd(r.get_reg());
if(node_data_type == int_data_type){
Register_Descriptor * temp = machine_desc_object.get_new_register<int_reg>();
a->set_reg(temp);
Ics_Opd *r3 = new Register_Addr_Opd(temp);
Icode_Stmt * i = new Compute_IC_Stmt(sub,r1,r2,r3);
a->append_ics(*i);
}
else{
Register_Descriptor * temp = machine_desc_object.get_new_register<float_reg>();
a->set_reg(temp);
Ics_Opd *r3 = new Register_Addr_Opd(temp);
Icode_Stmt * i = new Compute_IC_Stmt(sub_d,r1,r2,r3);
a->append_ics(*i);
}
l.get_reg()->reset_use_for_expr_result();
r.get_reg()->reset_use_for_expr_result();
return *a;
}
//////////////////////////////////////////////////////////////////////
Code_For_Ast & Divide_Ast::compile_and_optimize_ast(Lra_Outcome & lra){
}
Code_For_Ast & Divide_Ast::compile(){
Code_For_Ast l = lhs->compile();
Code_For_Ast r = rhs->compile();
list<Icode_Stmt *> x = l.get_icode_list();
list<Icode_Stmt *> y = r.get_icode_list();
Code_For_Ast * a = new Code_For_Ast();
for(list<Icode_Stmt *>::iterator it = x.begin();it!=x.end();it++){
a->append_ics(*(*it));
}
for(list<Icode_Stmt *>::iterator it = y.begin();it!=y.end();it++){
a->append_ics(*(*it));
}
Ics_Opd *r1 = new Register_Addr_Opd(l.get_reg());
Ics_Opd *r2 = new Register_Addr_Opd(r.get_reg());
if(node_data_type == int_data_type){
Register_Descriptor * temp = machine_desc_object.get_new_register<int_reg>();
a->set_reg(temp);
Ics_Opd *r3 = new Register_Addr_Opd(temp);
Icode_Stmt * i = new Compute_IC_Stmt(divd,r1,r2,r3);
a->append_ics(*i);
}
else{
Register_Descriptor * temp = machine_desc_object.get_new_register<float_reg>();
a->set_reg(temp);
Ics_Opd *r3 = new Register_Addr_Opd(temp);
Icode_Stmt * i = new Compute_IC_Stmt(div_d,r1,r2,r3);
a->append_ics(*i);
}
l.get_reg()->reset_use_for_expr_result();
r.get_reg()->reset_use_for_expr_result();
return *a;
}
//////////////////////////////////////////////////////////////////////
Code_For_Ast & Mult_Ast::compile_and_optimize_ast(Lra_Outcome & lra){
}
Code_For_Ast & Mult_Ast::compile(){
Code_For_Ast l = lhs->compile();
Code_For_Ast r = rhs->compile();
list<Icode_Stmt *> x = l.get_icode_list();
list<Icode_Stmt *> y = r.get_icode_list();
Code_For_Ast * a = new Code_For_Ast();
for(list<Icode_Stmt *>::iterator it = x.begin();it!=x.end();it++){
a->append_ics(*(*it));
}
for(list<Icode_Stmt *>::iterator it = y.begin();it!=y.end();it++){
a->append_ics(*(*it));
}
Ics_Opd *r1 = new Register_Addr_Opd(l.get_reg());
Ics_Opd *r2 = new Register_Addr_Opd(r.get_reg());
if(node_data_type == int_data_type){
Register_Descriptor * temp = machine_desc_object.get_new_register<int_reg>();
a->set_reg(temp);
Ics_Opd *r3 = new Register_Addr_Opd(temp);
Icode_Stmt * i = new Compute_IC_Stmt(mult,r1,r2,r3);
a->append_ics(*i);
}
else{
Register_Descriptor * temp = machine_desc_object.get_new_register<float_reg>();
a->set_reg(temp);
Ics_Opd *r3 = new Register_Addr_Opd(temp);
Icode_Stmt * i = new Compute_IC_Stmt(mult_d,r1,r2,r3);
a->append_ics(*i);
}
l.get_reg()->reset_use_for_expr_result();
r.get_reg()->reset_use_for_expr_result();
return *a;
}
//////////////////////////////////////////////////////////////////////
Code_For_Ast & UMinus_Ast::compile(){
Code_For_Ast r = lhs->compile();
list<Icode_Stmt *> y = r.get_icode_list();
Code_For_Ast * a = new Code_For_Ast();
for(list<Icode_Stmt *>::iterator it = y.begin();it!=y.end();it++){
a->append_ics(*(*it));
}
Ics_Opd *r2 = new Register_Addr_Opd(r.get_reg());
if(node_data_type == int_data_type){
Register_Descriptor * temp = machine_desc_object.get_new_register<int_reg>();
a->set_reg(temp);
Ics_Opd *r3 = new Register_Addr_Opd(temp);
Icode_Stmt * i = new Move_IC_Stmt(uminus,r2,r3);
a->append_ics(*i);
}
else{
Register_Descriptor * temp = machine_desc_object.get_new_register<float_reg>();
a->set_reg(temp);
Ics_Opd *r3 = new Register_Addr_Opd(temp);
Icode_Stmt * i = new Move_IC_Stmt(uminus_d,r2,r3);
a->append_ics(*i);
}
r.get_reg()->reset_use_for_expr_result();
return *a;
}
Code_For_Ast & UMinus_Ast::compile_and_optimize_ast(Lra_Outcome & lra){
}
//////////////////////////////////////////////////////////////////////
// Code_For_Ast & Relational_Expr_Ast::compile_and_optimize_ast(Lra_Outcome & lra){
// Code_For_Ast x;
// return x;
// }
Code_For_Ast & Relational_Expr_Ast::compile(){
Code_For_Ast l = lhs_condition->compile();
Code_For_Ast r = rhs_condition->compile();
list<Icode_Stmt *> x = l.get_icode_list();
list<Icode_Stmt *> y = r.get_icode_list();
Code_For_Ast * a = new Code_For_Ast();
for(list<Icode_Stmt *>::iterator it = x.begin();it!=x.end();it++){
a->append_ics(*(*it));
}
for(list<Icode_Stmt *>::iterator it = y.begin();it!=y.end();it++){
a->append_ics(*(*it));
}
Ics_Opd *r1 = new Register_Addr_Opd(l.get_reg());
Ics_Opd *r2 = new Register_Addr_Opd(r.get_reg());
Register_Descriptor * temp = machine_desc_object.get_new_register<int_reg>();
a->set_reg(temp);
Ics_Opd *r3 = new Register_Addr_Opd(temp);
Icode_Stmt * i;
if(node_data_type == int_data_type){
if(rel_op == less_equalto)
i = new Compute_IC_Stmt(sle,r1,r2,r3);
else if(rel_op == less_than)
i = new Compute_IC_Stmt(slt,r1,r2,r3);
else if(rel_op == greater_than)
i = new Compute_IC_Stmt(sgt,r1,r2,r3);
else if(rel_op == greater_equalto)
i = new Compute_IC_Stmt(sge,r1,r2,r3);
else if(rel_op == equalto)
i = new Compute_IC_Stmt(seq,r1,r2,r3);
else
i = new Compute_IC_Stmt(sne,r1,r2,r3);
}
else{
if(rel_op == less_equalto)
i = new Move_IC_Stmt(sle_d,r2,r1);
else if(rel_op == less_than)
i = new Move_IC_Stmt(slt_d,r2,r1);
else if(rel_op == greater_than)
i = new Move_IC_Stmt(sgt_d,r2,r1);
else if(rel_op == greater_equalto)
i = new Move_IC_Stmt(sge_d,r2,r1);
else if(rel_op == equalto)
i = new Move_IC_Stmt(seq_d,r2,r1);
else
i = new Move_IC_Stmt(sne_d,r2,r1);
}
a->append_ics(*i);
l.get_reg()->reset_use_for_expr_result();
r.get_reg()->reset_use_for_expr_result();
return *a;
}
//////////////////////////////////////////////////////////////////////
Code_For_Ast & Conditional_Expression_Ast::compile(){
Code_For_Ast c = cond->compile();
list<Icode_Stmt *> z = c.get_icode_list();
Code_For_Ast * a = new Code_For_Ast();
for(list<Icode_Stmt *>::iterator it = z.begin();it!=z.end();it++){
a->append_ics(*(*it));
}
Ics_Opd *r1 = new Register_Addr_Opd(c.get_reg());
string label1 = get_new_label();
string label2 = get_new_label();
Icode_Stmt * i1;
if(cond->get_data_type()==int_data_type)
i1 = new Control_Flow_IC_Stmt(beq,r1,NULL,label1);
else{
Icode_Stmt * check = a->get_icode_list().back();
if(check->get_op().get_op()==sgt_d || check->get_op().get_op()==sge_d || check->get_op().get_op()==sne_d)
i1 = new Label_IC_Stmt(bc1t, label1);
else
i1 = new Label_IC_Stmt(bc1f, label1);
}
a->append_ics(*i1);
c.get_reg()->reset_use_for_expr_result();
Code_For_Ast l = lhs->compile();
Code_For_Ast r = rhs->compile();
list<Icode_Stmt *> x = l.get_icode_list();
list<Icode_Stmt *> y = r.get_icode_list();
for(list<Icode_Stmt *>::iterator it = x.begin();it!=x.end();it++){
a->append_ics(*(*it));
}
Register_Descriptor * temp;
if(lhs->get_data_type() == int_data_type)
temp = machine_desc_object.get_new_register<int_reg>();
else
temp = machine_desc_object.get_new_register<float_reg>();
a->set_reg(temp);
r1 = new Register_Addr_Opd(l.get_reg());
Ics_Opd *r2 = new Register_Addr_Opd(machine_desc_object.spim_register_table[zero]);
Ics_Opd *r3 = new Register_Addr_Opd(temp);
Icode_Stmt * i2 = new Compute_IC_Stmt(or_t,r1,r2,r3);
a->append_ics(*i2);
l.get_reg()->reset_use_for_expr_result();
Icode_Stmt * i3 = new Label_IC_Stmt(j,label2);
a->append_ics(*i3);
Icode_Stmt * i4 = new Label_IC_Stmt(label,label1);
a->append_ics(*i4);
for(list<Icode_Stmt *>::iterator it = y.begin();it!=y.end();it++){
a->append_ics(*(*it));
}
r1 = new Register_Addr_Opd(r.get_reg());
Icode_Stmt * i5 = new Compute_IC_Stmt(or_t,r1,r2,r3);
a->append_ics(*i5);
Icode_Stmt * i6 = new Label_IC_Stmt(label,label2);
a->append_ics(*i6);
return *a;
}
//////////////////////////////////////////////////////////////////////
Code_For_Ast & Logical_Expr_Ast::compile(){
Code_For_Ast * a = new Code_For_Ast();
Ics_Opd *r1;
Code_For_Ast l;
if(bool_op != _logical_not){
l = lhs_op->compile();
list<Icode_Stmt *> x = l.get_icode_list();
for(list<Icode_Stmt *>::iterator it = x.begin();it!=x.end();it++){
a->append_ics(*(*it));
}
r1 = new Register_Addr_Opd(l.get_reg());
}
Code_For_Ast r = rhs_op->compile();
list<Icode_Stmt *> y = r.get_icode_list();
for(list<Icode_Stmt *>::iterator it = y.begin();it!=y.end();it++){
a->append_ics(*(*it));
}
Ics_Opd *r2 = new Register_Addr_Opd(r.get_reg());
Register_Descriptor * temp = machine_desc_object.get_new_register<int_reg>();
a->set_reg(temp);
Ics_Opd *r3 = new Register_Addr_Opd(temp);
Icode_Stmt * i;
if(bool_op == _logical_and)
i = new Compute_IC_Stmt(and_t,r1,r2,r3);
else if(bool_op == _logical_or)
i = new Compute_IC_Stmt(or_t,r1,r2,r3);
else
i = new Move_IC_Stmt(not_t,r2,r3);
a->append_ics(*i);
if(bool_op != _logical_not)
l.get_reg()->reset_use_for_expr_result();
r.get_reg()->reset_use_for_expr_result();
return *a;
}
//////////////////////////////////////////////////////////////////////
Code_For_Ast & Selection_Statement_Ast::compile(){
string label1 = get_new_label();
Code_For_Ast c = cond->compile();
list<Icode_Stmt *> z = c.get_icode_list();
Code_For_Ast * a = new Code_For_Ast();
for(list<Icode_Stmt *>::iterator it = z.begin();it!=z.end();it++){
a->append_ics(*(*it));
}
Ics_Opd *r1 = new Register_Addr_Opd(c.get_reg());
Icode_Stmt * i1;
if(cond->get_data_type()==int_data_type)
i1 = new Control_Flow_IC_Stmt(beq,r1,NULL,label1);
else{
Icode_Stmt * check = a->get_icode_list().back();
if(check->get_op().get_op()==sgt_d || check->get_op().get_op()==sge_d || check->get_op().get_op()==sne_d)
i1 = new Label_IC_Stmt(bc1t, label1);
else
i1 = new Label_IC_Stmt(bc1f, label1);
}
a->append_ics(*i1);
c.get_reg()->reset_use_for_expr_result();
a->set_reg(NULL);
if(else_part!=NULL){
string label2 = get_new_label();
Code_For_Ast l = then_part->compile();
Code_For_Ast r = else_part->compile();
list<Icode_Stmt *> x = l.get_icode_list();
list<Icode_Stmt *> y = r.get_icode_list();
for(list<Icode_Stmt *>::iterator it = x.begin();it!=x.end();it++){
a->append_ics(*(*it));
}
Icode_Stmt * i3 = new Label_IC_Stmt(j,label2);
a->append_ics(*i3);
Icode_Stmt * i4 = new Label_IC_Stmt(label,label1);
a->append_ics(*i4);
for(list<Icode_Stmt *>::iterator it = y.begin();it!=y.end();it++){
a->append_ics(*(*it));
}
Icode_Stmt * i6 = new Label_IC_Stmt(label,label2);
a->append_ics(*i6);
}
else{
Code_For_Ast l = then_part->compile();
list<Icode_Stmt *> x = l.get_icode_list();
for(list<Icode_Stmt *>::iterator it = x.begin();it!=x.end();it++){
a->append_ics(*(*it));
}
Icode_Stmt * i4 = new Label_IC_Stmt(label,label1);
a->append_ics(*i4);
}
return *a;
}
//////////////////////////////////////////////////////////////////////
Code_For_Ast & Iteration_Statement_Ast::compile(){
string label1 = get_new_label();
string label2 = get_new_label();
Code_For_Ast * a = new Code_For_Ast();
if(!is_do_form){
Icode_Stmt * ij = new Label_IC_Stmt(j, label2);
a->append_ics(*ij);
}
Icode_Stmt * i1 = new Label_IC_Stmt(label, label1);
a->append_ics(*i1);
Code_For_Ast b = body->compile();
list<Icode_Stmt *> z = b.get_icode_list();
for(list<Icode_Stmt *>::iterator it = z.begin();it!=z.end();it++){
a->append_ics(*(*it));
}
Icode_Stmt * i2 = new Label_IC_Stmt(label, label2);
a->append_ics(*i2);
Code_For_Ast c = cond->compile();
list<Icode_Stmt *> z1 = c.get_icode_list();
for(list<Icode_Stmt *>::iterator it = z1.begin();it!=z1.end();it++){
a->append_ics(*(*it));
}
Ics_Opd *r1 = new Register_Addr_Opd(c.get_reg());
Icode_Stmt * i3;
if(cond->get_data_type()==int_data_type)
i3 = new Control_Flow_IC_Stmt(bne,r1,NULL,label1);
else{
Icode_Stmt * check = a->get_icode_list().back();
if(check->get_op().get_op()==sgt_d || check->get_op().get_op()==sge_d || check->get_op().get_op()==sne_d)
i3 = new Label_IC_Stmt(bc1f, label1);
else
i3 = new Label_IC_Stmt(bc1t, label1);
}
a->append_ics(*i3);
c.get_reg()->reset_use_for_expr_result();
a->set_reg(NULL);
return *a;
}
//////////////////////////////////////////////////////////////////////
Code_For_Ast & Sequence_Ast::compile(){
for(list<Ast*>::iterator it = statement_list.begin(); it != statement_list.end(); it++){
Code_For_Ast x1 = (*it)->compile();
if (x1.get_reg() != NULL)
x1.get_reg()->reset_use_for_expr_result();
list<Icode_Stmt *> x = x1.get_icode_list();
for(list<Icode_Stmt *>::iterator it2 = x.begin(); it2!=x.end(); it2++){
sa_icode_list.push_back(*it2);
}
}
Code_For_Ast* t = new Code_For_Ast(sa_icode_list, NULL);
return *t;
}
void Sequence_Ast::print_assembly(ostream & file_buffer){
for (list<Icode_Stmt*>::iterator it = sa_icode_list.begin(); it != sa_icode_list.end(); it++){
(*it)->print_assembly(file_buffer);
}
}
void Sequence_Ast::print_icode(ostream & file_buffer){
for (list<Icode_Stmt*>::iterator it = sa_icode_list.begin(); it != sa_icode_list.end(); it++){
(*it)->print_icode(file_buffer);
}
}
//////////////////////////////////////////////////////////////////////
Code_For_Ast & Print_Ast::compile(){
Code_For_Ast * a = new Code_For_Ast();
a->set_reg(NULL);
Ics_Opd *r3 = new Mem_Addr_Opd(var->get_symbol_entry());
if(var->get_data_type() == int_data_type){
Ics_Opd *r1 = new Register_Addr_Opd(machine_desc_object.spim_register_table[v0]);
Ics_Opd *r2 = new Const_Opd<int>(1);
Icode_Stmt * i1 = new Move_IC_Stmt(imm_load, r2, r1);
a->append_ics(*i1);
r1 = new Register_Addr_Opd(machine_desc_object.spim_register_table[a0]);
Icode_Stmt * i = new Move_IC_Stmt(load,r3,r1);
a->append_ics(*i);
}
else{
Ics_Opd *r1 = new Register_Addr_Opd(machine_desc_object.spim_register_table[v0]);
Ics_Opd *r2 = new Const_Opd<int>(3);
Icode_Stmt * i1 = new Move_IC_Stmt(imm_load, r2, r1);
a->append_ics(*i1);
r1 = new Register_Addr_Opd(machine_desc_object.spim_register_table[f12]);
Icode_Stmt * i = new Move_IC_Stmt(load_d,r3,r1);
a->append_ics(*i);
}
Icode_Stmt * i2 = new Print_IC_Stmt();
a->append_ics(*i2);
return *a;
}
//////////////////////////////////////////////////////////////////////
Code_For_Ast & Return_Ast::compile_and_optimize_ast(Lra_Outcome & lra) {}
Code_For_Ast & Return_Ast::compile() {
list <Icode_Stmt*> icl;
if (return_value != NULL){
Code_For_Ast c = return_value->compile();
Register_Descriptor *reg = c.get_reg();
for(list<Icode_Stmt *>::iterator i2 = c.get_icode_list().begin(); i2 != c.get_icode_list().end(); i2++){
icl.push_back(*i2);
}
Ics_Opd *dst;
Ics_Opd *src = new Register_Addr_Opd(reg);
Icode_Stmt *ic_stmt;
if(return_value->get_data_type() == int_data_type){
dst = new Register_Addr_Opd(machine_desc_object.spim_register_table[v1]);
ic_stmt = new Move_IC_Stmt(mov, src, dst);
}
else if(return_value->get_data_type() == double_data_type){
dst = new Register_Addr_Opd(machine_desc_object.spim_register_table[f0]);
ic_stmt = new Move_IC_Stmt(move_d, src, dst);
}
reg->reset_use_for_expr_result();
icl.push_back(ic_stmt);
}
Icode_Stmt *ic_stmt = new Label_IC_Stmt(ret_inst, proc_name);
icl.push_back(ic_stmt);
Code_For_Ast* t = new Code_For_Ast(icl, NULL);
return *t;
}
//////////////////////////////////////////////////////////////////////
Code_For_Ast & Call_Ast::compile_and_optimize_ast(Lra_Outcome & lra) {}
Code_For_Ast & Call_Ast::compile(){
list<Icode_Stmt*> icl = list<Icode_Stmt*>();
Procedure* p = program_object.get_procedure_prototype(procedure_name);
Symbol_Table s = p->get_formal_param_list();
list<Symbol_Table_Entry*> l2 = s.get_table();
Symbol_Table sssss;
list<Symbol_Table_Entry*> l;
for (list<Symbol_Table_Entry*>::iterator i7 = l2.begin(); i7 != l2.end(); i7++){
string nnn((*i7)->get_variable_name());
Symbol_Table_Entry* sss = new Symbol_Table_Entry(nnn, (*i7)->get_data_type(), (*i7)->get_lineno(), sp_ref);
sssss.push_symbol(sss);
}
sssss.set_table_scope(local);
sssss.assign_offsets();
l = sssss.get_table();
list<Symbol_Table_Entry*>::iterator i3 = l.begin();
for(list<Ast*>::iterator i1 = --actual_param_list.end(); i1 != --actual_param_list.begin(); i1--){
Code_For_Ast c = (*i1)->compile();
Register_Descriptor* r = c.get_reg();
list<Icode_Stmt*> l2 = c.get_icode_list();
for (list<Icode_Stmt*>::iterator i2 = l2.begin(); i2 != l2.end(); i2++){
icl.push_back(*i2);
}
Ics_Opd * dst = new Mem_Addr_Opd(**i3);
Ics_Opd* src = new Register_Addr_Opd(r);
i3++;
if((*i1)->get_data_type() == int_data_type){
Icode_Stmt *ic_stmt = new Move_IC_Stmt(store, dst, src);
icl.push_back(ic_stmt);
}
else if ((*i1)->get_data_type() == double_data_type){
Icode_Stmt *ic_stmt = new Move_IC_Stmt(store_d, dst, src);
icl.push_back(ic_stmt);
}
r->reset_use_for_expr_result();
}
Icode_Stmt *ic_stmt = new Label_IC_Stmt(jal, procedure_name);
icl.push_back(ic_stmt);
Register_Descriptor* reg2;
if(node_data_type == int_data_type){
return_value_reg = machine_desc_object.spim_register_table[v1];
reg2 = machine_desc_object.get_new_register<int_reg>();
Ics_Opd *src = new Register_Addr_Opd(return_value_reg);
Ics_Opd *dst= new Register_Addr_Opd(reg2);
Icode_Stmt *ic_stmt = new Move_IC_Stmt(mov, src, dst);
icl.push_back(ic_stmt);
}
else if(node_data_type == double_data_type){
return_value_reg = machine_desc_object.spim_register_table[f0];
reg2 = machine_desc_object.get_new_register<float_reg>();
Ics_Opd *src = new Register_Addr_Opd(return_value_reg);
Ics_Opd *dst = new Register_Addr_Opd(reg2);
Icode_Stmt *ic_stmt = new Move_IC_Stmt(mov, src, dst);
icl.push_back(ic_stmt);
}
return *(new Code_For_Ast(icl, reg2));
} |
50c84ccd3229b15599c91101e57b090e13298e63 | 5ab111a422e95eaa9ddda219cdff4ba9d7da582a | /ptrtofun.cpp | 4647fa3c33afc20de6916924718782246eaa70bc | [] | no_license | Waseem-Raja/c-plusplus | 35ee84b33c01d895008193e8db538929b960c695 | f313f4501b61bf0e3f126bc7ec3d1b93ad7ae6ef | refs/heads/main | 2023-04-25T02:43:28.194278 | 2021-05-11T04:39:12 | 2021-05-11T04:39:12 | 321,020,255 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 1,542 | cpp | ptrtofun.cpp | /*#include<iostream>
using namespace std;
int add(int a,int b)
{
int c=a+b;
cout<<c;
}
int main()
{
int (*addd)(int,int); // decleration of function poniter
addd=add; //here u can write &add as well its optional, add functions address is stored in function pointer addd
(*add)(3,4); // here u can write as add or *add
}
*/
//function pointer as switch
#include<iostream>
using namespace std;
float add(float x, float y)
{
float z=x+y;
cout<<"addition of two numbers is :"<<z<<endl;
}
float minuss(float x, float y)
{
float z=x-y;
cout<<"subtraction of two numbers is :"<<z<<endl;
}
float divsionn(float x, float y)
{
float z=x/y;
cout<<"division of two numbers is :"<<z<<endl;
}
float mull(float x , float y)
{
float z=x*y;
cout<<"multiplication of two numbers is :"<<z<<endl;
}
int main()
{
int choice,a,b;
cout<<"enter 0 for ADD, 1 for sub, 2 for mul, 3 for divide "<<endl;
cout<<"enter the choice"<<endl;
cin>>choice;
if(choice>3||choice<0)
cout<<"invalid choice"<<endl;
else
{
float (*ptr[])(float, float)={add,minuss,mull,divsionn}; //decleration of function pointer here is function pointer
cout<<"enter the ist number"<<endl; //decleared as array cox we have multiple functions
cin>>a;
cout<<"enter the 2nd number"<<endl;
cin>>b;
(ptr[choice])(a,b);
}
}
|
96345add3082e9faf3c9ace73df655527feb6551 | a1c20f842718990ca6041a728f4a3c77bc16a83a | /ApartmentManager/mainwindow.cpp | 76ed5e6e90367bee78eb3d8bbef6d2862fc8e64b | [] | no_license | RasmusAntons/apartmentmanager | 342f8a5664b983cc931eaac7c94e05ad2dcdb65f | 80c78918122cb327a77bd40e00d944b87353300a | refs/heads/master | 2021-01-10T16:15:59.097203 | 2016-04-07T19:23:05 | 2016-04-07T19:23:05 | 55,721,115 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 10,877 | cpp | mainwindow.cpp | #include "mainwindow.h"
#include "ui_mainwindow.h"
QStringList RssText;
// ///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////7
void MainWindow::onTimeChanged() {
QTime time = QTime::currentTime();
QString text = time.toString("hh:mm");
if ((time.second() % 2) == 0)
text[2] = ' ';
ui->clock->display(text);
}
int placeAppo(Ui::MainWindow* ui, QStringList CalDate, QStringList CalText, QStringList CalName)
{
int i = CalDate.length();
ui->TableCal->setRowCount(i);
i = 0;
foreach(const QString &Date, CalDate) {
ui->TableCal->setItem(i,0,new QTableWidgetItem(Date));
ui->tableWidgetMain->setItem(i,0,new QTableWidgetItem(Date));
i++;
}
i = 0;
foreach(const QString &Text, CalText) {
ui->TableCal->setItem(i,1,new QTableWidgetItem(Text));
ui->tableWidgetMain->setItem(i,1,new QTableWidgetItem(Text));
i++;
}
i = 0;
foreach(const QString &Name, CalName) {
ui->TableCal->setItem(i,2,new QTableWidgetItem(Name));
ui->tableWidgetMain->setItem(i,2,new QTableWidgetItem(Name));
i++;
}
return 0;
}
// //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
void placeRss(Ui::MainWindow* ui) {
int i = 0;
int j = 0;
QFont TitleFont( "Ubuntu", 15, QFont::Bold);
foreach(const QString &sRssElement, RssText) {
if((i%2 == 0)) {
ui->RssList->addItem(sRssElement);
ui->RssList->item(j)->setFont(TitleFont);
j++;
} else {
ui->RssList->addItem(sRssElement);
ui->RssList->addItem(" ");
j = j +2;
}
i++;
}
}
void ListElements(QDomElement root, QString tagname, Ui::MainWindow* ui) {
QDomNodeList items = root.elementsByTagName(tagname);
qDebug() << "TotalItems = " << items.count();
for(int i = 0; i < items.count(); i++) {
QDomNode itemnode = items.at(i);
if(itemnode.isElement()) {
QDomElement title = itemnode.firstChildElement();
QDomElement summary = itemnode.lastChildElement();
RssText << title.text();
RssText << summary.text();
//qDebug() << title.text();
//qDebug() << summary.text() << "\n";
}
}
placeRss(ui);
}
void MainWindow::fileIsReady(QNetworkReply *reply){
QByteArray data = reply->readAll();
qDebug() << "XML download size:" << data.size() << "bytes";
//qDebug() << QString::fromUtf8(data);
QDomDocument versionXML;
QString errorStr;
int errorLine;
int errorColumn;
if(!versionXML.setContent(data, true, &errorStr, &errorLine, &errorColumn))
{
qWarning() << "Failed to parse XML";
qDebug() << errorStr << errorLine << errorColumn;
} else {
//qDebug() << "Opened!";TableCal
QDomElement root = versionXML.firstChildElement();
ListElements(root, "entry", ui);
}
}
// //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
void showWeather(QString info, Ui::MainWindow* ui) {
QStringList nTemps;
QStringList dTemps;
QStringList pics;
int i = 0;
foreach(const QString &nTemp, info.split( "font color=#0000ff>" )) {
if(i > 0 && i < 5) {
nTemps << nTemp.left(5).split("°").at(0);
}
i++;
}
i = 0;
foreach(const QString &dTemp, info.split( "font color=#ff0000>" )) {
if(i > 0 && i < 5) {
dTemps << dTemp.left(5).split("°").at(0);
}
i++;
}
i = 0;
foreach(const QString &pic, info.split( "http://www.wetter-vista.de/images/wetter/" )) {
if(i > 0 && i < 9) {
pics << (pic.left(23).split(".").at(0));
}
i++;
}
//qDebug() << nTemps;
//qDebug() << dTemps;
//qDebug() << pics;
ui->wTodayText->setText(nTemps.at(0) + "°C / " + dTemps.at(0) + "°C");
ui->wTomorrowText->setText(nTemps.at(1) + "°C / " + dTemps.at(1) + "°C");
ui->wOvermorrowText->setText(nTemps.at(1) + "°C / " + dTemps.at(2) + "°C");
ui->wTodayImage1->setStyleSheet("background-image: url(weatherImages/" + pics.at(0) + ");");
ui->wTodayImage2->setStyleSheet("background-image: url(weatherImages/" + pics.at(1) + ");");
ui->wTomorrowImage1->setStyleSheet("background-image: url(weatherImages/" + pics.at(2) + ");");
ui->wTomorrowImage2->setStyleSheet("background-image: url(weatherImages/" + pics.at(3) + ");");
ui->wOvermorrowImage1->setStyleSheet("background-image: url(weatherImages/" + pics.at(4) + ");");
ui->wOvermorrowImage2->setStyleSheet("background-image: url(weatherImages/" + pics.at(5) + ");");
}
void getWeather(QDomElement root, Ui::MainWindow* ui) {
QString info;
QDomNodeList channel = root.elementsByTagName("channel");
QDomNode channelN = channel.at(0);
QDomElement channelE = channelN.toElement();
QDomNodeList item = channelE.elementsByTagName("item");
QDomNode itemN = item.at(0);
QDomElement itemE = itemN.lastChildElement();
//qDebug() << itemE.text();
showWeather(itemE.text(), ui);
}
void MainWindow::fileIsReadyW(QNetworkReply *reply){
QByteArray data = reply->readAll();
qDebug() << "XML download size:" << data.size() << "bytes";
QDomDocument versionXML;
QString errorStr;
int errorLine;
int errorColumn;
if(!versionXML.setContent(data, true, &errorStr, &errorLine, &errorColumn))
{
qWarning() << "Failed to parse XML";
qDebug() << errorStr << errorLine << errorColumn;
} else {
//qDebug() << "Opened!";
QDomElement root = versionXML.firstChildElement();
getWeather(root,ui);
}
}
// //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
MainWindow::MainWindow(QWidget *parent) : QMainWindow(parent), ui(new Ui::MainWindow)
{
ui->setupUi(this);
//QWebView *WebView = new QWebView(this);
//ui->tabWidget->addTab(WebView,"Wetter");
//WebView->setGeometry(0,0,1100,900);
//WebView->load(QUrl("http://www.wetter-vista.de/wettervorhersage"));
QPixmap bedeckt("weatherImages/bedeckt.png");
QPixmap heiter("weatherImages/heiter.png");
QPixmap regen("weatherImages/regen.png");
QPixmap regen_leicht("weatherImages/regen-leicht.png");
QPixmap regenschauer_leicht("weatherImages/regenschauer-leicht.png");
QPixmap sonne("weatherImages/sonne.png");
QPixmap wolkig("weatherImages/wolkig.png");
//Time
TThread = new TimeThread(this);
connect(TThread, SIGNAL(TimeChanged()), this, SLOT(onTimeChanged()));
connect(TThread, SIGNAL(finished()), TThread, SLOT(deleteLater()));
TThread->start();
//Calender
ui->TableCal->setColumnCount(3);
ui->TableCal->setRowCount(10);
ui->TableCal->setColumnWidth(0, 300);
ui->TableCal->setColumnWidth(1, 600);
ui->TableCal->setColumnWidth(2, 200);
ui->TableCal->horizontalHeader()->setStretchLastSection(true);
ui->TableCal->setHorizontalHeaderLabels(QString("Datum; Text; Name").split(";"));
//Calender main
ui->tableWidgetMain->setColumnCount(3);
ui->tableWidgetMain->setRowCount(7);
ui->tableWidgetMain->setColumnWidth(0, 300);
ui->tableWidgetMain->setColumnWidth(1, 600);
ui->tableWidgetMain->setColumnWidth(2, 200);
ui->tableWidgetMain->horizontalHeader()->setStretchLastSection(true);
ui->tableWidgetMain->setHorizontalHeaderLabels(QString("Datum; Text; Name").split(";"));
//RSS News
QNetworkAccessManager * manager = new QNetworkAccessManager(this);
connect(manager, SIGNAL(finished(QNetworkReply*)), this, SLOT(fileIsReady(QNetworkReply*)));
manager->setNetworkAccessible(QNetworkAccessManager::Accessible);
manager->get(QNetworkRequest(QUrl("http://www.tagesschau.de/xml/atom/")));
ui->RssList->setWordWrap(true);
ui->RssList->setTextElideMode(Qt::ElideNone);
//Weather
QNetworkAccessManager * managerW = new QNetworkAccessManager(this);
connect(managerW, SIGNAL(finished(QNetworkReply*)), this, SLOT(fileIsReadyW(QNetworkReply*)));
managerW->setNetworkAccessible(QNetworkAccessManager::Accessible);
managerW->get(QNetworkRequest(QUrl("http://www.wetter-vista.de/wettervorhersage/wetter-braunschweig-1056.xml")));
ui->wTodayText->setAlignment(Qt::AlignCenter);
ui->wTomorrowText->setAlignment(Qt::AlignCenter);
//ui->textBrowser->setSource(QUrl("w.htm"));
//ui->webViewAuto->load(QUrl::fromLocalFile("w.htm"));
//Set Calender
QStringList CalDate;
CalDate << "2016-03-24 09:00:00" << "2016-04-01 11:30:00" << "2016-05-01 11:30:00" << "2016-04-01 13:30:00";
QStringList CalText;
CalText << "apple" << "pear" << "peach" << "tomato" << "test";
QStringList CalName;
CalName << "Rasmus" << "Maximilian" << "Rasmus" << "Maximilian";
placeAppo(ui, CalDate, CalText, CalName);
//placeRss(ui);
}
MainWindow::~MainWindow()
{
if (TThread != 0 && TThread->isRunning() ) {
TThread->requestInterruption();
TThread->wait();
}
delete ui;
}
/*
void QParent::resizeEvent(QResizeEvent *event) {
ui->TableCal->setColumnWidth(0, this->width()/3);
ui->TableCal->setColumnWidth(1, this->width()/3);
ui->TableCal->setColumnWidth(2, this->width()/3);
QMainWindow::resizeEvent(event);
}
*/
/*
int placeAppo(Ui::MainWindow* ui, QString Dates[], QString Texts[], QString Names[])
{
int x = Dates->length();
QString s = QString::number(x);
qDebug() << s;
for(int i = 0; i < Dates->length()-1; i++) {
ui->DateList->addItem(Dates[i]);
}
for(int i = 0; i < Texts->length()-1; i++) {
ui->TextList->addItem(Texts[i]);
}
for(int i = 0; i < Names->length()-1; i++) {
ui->NameList->addItem(Names[i]);
}
return 0;
}
QString *Dates = new QString[20];
QString *Texts = new QString[20];
QString *Names = new QString[20];
Dates[0] = "2016-03-24 09:00:00";
Dates[1] = "2016-04-01 11:30:00";
Dates[2] = "2016-03-24 09:00:00";
Dates[3] = "2016-04-01 11:30:00";
Dates[4] = "2016-03-24 09:00:00";
Dates[5] = "2016-04-01 11:30:00";
Texts[0] = "Termi2";
Texts[1] = "test";
Names[0] = "Maximilian";
Names[1] = "Rasmus";
placeAppo(ui, Dates, Texts, Names);
*/
|
6efca80fd64a74adf711d23284153eb072789efc | 21d0756e90c916684d531edc45ba6a4707c654f4 | /include/irods/private/re/python/types/standard/arrays.hpp | 7d49b97ca46262d098dd2f9474afb13ce487f2c1 | [] | no_license | irods/irods_rule_engine_plugin_python | 8db27464a1898613849d4f216a60e20afb5665d8 | 773105f6c429ad708adfbf292164dfc9aaf3e3cf | refs/heads/main | 2023-08-06T19:30:05.326697 | 2023-07-28T20:30:13 | 2023-07-28T20:51:16 | 37,076,977 | 7 | 13 | null | 2023-07-28T20:51:17 | 2015-06-08T15:55:22 | C++ | UTF-8 | C++ | false | false | 357 | hpp | arrays.hpp | #ifndef RE_PYTHON_TYPES_STANDARD_ARRAYS_HPP
#define RE_PYTHON_TYPES_STANDARD_ARRAYS_HPP
namespace irods::re::python::types
{
void export_int_array();
void export_char_array();
void export_unsigned_char_array();
void export_c_string();
void export_c_string_array();
} //namespace irods::re::python::types
#endif // RE_PYTHON_TYPES_STANDARD_ARRAYS_HPP
|
68149d33873f455a909f79fb57bcca88a937c9dd | 0f01dab3b868e94298fc54d5b449c71f435a56e3 | /游戏组件/子游戏/百人龙虎斗(机器人+控制+真人下注显示)/客户端组件/GameLogic.cpp | 9059f68936dbd833894a39535772e652e1417df5 | [] | no_license | ydcrow/refFoxuc | c6284476ed530263a5ffb8f8e7d37251e393c0d2 | f85601c050bb5f24883c88bbef0982b16ff952e3 | refs/heads/master | 2023-02-07T06:03:06.317797 | 2020-12-26T02:49:37 | 2020-12-26T02:49:37 | null | 0 | 0 | null | null | null | null | GB18030 | C++ | false | false | 1,109 | cpp | GameLogic.cpp | #include "StdAfx.h"
#include "GameLogic.h"
//////////////////////////////////////////////////////////////////////////
//扑克数据
BYTE CGameLogic::m_cbCardListData[52]=
{
0x01,0x02,0x03,0x04,0x05,0x06,0x07,0x08,0x09,0x0A,0x0B,0x0C,0x0D, //方块 A - K
0x11,0x12,0x13,0x14,0x15,0x16,0x17,0x18,0x19,0x1A,0x1B,0x1C,0x1D, //梅花 A - K
0x21,0x22,0x23,0x24,0x25,0x26,0x27,0x28,0x29,0x2A,0x2B,0x2C,0x2D, //红桃 A - K
0x31,0x32,0x33,0x34,0x35,0x36,0x37,0x38,0x39,0x3A,0x3B,0x3C,0x3D //黑桃 A - K
};
//////////////////////////////////////////////////////////////////////////
//构造函数
CGameLogic::CGameLogic()
{
}
//析构函数
CGameLogic::~CGameLogic()
{
}
//获取牌点
BYTE CGameLogic::GetCardPip(BYTE cbCardData)
{
return (cbCardData&0x0F);
}
//获取牌点
BYTE CGameLogic::GetCardListPip(const BYTE cbCardData[], BYTE cbCardCount)
{
//变量定义
BYTE cbPipCount=0;
//获取牌点
for (BYTE i=0;i<cbCardCount;i++)
{
cbPipCount=(GetCardPip(cbCardData[i])+cbPipCount)%10;
}
return cbPipCount;
}
//////////////////////////////////////////////////////////////////////////
|
d2e5fb9aa033676796a1ac0c90e973fd469a4da5 | d448ec171b9c83e3113cb5124d0fdd7c98613fbb | /PAEngine/source/InputType.cpp | 1e8e546c39aa2d6ce80f0dfc42e91bbab64e6155 | [
"MIT"
] | permissive | wnsrl7659/Project-ToyTank | 5c7482af8ba735595fa98d2b673c250c8ca80c2d | 8b806f7cf304056eb38e1436b3f5c0e9d1bb51e0 | refs/heads/master | 2023-08-22T03:42:21.887048 | 2021-09-26T02:31:16 | 2021-09-26T02:31:16 | 403,217,182 | 1 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 1,304 | cpp | InputType.cpp | /**
* @file InputType.cpp
*
* @brief It's an implementation file of InputType.h
*
* @author Minsu Kang
*
* @copyright (c) DigiPen Institute of Technology
*/
#include "pch.h"
#include "InputType.h"
namespace PAEngine
{
//////////////////////////////////////////////////////////////////////////////
// BindInfo Class ////////////////////////////////////////////////////////////
BindInfo::BindInfo() : m_keyCode(0), m_keyState(KeyState::JustReleased) {};
BindInfo::BindInfo(unsigned int keyCode, const KeyState keyState) : m_keyCode(keyCode), m_keyState(keyState)
{
// Convert a small letter to a capital one
if (97 <= keyCode && keyCode <= 122)
keyCode -= 32;
};
//////////////////////////////////////////////////////////////////////////////
// GameCommand Class /////////////////////////////////////////////////////////
GameCommand::GameCommand() : m_chord(0) {};
GameCommand::GameCommand(unsigned int keyCode, const KeyState keyState)
{
// Convert a small letter to a capital one
if (97 <= keyCode && keyCode <= 122)
keyCode -= 32;
m_chord.push_back(BindInfo(keyCode, keyState));
}
GameCommand::GameCommand(const BindInfo& bi)
{
m_chord.push_back(bi);
};
GameCommand::GameCommand(const std::vector<BindInfo>& chord) : m_chord(chord) {};
} |
b2ecfd10ae86202efb0af6a37198f95f1fbc780e | 315fd47690450e7a0530bf4b3596cc9448c88929 | /aoj/13/1320.cpp | 7ae7aeb083724e28fad4e8f82d0acc72d7c72955 | [] | no_license | 1119-2916/competitive-programming | 8d59f2c3c36de719d665307fcaa138cc03845573 | 356b66d2f93bf6e28f04af8968e0f1f6ae4d7bae | refs/heads/master | 2021-06-08T14:33:14.620002 | 2020-04-26T14:01:44 | 2020-04-26T14:01:44 | 108,534,522 | 3 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 3,202 | cpp | 1320.cpp | #include <bits/stdc++.h>
using namespace std;
#define INF 1001000100010001000
#define MOD 1000000007
#define EPS 1e-10
#define int long long
#define rep(i, N) for (int i = 0; i < N; i++)
#define Rep(i, N) for (int i = 1; i < N; i++)
#define For(i, a, b) for (int i = (a); i < (b); i++)
#define pb push_back
#define eb emplace_back
#define mp make_pair
#define pii pair<int, int>
#define vi vector<int>
#define vvi vector<vi >
#define vb vector<bool>
#define vvb vector<vb >
#define vp vector< pii >
#define all(a) (a).begin(), (a).end()
#define Int(x) int x; cin >> x;
#define int2(x, y) Int(x); Int(y);
#define int3(x, y, z) Int(x); int2(y, z);
#define in(x, a, b) ((a) <= (x) && (x) < (b))
#define fir first
#define sec second
#define ffir first.first
#define fsec first.second
#define sfir second.first
#define ssec second.second
#define Decimal fixed << setprecision(10)
//int dxy[5] = {0, 1, 0, -1, 0};
// cmd
bool inner(string a, string b)
{
if (a.size() < b.size()) {
return false;
}
rep(i, a.size() - b.size() + 1) {
bool fl = true;
rep(j, b.size()) {
if (a[i + j] != b[j]) fl = false;
}
if (fl) return true;
}
return false;
}
bool yui(string a, string b, int p)
{
rep(i, b.size()) {
if (p + i < a.size()) {
if (a[p+i] != b[i]) return false;
} else {
break;
}
}
return true;
}
int funami(string a, string b)
{
int as = a.size(), bs = b.size();
rep(i, a.size()) {
if (yui(a, b, i)) return (bs - as + i);
}
return b.size();
}
void calc(vector<string> &data, vvi &dist)
{
rep(i, data.size()) {
rep(j, data.size()) {
dist[i][j] = funami(data[i], data[j]);
}
}
}
signed Main(int n)
{
vector<string> input(n);
rep(i, n) {
cin >> input[i];
}
vi state(n, 0);
rep(i, n) {
rep(j, n) {
if (i == j) continue;
if (inner(input[i], input[j])) state[j] = 1;
}
}
vector<string> data;
rep(i, n) {
if (!state[i]) data.pb(input[i]);
}
n = data.size();
/*
rep(i, n) {
std::cout << data[i] << std::endl;
}
*/
vvi dist(n, vi(n, 0));
calc(data, dist);
/*
rep(i, n) {
rep(j, n) {
std::cout << dist[i][j] << " ";
}
cout << endl;
}
*/
vvi dp(1 << 15, vi(15, INF));
rep(i, n) {
dp[1 << i][i] = data[i].size();
}
Rep(i, 1 << n) {
rep(j, n) {
if (!(i & (1 << j))) continue;
rep(k, n) {
int p = (1 << k);
if (i & p) continue;
dp[i | p][k] = min(dp[i | p][k], dp[i][j] + dist[j][k]);
}
}
}
/*
rep(i, (1 << n)) {
rep(j, n) {
cout << dp[i][j] << " ";
}
std::cout << std::endl;
}
*/
int ans = INF;
rep(i, n) ans = min(ans, dp[(1 << n) -1][i]);
std::cout << ans << std::endl;
return 0;
}
signed main()
{
std::ios::sync_with_stdio(false);
std::cin.tie(0);
Int(tmp);
while (tmp) {
Main(tmp);
cin >> tmp;
}
}
|
95cfb6a078eb885304fe6a6e7b32c4349e316b08 | fe4b368fa2a7b959f3000e45dedf334aaa8f1d05 | /AlgoA-Pertemuan8-5180711018.cpp | fe0c905af226672d52f513f8c82fc11b213979da | [] | no_license | hanipabdullah/TugasAlgo | 28d46aef77be8ac073ee503b98cd2b34dc12a6ed | 16805c7ec5eb1d5bc257d60930f060bf151a0762 | refs/heads/master | 2020-05-09T13:23:24.550708 | 2019-04-13T09:41:45 | 2019-04-13T09:41:45 | 181,150,174 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 1,165 | cpp | AlgoA-Pertemuan8-5180711018.cpp | #include<iostream>
using namespace::std;
float input(string text)
{
double angka;
cout<<" Inputkan Nilai "<<text<<" : "; cin>>angka;
return angka;
}
void nilai (float dapat)
{
if(dapat>80)
{
cout<<" Anda Dapat Nilai (A) ";
}
else if(dapat>60)
{
cout<<" Anda Dapat Nilai (B) ";
}
else if(dapat>40)
{
cout<<" Anda Dapat Nilai (C) ";
}
else if(dapat>20)
{
cout<<" Anda Dapat Nilai (D) ";
}
else if(dapat>0)
{
cout<<" Anda Dapat Nilai (E) ";
}
}
struct akhir
{
double uts,uas,tugas,absen;
float a,b,c,d;
};
main()
{
float dapat;
akhir nilai1;
nilai1.uts=input(" UTS ");
nilai1.uas=input(" UAS ");
nilai1.tugas=input(" TUGAS ");
nilai1.absen=input(" ABSENSI ");
cout<<endl;
nilai1.a=nilai1.uts*20/100;
nilai1.b=nilai1.uas*30/100;
nilai1.c=nilai1.tugas*35/100;
nilai1.d=nilai1.absen*15/100;
dapat=nilai1.b+nilai1.a+nilai1.c+nilai1.d;
cout<<" Hasil Akhir Nilai Anda : "<<dapat<<endl;
nilai(dapat);
cout<<endl;
}
|
9df5871f6b52c1951a3bf3ea6da583ad97739ddf | e16058f3eb62ffe6abaf8595910585028c5873be | /csc402/assignment6/arrayBsTree.h | 7ca82455b5fe12c360040c21ae85857cd4c0012a | [] | no_license | ccarr419/Academic-Projects | 6b38c7f077cd49c1c86d000b1e47e1c8446ba631 | 71967751b4233f57e858944562db38cf506fc5d3 | refs/heads/master | 2023-06-07T17:36:59.265211 | 2020-08-14T14:30:11 | 2020-08-14T14:30:11 | 51,627,389 | 0 | 0 | null | 2023-05-31T20:19:03 | 2016-02-13T01:43:09 | Java | UTF-8 | C++ | false | false | 1,088 | h | arrayBsTree.h | /*
Author: Christian Carreras
File: treeGraph.h
Date: 10/18/2015
Class: CSC 402
About: Header file for treeGraph. treeGraph is a binary tree
that ties together nodes in accordance to their values.
This basic binary tree can insert nodes into the tree
and print the tree in order, pre order or post order.
*/
#ifndef ARRAYBSTREE_H
#define ARRAYBSTREE_H
#include <iostream>
#include "bsTree.h"
class arrayBsTree : public bsTree {
public:
arrayBsTree();
bool find(int) const;
void insert(int);
void erase(int);
void inOrder(std::ostream&) const; //NLR
void preOrder(std::ostream&) const; //LNR
void postOrder(std::ostream&) const; //LRN
void lvlOrder(std::ostream&) const; //Print by height
private:
treeNode<int>* root;
int nodeCount;
//private helper functions for specific traversals
void printInOrder(treeNode<int>*, std::ostream&) const;
void printPreOrder(treeNode<int>*, std::ostream&) const;
void printPostOrder(treeNode<int>*, std::ostream&) const;
void printLvlOrder(treeNode<int>*, std::ostream&) const;
};
#endif
|
342f284b0e89c32a4859bac2d2ace06c613e44a2 | eaff3f7a95e30bdb897c91c6e01c5281f56142f9 | /src/ros_threads/src/ThreadsServer.cpp | d26db6c42c941d3ce28ed007f611a7d8880d8d29 | [] | no_license | sumejko92/pavel-tasks | fcfeeea871c434ea1afdbc7908baa98b8a5ca3b3 | 647e8665aaacb88d17c4b5487143e277ae4e9b61 | refs/heads/master | 2021-05-23T05:21:49.141537 | 2019-10-22T07:05:18 | 2019-10-22T07:05:18 | 95,138,999 | 0 | 2 | null | 2019-10-22T07:05:19 | 2017-06-22T17:14:43 | C++ | UTF-8 | C++ | false | false | 2,848 | cpp | ThreadsServer.cpp | /*
* Copyright (c) ??? - All Rights Reserved
* Unauthorized copying of this file, via any medium is strictly prohibited
* Proprietary and confidential
* Authors: Pavel Shumejko
*/
#include "ros/ros.h"
#include "ros_threads/TimeDelay.h"
#include "string"
#include "thread"
#include "chrono"
/**
* This class contains the functions for a ros node that advertise ROS service /unix_time_now that takes an integer Delay_s as request and replies with a string Time
*
*/
class Server
{
public:
Server() { }
/**
* Callback function for the server service which based on the service call argument (Delay_s) sends
* back the response (unix time up to milisec) with or without a delay. To add a delay another
* thread function (startThread) is called.
* @param req gets the request from the service call
* @param res stores the response of the service
*/
bool serviceCallback(ros_threads::TimeDelay::Request &req,
ros_threads::TimeDelay::Response &res);
/**
* Thread function to implement the delay and send back the response.
* @param td gets the time delay
* @param response gets the time when the service was called
*/
void startThread(int td,std::string response);
};
void Server::startThread(int td,std::string response)
{
std::this_thread::sleep_for(std::chrono::milliseconds(static_cast<int>(td*1000))); // adds delay
ROS_INFO_STREAM("Sending back response AFTER DELAY: " + response);
}
bool Server::serviceCallback(ros_threads::TimeDelay::Request &req,
ros_threads::TimeDelay::Response &res)
{
ros::Time result = ros::Time::now(); // grab the time when service was called
int milisec = result.nsec/1000; // get the ms
res.Time = std::to_string(result.sec) + "." + std::to_string(milisec); // create response of type string
ROS_INFO("Receiving request: Delay=%ld", (long int)req.Delay_s);
// Starts a thread or sends back the response instantly depending on the Delay_s value
if(req.Delay_s > 0 && req.Delay_s < 3)
{
std::thread t(&Server::startThread,this,req.Delay_s,res.Time); // calls the thread function
t.detach();
}
else
{
ROS_INFO_STREAM("sending back response: " + res.Time);
}
return true;
}
int main(int argc, char **argv)
{
// rosnode initialization
ros::init(argc, argv, "threads_server");
// Create the handle
ros::NodeHandle n;
// Create the object
Server server;
// Creates the service which calls the class functions
ros::ServiceServer server_service = n.advertiseService("/unix_time_now", &Server::serviceCallback,&server);
ROS_INFO("Feel free to call the service");
ros::Rate rate_hz(1.0);
while (n.ok())
{
rate_hz.sleep();
ros::spinOnce();
}
return 0;
}
|
7f87b6e9c100b73513cec52b1f6de82abbea8fdf | 20d1c5315595c731a2b0e6846af068e791d0aa2e | /C++17Study/14_constexpr_Lambda_Expressions.cpp | 2e3f2253f049df985fad09b97d47b9e52630b09d | [] | no_license | WhiteCri/Cpp17Study | 15b71aaad3ce91da279f8461e23e50b43b179d30 | 5d5eb259d63e239fe222a71e7d6b0390d3a2c7f7 | refs/heads/master | 2021-05-21T19:45:18.261239 | 2020-04-06T12:28:58 | 2020-04-06T12:28:58 | 252,775,022 | 0 | 1 | null | null | null | null | UTF-8 | C++ | false | false | 639 | cpp | 14_constexpr_Lambda_Expressions.cpp | #include <iostream>
//Since C++17 lambda expressions (their call operator operator()) that follow the rules of
//standard constexpr functions are implicitly declared as constexpr
int main() {
constexpr auto SquareLambda = [](int n) {return n * n; };
static_assert(SquareLambda(3) == 10, "her!");
}
//features of constexpr functions
/*
- they cannot be virtual
- their return type shall be a literal type
- their parameter types shall be a literal type
- their function bodies cannot contain: asm definition, a goto statement, try-block, or
a variable that is a non-literal type or static or thread storage duration
*/ |
bba73442631fcb58d6df3131322823813cf372bd | 963a759f023c5da4762bd9b6414ee21f95a23d28 | /ch10/ex10_31.cpp | 753bbf94824bd0f5296b596b6650bfff801a1631 | [
"CC0-1.0"
] | permissive | zhangzhizhongz3/CppPrimer | af0fa2d3a8ac69e521dffac25053af088ee62fe0 | effe6505e417023124ed3ff41451c64dcf2cdfda | refs/heads/master | 2020-12-25T03:00:13.512787 | 2016-09-15T04:25:25 | 2016-09-15T04:25:25 | 62,138,513 | 0 | 0 | null | 2016-06-28T12:22:23 | 2016-06-28T12:22:23 | null | UTF-8 | C++ | false | false | 606 | cpp | ex10_31.cpp | //
// ex10_31.cpp
// Exercise 10.31
//
// Created by pezy on 12/13/14.
// Copyright (c) 2014 pezy. All rights reserved.
//
// Update the program from the previous exercise so that it prints only the
// unique elements. Your program should use unqiue_copy.
#include <iostream>
#include <iterator>
#include <vector>
#include <algorithm>
using namespace std;
int main()
{
istream_iterator<int> in_iter(cin), eof;
vector<int> ivec;
copy(in_iter, eof, back_inserter(ivec));
sort(ivec.begin(), ivec.end());
unique_copy(ivec.cbegin(), ivec.cend(), ostream_iterator<int>(cout, " "));
}
|
ce07e4ee1e63b371be86523e059a5928a35be614 | f41dba42b2aaf9df9b52e09e47cdc25da2e6e0e9 | /Greedy/Max_Set_of_Disjoint_Intervals.cpp | ca1f15b8506c8bf2768e731617504a3df9e1f4e0 | [] | no_license | Satzyakiz/CP | 5c9642fdede7fbe213fb98f259deda978712ef49 | e869dfd2bd6f3fc692e9223c2d370b5c95904701 | refs/heads/master | 2023-03-02T11:52:52.472154 | 2021-02-03T06:50:32 | 2021-02-03T06:50:32 | 258,285,110 | 1 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 1,372 | cpp | Max_Set_of_Disjoint_Intervals.cpp | // Given a set of N intervals denoted by 2D array A of size N x 2, the task is
// to find the length of maximal set of mutually disjoint intervals.
//
// Two intervals [x, y] & [p, q] are said to be disjoint if they do not
// have any point in common.
//
// Return a integer denoting the length of maximal set of mutually
// disjoint intervals.
// Input 1:
//
// A = [
// [1, 4]
// [2, 3]
// [4, 6]
// [8, 9]
// ]
// Input 2:
//
// A = [
// [1, 9]
// [2, 3]
// [5, 7]
// ]
//
//
// Example Output
// Output 1:
//
// 3
// Output 2:
//
// 2
//
//
// Example Explanation
// Explanation 1:
//
// Intervals: [ [1, 4], [2, 3], [4, 6], [8, 9] ]
// Intervals [2, 3] and [1, 4] overlap.
// We must include [2, 3] because if [1, 4] is included then
// we cannot include [4, 6].
// We can include at max three disjoint intervals: [[2, 3], [4, 6], [8, 9]]
// Explanation 2:
//
// Intervals: [ [1, 9], [2, 3], [5, 7] ]
// We can include at max two disjoint intervals: [[2, 3], [5, 7]]
bool compare(const vector<int> A,const vector<int> B){
return A[1] < B[1];
}
int Solution::solve(vector<vector<int> > &A) {
sort(A.begin(),A.end(),compare);
int ans = 1, j = 0;
for(int i=1; i<A.size(); i++){
if(A[j][1] < A[i][0]){
ans++;
j = i;
}
}
return ans;
}
|
d9adeaa1b6031b7ffa0f08b483d8ab8f39922d90 | 4516a547d243dd79b329303705499f639f873407 | /server/db.h | 93d3c7e175bf740c3774d9d880bdfe3479f09615 | [] | no_license | hubmaker/Arrive-Alive-SWIFT | 89ae4bb3eced56a465c365556b40ed604cfcb1a3 | bd48b9f874bec396a93768e25fa2eac2cc596869 | refs/heads/master | 2022-10-26T03:56:59.524272 | 2020-05-26T14:07:56 | 2020-05-26T14:07:56 | 267,031,914 | 0 | 0 | null | 2020-05-26T12:05:11 | 2020-05-26T12:05:10 | null | UTF-8 | C++ | false | false | 466 | h | db.h | #pragma once
#include <iostream>
#include <mysql.h>
#include <string>
#include <mutex>
#pragma comment (lib , "libmysql.lib")
class DB {
private:
MYSQL * connection, conn;
MYSQL_RES *sql_result;
MYSQL_ROW sql_row;
int query_stat;
std::mutex DB_mtx;
public:
int class_stat;
DB();
DB(const char* host, const char* user, const char* passwd, const char* db);
bool exit_db();
std::string search(const char* table, int args, ...);
}; |
94a181cb6518a5be3d523d45d6ecfa2808b6a8ac | f0b6c15feb1f63ca945fe073135599993084b08d | /src/testApp.cpp | 1829006c47855f09490a3fe7fca1a1d42c370099 | [] | no_license | ryanbartley/SpacebrewoFX1 | 1d2f0b20beb5b985e640e3e31bd74444b4110f0d | 2ecbd2d2a533cf7a1c82f4495dc5ca51fe36746f | refs/heads/master | 2021-01-25T06:36:42.305089 | 2013-02-13T02:08:58 | 2013-02-13T02:08:58 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 2,449 | cpp | testApp.cpp | #include "testApp.h"
//--------------------------------------------------------------
void testApp::setup(){
ofSetFrameRate(60);
string host = "54.235.111.53";
string name = "of-button-example";
string description = "It's amazing";
spacebrew.addPublish("button", Spacebrew::TYPE_BOOLEAN);
spacebrew.addSubscribe("backgroundOn", Spacebrew::TYPE_BOOLEAN);
spacebrew.connect(host, name, description);
Spacebrew::addListener(this, spacebrew);
bButtonPressed = false;
radius = 200;
bBackgroundOn = false;
ofBackground(0);
ofSetRectMode(OF_RECTMODE_CENTER);
ofEnableSmoothing();
ofSetCircleResolution(100);
}
//--------------------------------------------------------------
void testApp::update(){
}
//--------------------------------------------------------------
void testApp::draw(){
if ( !bBackgroundOn ) {
ofBackgroundGradient(ofColor(0,0,0), ofColor(50,50,50));
} else {
ofBackgroundGradient(ofColor(100,0,0), ofColor(150,150,150));
}
string textToDraw = "PRESS ME";
if ( bButtonPressed ) {
ofSetColor(150, 0, 0);
textToDraw = "THANKS";
} else {
ofSetColor(150);
}
ofCircle(ofGetWidth() / 2.0f, ofGetHeight() / 2.0f, radius);
ofSetColor(255);
ofDrawBitmapString(textToDraw, ofGetWidth() / 2.0f, ofGetHeight() / 2.0f);
}
void testApp::onMessage( Spacebrew::Message & m ) {
if (m.name == "backgroundOn")
bBackgroundOn = m.valueBoolean();
}
//--------------------------------------------------------------
void testApp::keyPressed(int key){
}
//--------------------------------------------------------------
void testApp::mousePressed(int x, int y, int button){
if ( checkInsideCircle(ofPoint(x,y), ofPoint(ofGetWidth() / 2.0f, ofGetHeight() / 2.0f), radius)) {
bButtonPressed = true;
spacebrew.sendBoolean("button", true);
}
}
//--------------------------------------------------------------
void testApp::mouseReleased(int x, int y, int button){
if (bButtonPressed) {
spacebrew.sendBoolean("button", false);
}
bButtonPressed = false;
}
bool testApp::checkInsideCircle(ofPoint point, ofPoint position, int radius) {
return ( point.x < position.x + radius
&& point.x > position.x - radius
&& point.y < position.y + radius
&& point.y > position.y - radius);
} |
3cc53e7301b02842373739b01c417f5bff0f9788 | c1141c6e3d19577163befc4369e023c2cb44eb05 | /SphereCollatz.c++ | f5507c1fe7460497b218d957758265be0d743965 | [] | no_license | bkvanvig/Collatz-Conjecture | 725cce37e50b060b89466ad5a0051a2bd936a6d7 | b7ec9532ef5c13ca700b324b6932198e7948aa5c | refs/heads/master | 2021-01-20T22:04:50.927329 | 2016-07-05T16:40:03 | 2016-07-05T16:40:03 | 62,745,960 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 4,950 | SphereCollatz.c++ | // --------------------------
// projects/collatz/Collatz.h
// Copyright (C) 2015
// Glenn P. Downing
// --------------------------
#ifndef Collatz_h
#define Collatz_h
// --------
// includes
// --------
#include <cassert> // assert
#include <iostream> // endl, istream, ostream
#include <sstream> // istringstream
#include <string> // getline, string
#include <utility> // make_pair, pair
using namespace std;
// ------------
// collatz_read
// ------------
/**
* read two ints
* @param s a string
* @return a pair of ints, representing the beginning and end of a range, [i, j]
*/
pair<int, int> collatz_read (const string& s);
// ------------
// collatz_eval
// ------------
/**
* @param i the beginning of the range, inclusive
* @param j the end of the range, inclusive
* @return the max cycle length of the range [i, j]
*/
int collatz_eval (int i, int j);
// -------------
// collatz_calc
// -------------
/**
* calculate cycle length of i
*/
int collatz_calc (int i);
// -------------
// populate_cache
// -------------
/**
* fill in cycle lengths for indicies i-j
*/
void populate_cache (int i, int j);
// -------------
// collatz_print
// -------------
/**
* print three ints
* @param w an ostream
* @param i the beginning of the range, inclusive
* @param j the end of the range, inclusive
* @param v the max cycle length
*/
void collatz_print (ostream& w, int i, int j, int v);
// -------------
// collatz_solve
// -------------
/**
* @param r an istream
* @param w an ostream
*/
void collatz_solve (istream& r, ostream& w);
#endif // Collatz_h
using namespace std;
#define CACHE 1
#ifdef CACHE
int init_cache = 0;
unsigned int cache [1000001] = {(unsigned)0};
#endif
// ------------
// collatz_read
// ------------
pair<int, int> collatz_read (const string& s) {
istringstream sin(s);
int i;
int j;
sin >> i >> j;
return make_pair(i, j);}
// ------------
// collatz_eval
// ------------
int collatz_eval (int i, int j) {
// <your code>
int max_cycle_length = 0;
int curr_cycle_length = 0;
if (i>j){
int temp = i;
i = j;
j = temp;
}
assert (i<=j);
assert(i>0);
if (CACHE && init_cache == 0){
populate_cache(1, 10000);
init_cache = 1;
}
for (int bound = i; bound<=j; bound++){
if (CACHE){
if (cache[bound]!=0)
curr_cycle_length=cache[bound];
else {
curr_cycle_length= collatz_calc(bound);
cache[bound] = curr_cycle_length;
}
}
else
curr_cycle_length = collatz_calc(bound);
max_cycle_length = curr_cycle_length > max_cycle_length ? curr_cycle_length : max_cycle_length;
}
assert(max_cycle_length >0);
return max_cycle_length;}
// -------------
// collatz_calc
// -------------
int collatz_calc (int i){
int cycle_length = 0;
while (i != 1){
if ((i%2)==1){
i = i + (i>>1) + 1;
cycle_length+=2;
}
else{
i = i>>1;
cycle_length++;
}
}
return cycle_length+1;
}
// -------------
// collatz_calc
// -------------
void populate_cache (int i, int j){
assert(i > 0);
assert(i <= 1000000);
assert(j > 0);
assert(j <= 1000000);
if (i>j){
int temp = i;
i = j;
j = temp;
}
assert (i<=j);
while(i<=j){
cache[i]=collatz_calc(i);
++i;
}
return;
}
// -------------
// collatz_print
// -------------
void collatz_print (ostream& w, int i, int j, int v) {
w << i << " " << j << " " << v << endl;}
// -------------
// collatz_solve
// -------------
void collatz_solve (istream& r, ostream& w) {
string s;
while (getline(r, s)) {
const pair<int, int> p = collatz_read(s);
const int i = p.first;
const int j = p.second;
const int v = collatz_eval(i, j);
collatz_print(w, i, j, v);}}
// -------------------------------
// projects/collatz/RunCollatz.c++
// Copyright (C) 2015
// Glenn P. Downing
// -------------------------------
// -------
// defines
// -------
#ifdef ONLINE_JUDGE
#define NDEBUG
#endif
// --------
// includes
// --------
#include <iostream> // cin, cout
// ----
// main
// ----
int main () {
using namespace std;
collatz_solve(cin, cout);
return 0;}
/*
% g++-4.8 -pedantic -std=c++11 -Wall Collatz.c++ RunCollatz.c++ -o RunCollatz
% cat RunCollatz.in
1 10
100 200
201 210
900 1000
% RunCollatz < RunCollatz.in > RunCollatz.out
% cat RunCollatz.out
1 10 1
100 200 1
201 210 1
900 1000 1
% doxygen -g
// That creates the file Doxyfile.
// Make the following edits to Doxyfile.
// EXTRACT_ALL = YES
// EXTRACT_PRIVATE = YES
// EXTRACT_STATIC = YES
% doxygen Doxyfile
// That creates the directory html/.
*/
| |
5cf97418750491cfc0d456507d463fcef75abbf7 | 6e55e2a8d177eb7ec64d3820b7c6066f87ac4783 | /scripts/dp/32_longest-valid-parentheses.cpp | ba1a6c8de6127b18ddb24304a4ef2c33e5035fa9 | [] | no_license | superMC5657/self_leetcode | ecf56f5a326a35232b2478a436fce802cdca5437 | e53cd9fcd07beec1396e0fa1af203855e2140547 | refs/heads/master | 2021-07-04T17:14:48.503017 | 2020-11-19T05:45:51 | 2020-11-19T05:45:51 | 201,088,256 | 1 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 2,056 | cpp | 32_longest-valid-parentheses.cpp | /* -*- coding: utf-8 -*-
!@time: 2019-09-17 13:45
!@author: superMC @email: 18758266469@163.com
!@fileName: 32_longest.cpp
*/
#include <environment.h>
#include <function.hpp>
class Solution {
public:
int longestValidParentheses(string s) {
int res = 0;
int left = 0;
int mark = 0;
for (int i = 0; i < s.size(); ++i) {
int prev_mark = mark;
mark = max(0, mark + ((s[i] == '(') ? 1 : -1));
if (mark == 0) {
if (prev_mark > 0) {
res = max(i - left + 1, res);
} else {
left = i + 1;
}
}
}
mark = 0;
int right = s.size() - 1;
for (int i = s.size() - 1; i >= 0; --i) {
int prev_mark = mark;
mark = max(0, mark + ((s[i] == ')') ? 1 : -1));
if (mark == 0) {
if (prev_mark > 0) {
res = max(right - i + 1, res);
} else {
right = i - 1;
}
}
}
return res;
}
int longestValidParentheses_dp(string s) {
int n = s.size();
int ans = 0;
vector<int> dp(n, 0);
for (int i = 1; i < n; ++i) {
if (s[i] == '(') {
dp[i] = 0;
} else {
int pre = i - 1 - dp[i - 1];
if (pre >= 0 && s[pre] == '(') {
if (pre > 0) {
dp[i] = dp[i - 1] + 2 + dp[pre - 1];
} else {
dp[i] = dp[i - 1] + 2;
}
}
}
}
for (int i = 0; i < n; ++i) {
ans = max(ans, dp[i]);
}
return ans;
}
};
int fun() {
string line;
while (getline(cin, line)) {
string s = stringToString(line);
int ret = Solution().longestValidParentheses_dp(s);
string out = to_string(ret);
cout << out << endl;
}
return 0;
} |
76c1da3324f6a20fb5bc544178e98a1f1a504bd6 | d1625162b37486d239c852107df3ee36a3ba2baa | /LV02_ZAD05.ino | 112073af091d68433433ac48481d07a628e5d2a7 | [] | no_license | 0mnitron/arduino | ed86c5d692cd7431db0d784c596428c7a4255337 | ce15efcef357eed67a06bdeb7ec0aeb0e33b0195 | refs/heads/master | 2023-04-28T14:49:18.812415 | 2021-05-17T11:36:48 | 2021-05-17T11:36:48 | 296,886,241 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 1,052 | ino | LV02_ZAD05.ino | int pin_SW1 = 8;
int pin_SW2 = 7;
int led1 = 2;
int led2 = 3;
int led3 = 4;
int led4 = 5;
int led5 = 6;
int button1 = 0;
int button2 = 0;
int nDelay = 200;
void setup() {
pinMode(led1, OUTPUT);
pinMode(led2, OUTPUT);
pinMode(led3, OUTPUT);
pinMode(led4, OUTPUT);
pinMode(led5, OUTPUT);
pinMode(pin_SW1, INPUT_PULLUP);
pinMode(pin_SW2, INPUT_PULLUP);
}
void loop() {
button1 = digitalRead(pin_SW1);
button2 = digitalRead(pin_SW2);
if(button1==0 || button2==0){
digitalWrite(led1, HIGH);
delay(nDelay);
digitalWrite(led1, LOW);
digitalWrite(led2, HIGH);
delay(nDelay);
digitalWrite(led2, LOW);
digitalWrite(led3, HIGH);
delay(nDelay);
digitalWrite(led3, LOW);
digitalWrite(led4, HIGH);
delay(nDelay);
digitalWrite(led4, LOW);
digitalWrite(led5, HIGH);
delay(nDelay);
digitalWrite(led5, LOW);
}
else{
digitalWrite(led1, LOW);
digitalWrite(led2, LOW);
digitalWrite(led3, LOW);
digitalWrite(led4, LOW);
digitalWrite(led5, LOW);
}
}
|
57592cc222667ced33a504b7c481d8b66d4a0fa2 | 3266d98067fa3da9f36b0854f49687604d2d142f | /hephaestus-lib/src/REND/RenderableInstance.h | aef7ad4fbfc3a8cae21df9f2a5a6febfcfe687d5 | [] | no_license | chrisschuette/HephaestusLibrary | f4457de92cc51b22689f19a41e0f40b78fa09063 | 869ab7a7347a34c701674abcb985d0c4ee1c2c0a | refs/heads/master | 2021-01-20T02:46:53.711954 | 2014-06-29T15:56:02 | 2014-06-29T15:56:02 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 679 | h | RenderableInstance.h | /*
* File: RenderableInstance.h
* Author: chris
*
* Created on June 2, 2014, 12:40 AM
*/
#ifndef RENDERABLEINSTANCE_H
#define RENDERABLEINSTANCE_H
#include <list>
namespace REND {
class Renderer;
class Renderable;
class UniformSetting;
class RenderableInstance {
public:
RenderableInstance(const Renderable& renderable);
virtual ~RenderableInstance();
void addUniformSetting(UniformSetting* uniformSetting);
virtual void draw(Renderer& renderer);
private:
const Renderable& m_renderable;
std::list<UniformSetting*> m_uniformSettings;
};
}
#endif /* RENDERABLEINSTANCE_H */
|
9293a12f5be4548f426866682e6a1b487d98af57 | 38dbe4904a67f33ffd95e4ba6ab0ef88bae6f8eb | /Creation,Insertion,Searching,Deletion,Traversing and replacing in Link list.CPP | 6edc6ee0dc6b6f9b520c772be5e661d4a433d9ec | [] | no_license | Shashank02051997/datastructureinc | 829a2d7af3aa5d698129c6e4df1ce8f2225be308 | bd1e85aed0223fc5fc750943f3eb4a4c31316147 | refs/heads/master | 2021-01-12T02:18:35.403400 | 2017-01-10T05:11:31 | 2017-01-10T05:11:31 | 78,498,585 | 2 | 2 | null | null | null | null | UTF-8 | C++ | false | false | 3,205 | cpp | Creation,Insertion,Searching,Deletion,Traversing and replacing in Link list.CPP | //Creation,Insertion,Searching,Deletion,Traversing and replacing in Link list
#include<stdio.h>
#include<conio.h>
#include<alloc.h>
struct node
{ int data;
struct node *next;
};
struct node *start=NULL;
void creation()
{ struct node *q,*t;
t=(struct node*)malloc(sizeof(struct node));
printf("Enter an element:");
scanf("%d",&t->data);
t->next=NULL;
if(start==NULL)
start=t;
else
q=start;
while(q->next!=NULL)
q=q->next;
q->next=t;
}
void insertion()
{ struct node *q,*t,*r;
int p,i;
t=(struct node*)malloc(sizeof(struct node));
printf("Enter an element:");
scanf("%d",&t->data);
printf("Enter the position:");
scanf("%d",&p);
t->next=NULL;
if(start==NULL)
{ printf("No insertion ,empty link list\n");
return;
}
q=start;
if(p==1)
{ t->next=q;
start=t;
printf("Element successfully insert\n");
}
if(p>1)
{ for(i=2;i<=p;i++)
{ r=q;
q=q->next;
}
t->next=q;
r->next=t;
printf("Element successfully insert\n");
}
}
void search()
{ struct node *q;
int item,p=0;
printf("Enter an element for search:");
scanf("%d",&item);
if(start==NULL)
{ printf("No element for search\n");
return;
}
q=start;
while(q->data!=item)
{ q=q->next;
p++;
if(q==NULL)
break;
}
if(q==NULL)
printf("Element not found\n");
else
printf("Element found at position %d\n",p+1);
}
void deletion()
{ struct node *q,*r;
int d;
printf("Enter element for delete:");
scanf("%d",&d);
if(start==NULL)
printf("Link is empty\n");
else
{ q=start;
while(q->data!=d)
{ r=q;
q=q->next;
}
if(q==NULL)
printf("Element not found");
else if(q==start)
{ start=q->next;
printf("Element successfully delete\n");
}
else
{ r->next=q->next;
printf("Element succesfully delete\n");
}
}
}
void replace()
{ struct node *q,*r,*t;
int item,p=1,i;
t=(struct node*)malloc(sizeof(struct node));
printf("Enter element:");
scanf("%d",&t->data);
t->next=NULL;
printf("Enter element for replace:");
scanf("%d",&item);
q=start;
while(q->data!=item)
{ q=q->next;
p++;
if(q==NULL)
break;
}
if(q==NULL)
printf("Element not found for such replacement\n");
else
{ q=start;
for(i=1;i<p;i++)
{ r=q;
q=q->next;
}
t->next=q->next;
r->next=t;
printf("Element successfully replace\n");
}
}
void traverse()
{ struct node *q;
if(start==NULL)
printf("Link is empty\n");
else
{ q=start;
while(q->next!=NULL)
{ printf("%d\t",q->data);
q=q->next;
}
printf("%d\n",q->data);
}
}
void main()
{ clrscr();
int x;
while(x!=7)
{ printf("Enter choice");
printf("\n1.Creation 2.Insertion 3.Searching 4.Delete 5.Replace 6.Traversing 7.Exit\n");
scanf("%d",&x);
switch(x)
{ case 1: creation();
break;
case 2: insertion();
break;
case 3: search();
break;
case 4: deletion();
break;
case 5: replace();
break;
case 6: traverse();
break;
case 7: break;
default: printf("Wrong choice\n");
break;
}
}
getch();
}
|
a15677e473f3230bac5f394ff3ebe8bd3ec0012b | 95ae6fa9cc64bc2f537753475c1b84ae526391b1 | /source/tm/ability.cpp | 25f002125a666c92b33c29f11f8198e3ad7e5879 | [
"BSL-1.0"
] | permissive | OctalMicrobe/technical-machine | 7deeb30cf1ff2eb730bc0ad9efc4794b30c6cf5c | bffa259bd4d069ce104efa21fef34a5342ee0755 | refs/heads/master | 2023-02-04T00:43:19.534781 | 2020-12-20T17:21:50 | 2020-12-20T17:21:50 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 1,757 | cpp | ability.cpp | // Copyright David Stone 2020.
// 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)
#include <tm/ability.hpp>
#include <tm/move/category.hpp>
#include <tm/move/move.hpp>
#include <tm/move/moves.hpp>
#include <tm/pokemon/active_pokemon.hpp>
#include <tm/type/type.hpp>
#include <tm/heal.hpp>
#include <tm/rational.hpp>
#include <tm/weather.hpp>
#include <containers/algorithms/all_any_none.hpp>
namespace technicalmachine {
auto blocks_intimidate(Generation const generation, Ability const ability) -> bool {
if (generation <= Generation::eight) {
return false;
}
switch (ability) {
case Ability::Inner_Focus:
case Ability::Oblivious:
case Ability::Scrappy:
case Ability::Own_Tempo:
return true;
default:
return false;
}
}
auto traceable(Generation const generation, Ability const ability) -> bool {
switch (ability) {
case Ability::Multitype:
case Ability::Illusion:
case Ability::Zen_Mode:
case Ability::Imposter:
case Ability::Stance_Change:
case Ability::Power_of_Alchemy:
case Ability::Receiver:
case Ability::Schooling:
case Ability::Comatose:
case Ability::Shields_Down:
case Ability::Disguise:
case Ability::RKS_System:
case Ability::Battle_Bond:
case Ability::Power_Construct:
case Ability::Gulp_Missile:
case Ability::Ice_Face:
case Ability::Neutralizing_Gas:
case Ability::Hunger_Switch:
return false;
case Ability::Trace:
return generation <= Generation::three;
case Ability::Forecast:
return generation <= Generation::three;
case Ability::Flower_Gift:
return generation <= Generation::four;
default:
return true;
}
}
} // namespace technicalmachine
|
2e41a03fe0a9d08fde31130965f86a8e2883f8b6 | 50a4352f6eb04e84dd2f65c35c0f0f7b349b7624 | /app/scenes/LevelScene.h | 12e427350228438317f4306372c15d45fb9da64f | [] | no_license | and3rson/campfire | 3aa04a2141bb9dd9a262f74bb6437371bfbd9161 | a49b764e696d9a4ed5d31cd46bf614a9e883ebe7 | refs/heads/master | 2021-01-10T13:48:41.356926 | 2015-11-01T18:21:28 | 2015-11-01T18:21:28 | 43,603,547 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 1,069 | h | LevelScene.h | #ifndef MAINMENUSCENE_H
#define MAINMENUSCENE_H
#include <SFML/Graphics.hpp>
#include <customtypes.h>
#include "../scenes/AScene.h"
#include "../world/Camera.h"
#include "world/Creature.h"
#include "world/Grid.h"
#include "world/Projectile.h"
class GameEngine;
class LevelScene : public AScene
{
public:
LevelScene(GameEngine *);
virtual void tick();
WorldObjectList walk(WorldObject *object);
protected:
void addObject(WorldObject *object);
// void removeObject(WorldObject *object);
void setControlledCreature(Creature *creature);
Creature *getControlledCreature();
void setActiveCamera(Camera *camera);
Camera *getActiveCamera();
private:
sf::Clock worldClock;
sf::Clock frameClock;
sf::RenderWindow *window;
WorldObjectList objects;
Creature *controlledCreature;
Camera *activeCamera;
int _dbgRandom()
{
#ifdef __linux__
return random() % 100 + 100;
#else
return rand() % 100 + 100;
#endif
}
sf::Font font;
};
#endif // MAINMENUSCENE_H
|
ecbae20296f2978743ca3836657761a48c9cd452 | 5ef0b4d230dc5243225d149efb44cdcdd2ffea9d | /trunk/cpp-tests/2420-content/control_flow/sum.cpp | 3a8c126996c242e4d88061ab5b190b5f19695943 | [] | no_license | kai-zhu/the-teaching-machine-and-webwriter | 3d3b3dfdecd61e0fb2146b44c42d6467489fd94f | 67adf8f41bb475108c285eb0894906cb0878849c | refs/heads/master | 2021-01-16T20:47:55.620437 | 2016-05-23T12:38:03 | 2016-05-23T12:38:12 | 61,149,759 | 1 | 0 | null | 2016-06-14T19:22:57 | 2016-06-14T19:22:57 | null | UTF-8 | C++ | false | false | 1,325 | cpp | sum.cpp | /*#HA*//******************************************************************
* Memorial University of Newfoundland
* Engineering 2420 Structured Programming
* sum.cpp -- Illustrate using while loops to sum some values.
*
*
* Author: Dennis Peters
*
*******************************************************************/
#include <iostream>
using namespace std;
/******************************************************************
* main -- sum values input by user
*
* Arguments: none
*
* Returns: 0
*******************************************************************/
/*#DA*/int main() {
double sum = 0.0; // Accumulator for sum of values
double val; // Value input by user
int num = 0; // Number of values to sum
int count = 0; // Number of values input so far
cout << "This program calculates the sum of the values entered.\n";
cout << "How many values will you sum:";
cin >> num;
while (count < num) {
cout << "Please enter a value: ";
cin >> val;
sum = sum + val;
count++;
}
cout << "The sum is: " << sum << endl;
return 0;
}
/*#HA*/
/******************************************************************
* Revision: 0
* Date:
*
*
* REVISION HISTORY
*
* Log
*
******************************************************************/
|
cfb4046d86cb39a1ff0da006b1623c0624aab817 | cfdab33825bb160dea64f0aab79b7206bf82e6d7 | /5704/5704.cc | 0bc80ecfc0ae7b06176d65771900d879954d5e85 | [] | no_license | wjdwithyou/BOJ | 299e0efaf3e5173addc55709fed5c19a458a0900 | a8ab50a14f2059905be4093b1f889c02f568126c | refs/heads/master | 2021-01-11T20:18:13.462615 | 2018-01-24T14:28:25 | 2018-01-24T14:28:25 | 81,535,224 | 0 | 1 | null | null | null | null | UTF-8 | C++ | false | false | 609 | cc | 5704.cc | #include <iostream>
#include <cstring>
int main() {
char buf[256];
int alpha[32];
int cnt;
while (true) {
memset(alpha, 0, sizeof(alpha));
cnt = 0;
fgets(buf, 256, stdin);
if (buf[0] == '*') {
break;
}
for (int i = 0; cnt < 26 && buf[i] != '\n'; ++i) {
if (buf[i] == ' ' || alpha[buf[i] - 'a']) {
continue;
}
++alpha[buf[i] - 'a'];
++cnt;
}
puts((cnt == 26) ? "Y" : "N");
}
return 0;
} |
4c589293708f55886220d5648ed029e6993a8a41 | b367fe5f0c2c50846b002b59472c50453e1629bc | /xbox_leak_may_2020/xbox trunk/xbox/private/atg/samples/cert/game/PhysicsSystem.cpp | 51178cd46e36600b7ab20a4a7483c4f04add8952 | [] | no_license | sgzwiz/xbox_leak_may_2020 | 11b441502a659c8da8a1aa199f89f6236dd59325 | fd00b4b3b2abb1ea6ef9ac64b755419741a3af00 | refs/heads/master | 2022-12-23T16:14:54.706755 | 2020-09-27T18:24:48 | 2020-09-27T18:24:48 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 33,849 | cpp | PhysicsSystem.cpp | //-----------------------------------------------------------------------------
// FILE: PhysicsSystem.cpp
//
// Desc: Physics system
//
// Hist: 04.10.01 - New for May XDK release
//
// Copyright (c) 1999-2000 Microsoft Corporation. All rights reserved.
//-----------------------------------------------------------------------------
#include <assert.h>
#include "PhysicsSystem.h"
#include "Polyhedron.h"
#include "HeightField.h"
#include "PerfTimer.h"
#include "Globals.h"
#include "Controller.h"
#pragma warning(disable: 4355)
//-----------------------------------------------------------------------------
// Constants
//-----------------------------------------------------------------------------
const DWORD MAX_PHYSICS_OBJECTS = 20; // arbitrary
PhysicsSystem::PhysicsSystem()
:
m_WorldObject( this )
{
// Initilize global overlap list.
OverlapsHead.pPrev = 0;
OverlapsHead.pNext = &OverlapsTail;
OverlapsTail.pPrev = &OverlapsHead;
OverlapsTail.pNext = 0;
pHeightField = 0;
}
//-----------------------------------------------------------------------------
// Name: ~PhysicsSystem()
// Desc: Destroy the system
//-----------------------------------------------------------------------------
PhysicsSystem::~PhysicsSystem()
{
Shutdown();
}
//-----------------------------------------------------------------------------
// Name: Shutdown()
// Desc: Shutdown the physics system
//-----------------------------------------------------------------------------
void PhysicsSystem::Shutdown()
{
// Bye bye static constraints
for( ConstraintList::iterator i = StaticConstraints.begin();
i != StaticConstraints.end(); ++i )
{
delete *i;
}
StaticConstraints.clear();
// Remove any objects left in the object list.
PhysObjList::iterator it = Objects.begin();
while (it != Objects.end())
{
RemoveObject((*it));
it = Objects.begin();
}
// Initilize global overlap list
OverlapsHead.pPrev = NULL;
OverlapsHead.pNext = &OverlapsTail;
OverlapsTail.pPrev = &OverlapsHead;
OverlapsTail.pNext = NULL;
// Make sure extent lists are empty.
ExtentsX.clear();
ExtentsY.clear();
ExtentsZ.clear();
// Nuke height field
delete pHeightField;
pHeightField = NULL;
}
FLOAT PhysicsSystem::Simulate(float start_time, float end_time)
{
static float fLeftOverTime = 0.0f;
float state0[13*32], state1[13*32], derivatives[13*32];
PhysObjList::iterator it;
TimeStamp start, end;
// Add in left over time.
start_time -= fLeftOverTime;
fLeftOverTime = 0.0f;
// Clamp timestep.
if (end_time > start_time+0.05f)
end_time = start_time+0.05f;
#if (0)
// Fixed time step for debugging.
end_time = start_time + 0.002f;
#endif
GetTimeStamp(&start);
FLOAT fRumble = 0.0f;
while (start_time < end_time)
{
float step = end_time - start_time;
if (step > fMaxTimeStep)
step = fMaxTimeStep;
if (step < fMinTimeStep)
{
fLeftOverTime = step;
break;
}
// Take half step.
ProcessCollisionsAndForces( start_time, fRumble );
float half_step = step*0.5f;
int offset = 0;
for (it = Objects.begin(); it != Objects.end(); ++it )
{
// Get state.
(*it)->GetState(state0+offset);
// Get derivatives.
(*it)->GetDerivatives(derivatives+offset);
int state_size = (*it)->StateSize();
// Take half step.
for (int i = offset; i < offset+state_size; i++)
state1[i] = state0[i] + half_step * derivatives[i];
// Set state.
(*it)->SetState(state1+offset);
offset += state_size;
}
bool bDiscontinous = ProcessCollisionsAndForces( start_time+half_step, fRumble );
if (bDiscontinous)
{
// Bail out of integrator.
start_time += half_step;
continue;
}
// Take full step with derivatives from midpoint.
offset = 0;
for (it = Objects.begin(); it != Objects.end(); ++it )
{
// Get derivatives at midpoint.
(*it)->GetDerivatives(derivatives+offset);
int state_size = (*it)->StateSize();
// Take half step.
for (int i = offset; i < offset+state_size; i++)
state1[i] = state0[i] + step * derivatives[i];
// Set state.
(*it)->SetState(state1+offset);
offset += state_size;
}
start_time += step;
}
GetTimeStamp(&end);
g_PhysicsTime += SecondsElapsed(start, end);
if( fRumble < 0.0f )
fRumble = 0.0f;
else if( fRumble > 1.0f )
fRumble = 1.0f;
return fRumble;
}
bool PhysicsSystem::ProcessCollisionsAndForces( float cur_time, FLOAT& fRumble )
{
float A[iMaxConstraints][iMaxConstraints];
float b[iMaxConstraints];
TimeStamp start, end;
PhysObjList::iterator it;
bool bAppliedImpulse = false;
g_DebugLines.clear();
Collisions.clear();
// Update object extents.
for (it = Objects.begin(); it != Objects.end(); ++it )
(*it)->UpdateExtents();
// Find any intersections.
SortExtentsAndUpdate(ExtentsX);
SortExtentsAndUpdate(ExtentsY);
SortExtentsAndUpdate(ExtentsZ);
static IntersectionInfo IntInfos[32];
for (OverlapRecord* pRec = OverlapsHead.pNext; pRec != &OverlapsTail; pRec = pRec->pNext)
{
PhysicsObject* pA = pRec->pA;
PhysicsObject* pB = pRec->pB;
// Check objects we overlap.
Transformation TransformA(pA->qR, pA->v3X);
Transformation TransformB(pB->qR, pB->v3X);
if (Polyhedron::CheckForIntersection(TransformA, *pA->pShape,
TransformB, *pB->pShape))
{
GetTimeStamp(&start);
int iNumInfos = 0;
Polyhedron::ComputeIntersectionInfo(TransformA, *pA->pShape,
TransformB, *pB->pShape,
&iNumInfos, IntInfos);
for (int i = 0; i < iNumInfos; i++)
{
if (IntInfos[i].bAtowardsB)
Collisions.push_back(CollisionRecord(pA, pB));
else
Collisions.push_back(CollisionRecord(pB, pA));
CollisionRecord& crec = Collisions.back();
crec.info = IntInfos[i];
#if (0)
// Add debug lines for intersection.
g_DebugLines.push_back(DebugLine());
DebugLine& line = g_DebugLines.back();
line.pos1 = crec.info.v3CenterOfIntersection;
line.color1 = 0x00ff0000;
line.pos2 = crec.info.v3CenterOfIntersection
+ crec.info.v3ExtractionDirection * 0.5f;
line.color2 = 0x0000ff00;
#endif
}
GetTimeStamp(&end);
g_CollisionTime += SecondsElapsed(start, end);
}
}
// Check against heightfield.
if (pHeightField)
{
for (it = Objects.begin(); it != Objects.end(); ++it )
{
// Skip static objects.
if ((*it)->fMass == 0.0f)
continue;
int iNumInfos = 0;
Transformation TransformA;
Transformation TransformB((*it)->qR, (*it)->v3X);
pHeightField->ComputeIntersectionInfo(TransformA, TransformB, *(*it)->pShape, &iNumInfos, IntInfos);
for (int i = 0; i < iNumInfos; i++)
{
if (IntInfos[i].bAtowardsB)
Collisions.push_back(CollisionRecord( GetWorldObject(), (*it)));
else
Collisions.push_back(CollisionRecord((*it), GetWorldObject() ));
CollisionRecord& crec = Collisions.back();
crec.info = IntInfos[i];
#if (0)
// Add debug lines for intersection.
g_DebugLines.push_back(DebugLine());
DebugLine& line = g_DebugLines.back();
line.pos1 = crec.info.v3CenterOfIntersection;
line.color1 = 0x00ff0000;
line.pos2 = crec.info.v3CenterOfIntersection
+ crec.info.v3ExtractionDirection * 0.5f;
line.color2 = 0x0000ff00;
#endif
}
}
}
// Setup active constraint list.
for (it = Objects.begin(); it != Objects.end(); ++it )
{
(*it)->AddConstraints(cur_time);
}
// Add static constraints to active list.
for (UINT i = 0; i < StaticConstraints.size(); i++)
{
const Constraint& sc = *StaticConstraints[i];
Constraint* dc = new Constraint(sc.pA, sc.pB);
dc->Type = sc.Type;
dc->v3Point = sc.v3Point * sc.pA->qR + sc.pA->v3X;
dc->v3Normal = sc.v3Normal * sc.pB->qR;
dc->fDist = sc.fDist - dc->v3Normal * sc.pB->v3X;
ActiveConstraints.push_back(dc);
}
// Compute A matrix for constraint solver.
ComputeAMatrix(ActiveConstraints, A);
// Resolve any collisions.
bool bCollisionsResolved = false;
while (!bCollisionsResolved)
{
bCollisionsResolved = true;
CollisionList::iterator cit;
for (cit = Collisions.begin(); cit != Collisions.end(); ++cit )
{
PhysicsObject* pA = (*cit).pA;
PhysicsObject* pB = (*cit).pB;
const Vector3& n = (*cit).info.v3ExtractionDirection;
const Vector3& p = (*cit).info.v3CenterOfIntersection;
Vector3 ra = p - pA->v3X;
Vector3 rb = p - pB->v3X;
Vector3 padot = pA->VelocityAtPoint(p);
Vector3 pbdot = pB->VelocityAtPoint(p);
float vrel = n * (padot - pbdot);
// Stop any velocity that will cause further penetration.
if (vrel < -0.1f)
{
float numerator = -(1.0f + 0.0f) * vrel;
float term3 = n * (((ra ^ n) * pA->m3InvI) ^ ra);
float term4 = n * (((rb ^ n) * pB->m3InvI) ^ rb);
float j = numerator / (pA->fInvMass + pB->fInvMass + term3 + term4);
Vector3 impulse = j * n;
assert(_finite(impulse.x) && _finite(impulse.y) && _finite(impulse.z));
pA->ApplyImpulse(p, impulse);
pB->ApplyImpulse(p, -impulse);
// We may have messed up another collision.
bCollisionsResolved = false;
bAppliedImpulse = true;
}
}
}
// Compute b vector (velocities) for constriants.
for (i = 0; i < ActiveConstraints.size(); i++)
{
Constraint& c = *ActiveConstraints[i];
Vector3 pa_dot = c.pA->VelocityAtPoint(c.v3Point);
Vector3 pb_dot = c.pB->VelocityAtPoint(c.v3Point);
b[i] = c.v3Normal * (pa_dot - pb_dot);
if (c.Type == Constraint::Bilateral)
{
// Return to correct position.
float error_dist = c.v3Normal * c.v3Point + c.fDist;
b[i] += 0.1f * error_dist;
}
}
// Solve for constraint impulses.
float constraint_impulses[iMaxConstraints];
ConstraintSolver(ActiveConstraints, A, b, constraint_impulses);
// Apply constraint impulses.
for (i = 0; i < ActiveConstraints.size(); i++)
{
Constraint& c = *ActiveConstraints[i];
c.pA->ApplyImpulse(c.v3Point, c.v3Normal * constraint_impulses[i]);
c.pB->ApplyImpulse(c.v3Point, c.v3Normal * -constraint_impulses[i]);
}
// Add external forces.
for (it = Objects.begin(); it != Objects.end(); ++it )
{
(*it)->v3Force.Zero();
(*it)->v3Torque.Zero();
(*it)->ComputeForceAndTorque(cur_time);
}
// Add non-penetration forces.
CollisionList::iterator cit;
for (cit = Collisions.begin(); cit != Collisions.end(); ++cit )
{
PhysicsObject* pA = (*cit).pA;
PhysicsObject* pB = (*cit).pB;
const Vector3& n = (*cit).info.v3ExtractionDirection;
const Vector3& p = (*cit).info.v3CenterOfIntersection;
// Add non-penetration force.
Vector3 padot = pA->VelocityAtPoint(p);
Vector3 pbdot = pB->VelocityAtPoint(p);
float vrel = n * (padot - pbdot);
Vector3 tvel = (padot - pbdot) - (n * vrel);
if (vrel < 0.0f) vrel = 0.0f;
float ks = 100.0f * (pA->fMass + pB->fMass);
float kd = 10.0f * (pA->fMass + pB->fMass);
Vector3 force = n * (ks * (*cit).info.fPenetrationDepth - kd * vrel);
if (tvel.GetLength() > 0.01f)
{
// Add friction force.
float mag = force.GetLength();
force -= tvel * mag * 0.2f;
}
assert(_finite(force.x) && _finite(force.y) && _finite(force.z));
pA->AddForce(p, force);
pB->AddForce(p, -force);
fRumble += force.GetLength();
}
// Compute b vector (accelerations) for constriants.
ComputeBVector(ActiveConstraints, b);
// Solve for constraint forces.
float constraint_forces[iMaxConstraints];
ConstraintSolver(ActiveConstraints, A, b, constraint_forces);
// Add constraint forces.
for (i = 0; i < ActiveConstraints.size(); i++)
{
Constraint& c = *ActiveConstraints[i];
c.pA->AddForce(c.v3Point, c.v3Normal * constraint_forces[i]);
c.pB->AddForce(c.v3Point, c.v3Normal * -constraint_forces[i]);
}
#if (0)
// Check to make sure accelerations were zeroed.
ComputeBVector(ActiveConstraints, b);
for (i = 0; i < ActiveConstraints.size(); i++)
{
switch (ActiveConstraints[i]->Type)
{
case Constraint::UnilateralVertFace:
case Constraint::UnilateralEdgeEdge:
assert(b[i] > -0.001f);
break;
case Constraint::StaticFriction:
assert(fabs(b[i]) < 0.001f || fabs(constraint_forces[i])+0.001f > ActiveConstraints[i]->fFrictionForce);
break;
case Constraint::Bilateral:
assert(fabs(b[i]) < 0.001f);
break;
}
}
#endif;
// Get rid of active constraints.
for (i = 0; i < ActiveConstraints.size(); i++)
delete ActiveConstraints[i];
ActiveConstraints.clear();
return bAppliedImpulse;
}
void PhysicsSystem::AddObject(PhysicsObject* pObj)
{
pObj->UpdateExtents();
// Add object extents.
InsertExtent(ExtentsX, &pObj->MinX);
InsertExtent(ExtentsX, &pObj->MaxX);
InsertExtent(ExtentsY, &pObj->MinY);
InsertExtent(ExtentsY, &pObj->MaxY);
InsertExtent(ExtentsZ, &pObj->MinZ);
InsertExtent(ExtentsZ, &pObj->MaxZ);
// Add overlaps.
for (PhysObjList::iterator it = Objects.begin(); it != Objects.end(); ++it )
{
PhysicsObject* pB = *it;
if (PhysicsObject::ExtentsOverlap(pObj, pB))
{
AddOverlap(pObj, pB);
}
}
// Add object to object list.
Objects.push_back(pObj);
assert( Objects.size() < MAX_PHYSICS_OBJECTS );
}
void PhysicsSystem::RemoveObject(PhysicsObject* pObj)
{
// Remove object from object list.
Objects.remove(pObj);
// Remove object extents.
RemoveExtent(ExtentsX, &pObj->MinX);
RemoveExtent(ExtentsX, &pObj->MaxX);
RemoveExtent(ExtentsY, &pObj->MinY);
RemoveExtent(ExtentsY, &pObj->MaxY);
RemoveExtent(ExtentsZ, &pObj->MinZ);
RemoveExtent(ExtentsZ, &pObj->MaxZ);
// Remove overlaps.
OverlapRecord* pRec = pObj->pOverlaps;
while (pRec)
{
RemoveOverlap(pRec->pA, pRec->pB);
pRec = pObj->pOverlaps;
}
}
void PhysicsSystem::AddHeightField(HeightField* pHF)
{
pHeightField = pHF;
}
void PhysicsSystem::AddPinJointConstraint(PhysicsObject* pA, PhysicsObject* pB, const Vector3& v3Point)
{
Vector3 pos_a = v3Point * ~Transformation(pA->qR, pA->v3X);
Vector3 pos_b = v3Point * ~Transformation(pB->qR, pB->v3X);
Constraint* c1 = new Constraint(pA, pB);
Constraint* c2 = new Constraint(pA, pB);
Constraint* c3 = new Constraint(pA, pB);
c1->Type = Constraint::Bilateral;
c1->v3Point = pos_a;
c1->v3Normal = Vector3(1.0f, 0.0f, 0.0f);
c1->fDist = -(c1->v3Normal * pos_b);
c2->Type = Constraint::Bilateral;
c2->v3Point = pos_a;
c2->v3Normal = Vector3(0.0f, 1.0f, 0.0f);
c2->fDist = -(c2->v3Normal * pos_b);
c3->Type = Constraint::Bilateral;
c3->v3Point = pos_a;
c3->v3Normal = Vector3(0.0f, 0.0f, 1.0f);
c3->fDist = -(c3->v3Normal * pos_b);
StaticConstraints.push_back(c1);
StaticConstraints.push_back(c2);
StaticConstraints.push_back(c3);
}
Constraint* PhysicsSystem::AddConstraint(PhysicsObject* pA, PhysicsObject* pB)
{
Constraint* c = new Constraint(pA, pB);
ActiveConstraints.push_back(c);
return c;
}
bool PhysicsSystem::CheckLineSegment(const Vector3& p1, const Vector3& p2, float* p_t, Vector3* p_q)
{
if (pHeightField)
{
return( pHeightField->CheckLineSegment(p1, p2, p_t, p_q) == TRUE );
}
else
{
// Check line (p1,p2).
Plane3 ground(0.0f, 1.0f, 0.0f, -0.5f);
float d1 = ground.GetDistance(p1);
float d2 = ground.GetDistance(p2);
if (d2 < 0.0f)
{
float t = d1 / (d1 - d2);
*p_q = (1.0f - t) * p1 + t * p2;
*p_t = t;
return true;
}
}
return false;
}
//-----------------------------------------------------------------------------
// Name: GetMaxStateSize()
// Desc: Returns the maximum state size of the physics system
//-----------------------------------------------------------------------------
DWORD PhysicsSystem::GetMaxStateSize() // static
{
return MAX_PHYSICS_OBJECTS * PhysicsObject::GetMaxStateSize();
}
int PhysicsSystem::GetStateSize()
{
// Return the total of the sizes of each object.
int state_size = 0;
PhysObjList::iterator it;
for (it = Objects.begin(); it != Objects.end(); ++it )
{
state_size += (*it)->StateSize();
}
return state_size;
}
void PhysicsSystem::GetState( FLOAT* pState )
{
assert( pState != NULL );
// Get the state of each object
PhysObjList::iterator it;
for (it = Objects.begin(); it != Objects.end(); ++it )
{
// Get state
(*it)->GetState( pState );
pState += (*it)->StateSize();
}
}
void PhysicsSystem::SetState( const FLOAT* pState )
{
assert( pState != NULL );
// Set the state of each object
PhysObjList::iterator it;
for (it = Objects.begin(); it != Objects.end(); ++it )
{
// Get state
(*it)->SetState( pState );
pState += (*it)->StateSize();
}
}
PhysicsObject* PhysicsSystem::GetWorldObject()
{
return &m_WorldObject;
}
void PhysicsSystem::AddOverlap(PhysicsObject* pA, PhysicsObject* pB)
{
// Check for duplicates.
OverlapRecord* pRec = pA->pOverlaps;
while (pRec)
{
if (pRec->pA == pA)
{
if (pRec->pB == pB)
return;
pRec = pRec->pNextA;
}
else // if (pRec->pB == pA)
{
if (pRec->pA == pB)
return;
pRec = pRec->pNextB;
}
}
// Allocate new record.
pRec = new OverlapRecord(pA, pB);
// Add to overlap list for pA.
pRec->pNextA = pA->pOverlaps;
pA->pOverlaps = pRec;
// Add to overlap list for pA.
pRec->pNextB = pB->pOverlaps;
pB->pOverlaps = pRec;
// Add to global overlap list.
OverlapsTail.pPrev->pNext = pRec;
pRec->pPrev = OverlapsTail.pPrev;
pRec->pNext = &OverlapsTail;
OverlapsTail.pPrev = pRec;
}
void PhysicsSystem::RemoveOverlap(PhysicsObject* pA, PhysicsObject* pB)
{
// Remove record from A's list.
OverlapRecord** pPrevPtr = &pA->pOverlaps;
OverlapRecord* pRec = pA->pOverlaps;
while (pRec)
{
if (pRec->pA == pA)
{
if (pRec->pB == pB)
{
*pPrevPtr = pRec->pNextA;
break;
}
pRec = pRec->pNextA;
}
else // if (pRec->pB == pA)
{
if (pRec->pA == pB)
{
*pPrevPtr = pRec->pNextB;
break;
}
pRec = pRec->pNextB;
}
}
// Remove record from B's list.
pPrevPtr = &pB->pOverlaps;
pRec = pB->pOverlaps;
while (pRec)
{
if (pRec->pA == pB)
{
if (pRec->pB == pA)
{
*pPrevPtr = pRec->pNextA;
break;
}
pRec = pRec->pNextA;
}
else // if (pRec->pB == pB)
{
if (pRec->pA == pA)
{
*pPrevPtr = pRec->pNextB;
break;
}
pRec = pRec->pNextB;
}
}
if (pRec)
{
// Remove from global overlap list.
pRec->pPrev->pNext = pRec->pNext;
pRec->pNext->pPrev = pRec->pPrev;
delete pRec;
}
}
void PhysicsSystem::InsertExtent(ExtentList& extents, PhysicsObject::Extent* extent)
{
int n = extents.size();
// Find where the extent goes and insert it.
int i;
for (i = 0; i < n; i++)
{
if (extent->Value < extents[i]->Value)
break;
}
// Make room.
extents.resize(n+1);
for (int j = n; j > i; j--)
{
extents[j] = extents[j-1];
}
extents[i] = extent;
}
void PhysicsSystem::RemoveExtent(ExtentList& extents, PhysicsObject::Extent* extent)
{
int n = extents.size();
// Find where the extent is and remove it.
int i;
for (i = 0; i < n; i++)
{
if (extents[i] == extent)
break;
}
assert(i < n);
// Make room.
for (int j = i; j < n-1; j++)
{
extents[j] = extents[j+1];
}
extents.resize(n-1);
}
void PhysicsSystem::SortExtentsAndUpdate(ExtentList& extents)
{
const int n = extents.size();
for (int step = 1; step < n; step++)
{
int i;
PhysicsObject::Extent* temp;
temp = extents[step];
for (i = step-1; i >= 0; i--)
{
if (extents[i]->Value > temp->Value)
{
// Make room.
extents[i+1] = extents[i];
// See if overlap status has changed.
if (temp->bStart ^ extents[i]->bStart)
{
// REVISIT: Should we save up a count of swaps to minimize checks?
if (PhysicsObject::ExtentsOverlap(temp->pObject, extents[i]->pObject))
{
// Add overlap.
AddOverlap(temp->pObject, extents[i]->pObject);
}
else
{
// Remove overlap.
RemoveOverlap(temp->pObject, extents[i]->pObject);
}
}
}
else
{
// Found place.
break;
}
}
// Insert value from Array[step].
extents[i+1] = temp;
}
}
void PhysicsSystem::ComputeAMatrix(const ConstraintList& Constraints, float matA[][iMaxConstraints])
{
const int iNumConstraints = Constraints.size();
for (int i = 0; i < iNumConstraints; i++)
{
const Constraint& ci = *Constraints[i];
for (int j = 0; j < iNumConstraints; j++)
{
const Constraint& cj = *Constraints[j];
// Check to see if constraints are distict.
if ((ci.pA != cj.pA) && (ci.pB != cj.pB) &&
(ci.pA != cj.pB) && (ci.pB != cj.pA))
{
matA[i][j] = 0.0f;
continue;
}
PhysicsObject* pA = ci.pA;
PhysicsObject* pB = ci.pB;
Vector3 ra = (ci.v3Point - pA->v3X);
Vector3 rb = (ci.v3Point - pB->v3X);
// What force and torque does constraint j exert on body A?
Vector3 force_on_a(0.0f, 0.0f, 0.0f);
Vector3 torque_on_a(0.0f, 0.0f, 0.0f);
if (cj.pA == ci.pA)
{
force_on_a = cj.v3Normal;
torque_on_a = (cj.v3Point - pA->v3X) ^ cj.v3Normal;
}
else if (cj.pB == ci.pA)
{
force_on_a = -cj.v3Normal;
torque_on_a = (cj.v3Point - pA->v3X) ^ -cj.v3Normal;
}
// What force and torque does constraint j exert on body B?
Vector3 force_on_b(0.0f, 0.0f, 0.0f);
Vector3 torque_on_b(0.0f, 0.0f, 0.0f);
if (cj.pA == ci.pB)
{
force_on_b = cj.v3Normal;
torque_on_b = (cj.v3Point - pB->v3X) ^ cj.v3Normal;
}
else if (cj.pB == ci.pB)
{
force_on_b = -cj.v3Normal;
torque_on_b = (cj.v3Point - pB->v3X) ^ -cj.v3Normal;
}
// Compute how the j'th contact force affects the linear and
// angular acceleration of the contact point on body A.
Vector3 a_linear = force_on_a * pA->fInvMass;
Vector3 a_angular = (torque_on_a * pA->m3InvI) ^ ra;
// Do the same for body B.
Vector3 b_linear = force_on_b * pB->fInvMass;
Vector3 b_angular = (torque_on_b * pB->m3InvI) ^ rb;
matA[i][j] = ci.v3Normal * ((a_linear + a_angular) - (b_linear + b_angular));
}
}
}
void PhysicsSystem::ComputeBVector(const ConstraintList& Constraints, float* vecB)
{
const int iNumConstraints = Constraints.size();
for (int i = 0; i < iNumConstraints; i++)
{
const Constraint& c = *Constraints[i];
PhysicsObject* pA = c.pA;
PhysicsObject* pB = c.pB;
Vector3 ra = (c.v3Point - pA->v3X);
Vector3 rb = (c.v3Point - pB->v3X);
// Compute the part of pa_dot_dot due to external force and torque.
Vector3 pa_dot_dot = pA->v3Force * pA->fInvMass +
((pA->v3Torque * pA->m3InvI) ^ ra);
// .. and similarly for pb_dot_dot.
Vector3 pb_dot_dot = pB->v3Force * pB->fInvMass +
((pB->v3Torque * pB->m3InvI) ^ rb);
// Compute the part of pa_dot_dot due to velocity
pa_dot_dot += (pA->v3Omega ^ (pA->v3Omega ^ ra)) +
(((pA->v3L ^ pA->v3Omega) * pA->m3InvI) ^ ra);
// .. and similarly for pb_dot_dot.
pb_dot_dot += (pB->v3Omega ^ (pB->v3Omega ^ rb)) +
(((pB->v3L ^ pB->v3Omega) * pB->m3InvI) ^ rb);
vecB[i] = c.v3Normal * (pa_dot_dot - pb_dot_dot);
Vector3 pa_dot = c.pA->VelocityAtPoint(c.v3Point);
Vector3 pb_dot = c.pB->VelocityAtPoint(c.v3Point);
switch(c.Type)
{
/*
case Constraint::Bilateral:
{
//Vector3 ndot = pB->v3Omega ^ c.v3Normal;
//vecB[i] += 2.0f * ndot * (pa_dot - pb_dot);
float error_dist = c.v3Normal * c.v3Point + c.fDist;
vecB[i] += 1.0f * error_dist + (c.v3Normal * (pa_dot - pb_dot) * 0.1f);
}
break;
*/
case Constraint::UnilateralVertFace:
{
Vector3 ndot = pB->v3Omega ^ c.v3Normal;
vecB[i] += 2.0f * ndot * (pa_dot - pb_dot);
}
break;
case Constraint::UnilateralEdgeEdge:
{
Vector3 eadot = pA->v3Omega ^ c.v3EdgeA;
Vector3 ebdot = pB->v3Omega ^ c.v3EdgeB;
Vector3 z = (eadot ^ c.v3EdgeB) + (c.v3EdgeA ^ ebdot);
Vector3 n = c.v3EdgeA ^ c.v3EdgeB;
float l = n.GetLength();
n /= l;
Vector3 ndot = (z - ((z * n) * n)) / l;
vecB[i] += 2.0f * ndot * (pa_dot - pb_dot);
}
break;
case Constraint::StaticFriction:
{
//Vector3 ndot = pB->v3Omega ^ c.v3Normal;
//vecB[i] += 2.0f * ndot * (pa_dot - pb_dot);
}
break;
}
}
}
//
// Solve a linear system of equations A * x = b
//
bool PhysicsSystem::SolveLinearSystem(float A[][iMaxConstraints], int n, float* b, float* x)
{
float p[iMaxConstraints];
// Cholesky decomposition.
for (int i = 0; i < n; i++)
{
for (int j = 0; j < n; j++)
{
float sum = A[i][j];
for (int k = i-1; k >= 0; k--)
sum -= A[i][k] * A[j][k];
if (i == j)
{
if (sum <= 0.0f)
return false;
p[i] = sqrtf(sum);
}
else
{
A[j][i] = sum / p[i];
}
}
}
// Backsubstitution.
for (i = 0; i < n; i++)
{
float sum = b[i];
for (int k = i-1; k >= 0; k--)
sum -= A[i][k] * x[k];
x[i] = sum / p[i];
}
for (i = n-1; i >= 0; i--)
{
float sum = x[i];
for (int k = i+1; k < n; k++)
sum -= A[k][i] * x[k];
x[i] = sum / p[i];
}
return true;
}
//
// Vector matrix multiplication (x = A * b)
//
void PhysicsSystem::MatVecMul(float A[][iMaxConstraints], int n, float* b, float* x)
{
for (int i = 0; i < n; i++)
{
float sum = 0.0f;
for (int j = 0; j < n; j++)
{
sum += A[i][j] * b[j];
}
x[i] = sum;
}
}
void PhysicsSystem::ConstraintSolver(const ConstraintList& Constraints, float A[][iMaxConstraints], float* b, float* f)
{
int i;
float A11[iMaxConstraints][iMaxConstraints]; // Subset of A matrix.
float a[iMaxConstraints]; // Current accelerations.
float delta_f[iMaxConstraints]; // Change in forces.
float delta_a[iMaxConstraints]; // Change in accelerations.
SolverSets ConstraintSet[iMaxConstraints]; // Current classification of each constraint.
int A11_index[iMaxConstraints]; // Indices used for build A11 matrix.
float v1[iMaxConstraints];
float x[iMaxConstraints];
int A11_size;
const int iNumConstraints = Constraints.size();
// C = NC = Cf = NC+ = NC- = empty
for (i = 0; i < iNumConstraints; i++)
ConstraintSet[i] = SetNone;
// f = 0
for (i = 0; i < iNumConstraints; i++)
f[i] = 0.0f;
// a = b
for (i = 0; i < iNumConstraints; i++)
a[i] = b[i];
//
// Solve for bilateral constraints and place them in C.
//
A11_size = 0;
for (i = 0; i < iNumConstraints; i++)
{
if (Constraints[i]->Type == Constraint::Bilateral)
{
ConstraintSet[i] = SetC;
A11_index[A11_size++] = i;
}
}
// A11 = A(CC)
for (i = 0; i < A11_size; i++)
for (int j = 0; j < A11_size; j++)
A11[i][j] = A[A11_index[i]][A11_index[j]];
// -v1 = -b
for (i = 0; i < A11_size; i++)
v1[i] = -b[A11_index[i]];
#if (0)
float Temp[iMaxConstraints][iMaxConstraints];
memcpy(Temp, A11, sizeof(A11));
#endif
// Solve A11*x = -v1
SolveLinearSystem(A11, A11_size, v1, x);
#if (0)
// Check solution.
float y[iMaxConstraints];
MatVecMul(Temp, A11_size, x, y);
for (i = 0; i < A11_size; i++)
assert(fabs(v1[i] - y[i]) < 0.001f);
#endif
// df = 0
for (i = 0; i < iNumConstraints; i++)
delta_f[i] = 0.0f;
// Transfer x into delta_f
for (i = 0; i < A11_size; i++)
delta_f[A11_index[i]] = x[i];
// delta_a = A * delta_f
MatVecMul(A, iNumConstraints, delta_f, delta_a);
// f = f + delta_f
for (i = 0; i < iNumConstraints; i++)
f[i] += delta_f[i];
// a = a + delta_a
for (i = 0; i < iNumConstraints; i++)
a[i] += delta_a[i];
//
// Now use Dantzig's algorithm for solving LCP's to solve for the unilateral
// and friction constraint forces.
//
for (int d = 0; d < iNumConstraints; d++)
{
// Scan for a constraint where the conditions are not met.
if (ConstraintSet[d] != SetNone)
continue;
if ((Constraints[d]->Type == Constraint::UnilateralVertFace ||
Constraints[d]->Type == Constraint::UnilateralVertFace) &&
a[d] > 0.0f)
{
// Go ahead and put this constraint in NC.
ConstraintSet[d] = SetNC;
continue;
}
if (Constraints[d]->Type == Constraint::StaticFriction && fabs(a[d]) < 1e-6f)
{
// Go ahead and put this constraint in Cf.
ConstraintSet[d] = SetCf;
continue;
}
L1:
//
// drive-to-zero(d)
//
//
// delta_f = fdirection(d)
//
for (i = 0; i < iNumConstraints; i++)
{
delta_f[i] = 0.0f;
}
if (a[d] < 0.0f)
delta_f[d] = 1.0f;
else
delta_f[d] = -1.0f;
// A11 = A(CC)
A11_size = 0;
for (i = 0; i < iNumConstraints; i++)
if (ConstraintSet[i] == SetC || ConstraintSet[i] == SetCf)
A11_index[A11_size++] = i;
for (i = 0; i < A11_size; i++)
for (int j = 0; j < A11_size; j++)
A11[i][j] = A[A11_index[i]][A11_index[j]];
// -v1 = -A(Cd)
for (i = 0; i < A11_size; i++)
v1[i] = -A[A11_index[i]][d] * delta_f[d];
#if (0)
float Temp[iMaxConstraints][iMaxConstraints];
memcpy(Temp, A11, sizeof(A11));
#endif
// Solve A11*x = -v1
SolveLinearSystem(A11, A11_size, v1, x);
#if (0)
// Check solution.
float y[iMaxConstraints];
MatVecMul(Temp, A11_size, x, y);
for (i = 0; i < A11_size; i++)
assert(fabs(v1[i] - y[i]) < 0.001f);
#endif
// Transfer x into delta_f
for (i = 0; i < A11_size; i++)
delta_f[A11_index[i]] = x[i];
// delta_a = A * delta_f
MatVecMul(A, iNumConstraints, delta_f, delta_a);
//
// (s,j) = maxstep(f,a,delta_f,delta_a,d)
//
float s = FLT_MAX;
int j = -1;
SolverSets NextSet = SetNone;
if (Constraints[d]->Type == Constraint::StaticFriction)
{
if (delta_a[d]*delta_f[d] > 0.0f)
{
// Either reduce a to zero ..
j = d;
s = -a[d] / delta_a[d];
NextSet = SetCf;
}
// .. or increase f to maximum.
if (delta_f[d] > 0.0f)
{
float s_prime = (Constraints[d]->fFrictionForce - f[d]) / delta_f[d];
if (s_prime < s)
{
j = d;
s = s_prime;
NextSet = SetNCfplus;
}
}
else if (delta_f[d] < 0.0f)
{
float s_prime = (-Constraints[d]->fFrictionForce - f[d]) / delta_f[d];
if (s_prime < s)
{
j = d;
s = s_prime;
NextSet = SetNCfminus;
}
}
}
else
{
assert(delta_a[d] > 0.0f);
// Step that will reduce accel to zero.
j = d;
s = -a[d] / delta_a[d];
NextSet = SetC;
}
for (i = 0; i < iNumConstraints; i++)
{
if (ConstraintSet[i] == SetC && Constraints[i]->Type != Constraint::Bilateral)
{
// Step that would reduce force to zero.
if (delta_f[i] < 0.0f)
{
float s_prime = -f[i] / delta_f[i];
if (s_prime < s)
{
j = i;
s = s_prime;
}
}
}
else if (ConstraintSet[i] == SetNC)
{
// Step that would reduce accel to zero.
if (delta_a[i] < 0.0f)
{
float s_prime = -a[i] / delta_a[i];
if (s_prime < s)
{
j = i;
s = s_prime;
}
}
}
else if (ConstraintSet[i] == SetCf)
{
// Step that would increase force to maximum.
if (delta_f[i] > 0.0f)
{
float s_prime = (Constraints[i]->fFrictionForce - f[i]) / delta_f[i];
if (s_prime < s)
{
j = i;
s = s_prime;
NextSet = SetNCfplus;
}
}
else if (delta_f[i] < 0.0f)
{
float s_prime = (-Constraints[i]->fFrictionForce - f[i]) / delta_f[i];
if (s_prime < s)
{
j = i;
s = s_prime;
NextSet = SetNCfminus;
}
}
}
else if (ConstraintSet[i] == SetNCfplus)
{
// Step that would reduce accel to zero.
if (delta_a[i] > 0.0f)
{
float s_prime = -a[i] / delta_a[i];
if (s_prime < s)
{
j = i;
s = s_prime;
}
}
}
else if (ConstraintSet[i] == SetNCfminus)
{
// Step that would reduce accel to zero.
if (delta_a[i] < 0.0f)
{
float s_prime = -a[i] / delta_a[i];
if (s_prime < s)
{
j = i;
s = s_prime;
}
}
}
}
assert(j != -1);
// f = f + s * delta_f
for (i = 0; i < iNumConstraints; i++)
f[i] += s * delta_f[i];
// a = a + s * delta_a
for (i = 0; i < iNumConstraints; i++)
a[i] += s * delta_a[i];
if (ConstraintSet[j] == SetC)
{
// Move to NC.
ConstraintSet[j] = SetNC;
goto L1;
}
else if (ConstraintSet[j] == SetNC)
{
// Move to C.
ConstraintSet[j] = SetC;
goto L1;
}
else if (ConstraintSet[j] == SetCf)
{
// Move to NCf+ or NCf- based on a.
ConstraintSet[j] = NextSet;
goto L1;
}
else if (ConstraintSet[j] == SetNCfplus)
{
// Move to Cf.
ConstraintSet[j] = SetCf;
goto L1;
}
else if (ConstraintSet[j] == SetNCfminus)
{
// Move to Cf.
ConstraintSet[j] = SetCf;
goto L1;
}
else
{
// Place in C, Cf, NCf+, or NCf-.
ConstraintSet[j] = NextSet;
}
}
}
const float PhysicsSystem::fMaxTimeStep = 0.02f;
const float PhysicsSystem::fMinTimeStep = 0.001f;
|
0fd2526d620846a67367cf6655fe6a38bdc4e566 | feb970ee041c281d9bce9658d72d72891e4a2a0d | /SmartFM/SmartFMV1/lib/Utils/logsplittype.cpp | a1f8291cc9cd6be267acccf33ab804e997d93eab | [] | no_license | yogeshiggalore/RandomLearning | e4a72644104d4787f68580a2ba79e1137ceb5ecf | d1b2b54076d6e601bbbadd4d1567720e58a0dabf | refs/heads/main | 2023-04-16T18:18:37.605826 | 2021-04-30T07:12:49 | 2021-04-30T07:12:49 | 308,560,973 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 633 | cpp | logsplittype.cpp | #include<string>
#include<logsplittype.h>
using namespace std;
LogSplitType LogSplitType::Parse(int code)
{
if(code == Monthly)
{
return Monthly;
}
else if(code == Hourly)
{
return Hourly;
}
return Daily;
}
string LogSplitType::ToString()
{
return this->GetLabel();
}
uint8 LogSplitType::GetCode()
{
return m_iCode;
}
string LogSplitType::GetLabel()
{
if (m_iCode == Daily)
{
return "Daily";
}
else if (m_iCode == Monthly)
{
return "Monthly";
}
else if (m_iCode == Hourly)
{
return "Hourly";
}
return "";
}
|
438e5a6530d6f7885f0a5203ae4a2c9d524d3832 | 43f42ce170085a5253d4a6f3f844cec648aa0904 | /Illumination/FileIO.h | 7b784e3247d3882b50876a5f27187c89d4865698 | [] | no_license | anjaldoshi/vk_forge | eb3148b0864102d05f02fcae5c65e45af9fc1f32 | 35606a510f9e7ac9d80aaa696a8bafdca4baa493 | refs/heads/master | 2020-04-07T18:12:12.162678 | 2018-11-21T21:24:58 | 2018-11-21T21:24:58 | 158,601,161 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 385 | h | FileIO.h | #pragma once
//STL
#include <string>
#include <vector>
#include "Vertex.h"
std::vector<char> readShaderFile(const std::string& filename);
void readObjFile(const std::string& filename, std::vector<Vertex>& vertices, std::vector<uint32_t>& indices, VkFrontFace frontFace);
//helper function for readObjFile
std::vector<std::string> getVertexDetails(const std::string& vertexString); |
270ed00ef597b655d81a9f3954c42ac03ec961d0 | b367fe5f0c2c50846b002b59472c50453e1629bc | /xbox_leak_may_2020/xbox trunk/xbox/private/atg/samples/template/template.cpp | fb9115d154e4189daf6be4f75de0298cd6e0ec17 | [] | no_license | sgzwiz/xbox_leak_may_2020 | 11b441502a659c8da8a1aa199f89f6236dd59325 | fd00b4b3b2abb1ea6ef9ac64b755419741a3af00 | refs/heads/master | 2022-12-23T16:14:54.706755 | 2020-09-27T18:24:48 | 2020-09-27T18:24:48 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 4,105 | cpp | template.cpp | //-----------------------------------------------------------------------------
// File: %%NAME%%.cpp
//
// Desc: [TODO: Describe source file here]
//
// Hist: %%DATE%% - Created
//
// Copyright (c) Microsoft Corporation. All rights reserved.
//-----------------------------------------------------------------------------
#include <XBApp.h>
#include <XBFont.h>
#include <XBHelp.h>
#include <xgraphics.h>
//-----------------------------------------------------------------------------
// Callouts for labelling the gamepad on the help screen
//-----------------------------------------------------------------------------
XBHELP_CALLOUT g_HelpCallouts[] =
{
{ XBHELP_BACK_BUTTON, XBHELP_PLACEMENT_2, L"Display help" },
};
#define NUM_HELP_CALLOUTS ( sizeof( g_HelpCallouts ) / sizeof( g_HelpCallouts[0] ) )
//-----------------------------------------------------------------------------
// Name: class CXBoxSample
// Desc: Main class to run this application. Most functionality is inherited
// from the CXBApplication base class.
//-----------------------------------------------------------------------------
class CXBoxSample : public CXBApplication
{
public:
CXBoxSample();
virtual HRESULT Initialize();
virtual HRESULT Render();
virtual HRESULT FrameMove();
CXBFont m_Font; // Font object
CXBHelp m_Help; // Help object
BOOL m_bDrawHelp; // TRUE to draw help screen
};
//-----------------------------------------------------------------------------
// Name: main()
// Desc: Entry point to the program.
//-----------------------------------------------------------------------------
VOID __cdecl main()
{
CXBoxSample xbApp;
if( FAILED( xbApp.Create() ) )
return;
xbApp.Run();
}
//-----------------------------------------------------------------------------
// Name: CXBoxSample (constructor)
// Desc: Constructor for CXBoxSample class
//-----------------------------------------------------------------------------
CXBoxSample::CXBoxSample()
:CXBApplication()
{
m_bDrawHelp = FALSE;
}
//-----------------------------------------------------------------------------
// Name: Initialize
// Desc: Peforms initialization
//-----------------------------------------------------------------------------
HRESULT CXBoxSample::Initialize()
{
// Create a font
if( FAILED( m_Font.Create( m_pd3dDevice, "Font.xpr" ) ) )
return XBAPPERR_MEDIANOTFOUND;
// Create help
if( FAILED( m_Help.Create( m_pd3dDevice, "Gamepad.xpr" ) ) )
return XBAPPERR_MEDIANOTFOUND;
return S_OK;
}
//-----------------------------------------------------------------------------
// Name: FrameMove
// Desc: Performs per-frame updates
//-----------------------------------------------------------------------------
HRESULT CXBoxSample::FrameMove()
{
// Toggle help
if( m_DefaultGamepad.wPressedButtons & XINPUT_GAMEPAD_BACK )
{
m_bDrawHelp = !m_bDrawHelp;
}
return S_OK;
}
//-----------------------------------------------------------------------------
// Name: Render
// Desc: Renders the scene
//-----------------------------------------------------------------------------
HRESULT CXBoxSample::Render()
{
// Clear the zbuffer
m_pd3dDevice->Clear( 0L, NULL, D3DCLEAR_ZBUFFER|D3DCLEAR_STENCIL,
0x00000000, 1.0f, 0L );
// Draw a gradient filled background
RenderGradientBackground( 0xff404040, 0xff404080 );
// Show title, frame rate, and help
if( m_bDrawHelp )
m_Help.Render( &m_Font, g_HelpCallouts, NUM_HELP_CALLOUTS );
else
{
m_Font.Begin();
m_Font.DrawText( 64, 50, 0xffffffff, L"%%NAME%%" );
m_Font.DrawText( 450, 50, 0xffffff00, m_strFrameRate );
m_Font.End();
}
// Present the scene
m_pd3dDevice->Present( NULL, NULL, NULL, NULL );
return S_OK;
}
|
f9a6586caed899e6c7810a960169f35b5d5d1aa0 | cea7712c53481bf7f25cf28f06ba432fab4af1bc | /Game/OceanSurface.h | ea20a725e425b7835ec1a4f5f5e24435ce481fe6 | [
"CC-BY-4.0"
] | permissive | Barrown1990/Floating-Sandbox | 09a31d4c7ecccecc8200bc198a734337c178744f | 4c67c93690ea867dd207a8d2283b6bd0d5299d48 | refs/heads/master | 2021-01-02T11:43:58.746831 | 2020-02-09T14:30:44 | 2020-02-09T14:30:44 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 7,773 | h | OceanSurface.h | /***************************************************************************************
* Original Author: Gabriele Giuseppini
* Created: 2018-04-14
* Copyright: Gabriele Giuseppini (https://github.com/GabrieleGiuseppini)
***************************************************************************************/
#pragma once
#include "GameEventDispatcher.h"
#include "GameParameters.h"
#include <GameCore/GameMath.h>
#include <GameCore/PrecalculatedFunction.h>
#include <GameCore/RunningAverage.h>
#include <memory>
#include <optional>
namespace Physics
{
class OceanSurface
{
public:
OceanSurface(std::shared_ptr<GameEventDispatcher> gameEventDispatcher);
void Update(
float currentSimulationTime,
Wind const & wind,
GameParameters const & gameParameters);
void Upload(
GameParameters const & gameParameters,
Render::RenderContext & renderContext) const;
public:
/*
* Assumption: x is in world boundaries.
*/
float GetHeightAt(float x) const noexcept
{
assert(x >= -GameParameters::HalfMaxWorldWidth && x <= GameParameters::HalfMaxWorldWidth);
//
// Find sample index and interpolate in-between that sample and the next
//
// Fractional index in the sample array
float const sampleIndexF = (x + GameParameters::HalfMaxWorldWidth) / Dx;
// Integral part
int64_t sampleIndexI = FastTruncateInt64(sampleIndexF);
// Fractional part within sample index and the next sample index
float sampleIndexDx = sampleIndexF - sampleIndexI;
assert(sampleIndexI >= 0 && sampleIndexI <= SamplesCount);
assert(sampleIndexDx >= 0.0f && sampleIndexDx <= 1.0f);
return mSamples[sampleIndexI].SampleValue
+ mSamples[sampleIndexI].SampleValuePlusOneMinusSampleValue * sampleIndexDx;
}
void AdjustTo(
std::optional<vec2f> const & worldCoordinates,
float currentSimulationTime);
void ApplyThanosSnap(
float leftFrontX,
float rightFrontX);
void TriggerTsunami(float currentSimulationTime);
void TriggerRogueWave(
float currentSimulationTime,
Wind const & wind);
public:
// The number of samples for the entire world width;
// a higher value means more resolution at the expense of Update() and of cache misses
static int64_t constexpr SamplesCount = 8192;
// The x step of the samples
static float constexpr Dx = GameParameters::MaxWorldWidth / static_cast<float>(SamplesCount);
private:
static int32_t ToSampleIndex(float x)
{
// Calculate sample index, minimizing error
float const sampleIndexF = (x + GameParameters::HalfMaxWorldWidth) / Dx;
int32_t sampleIndexI = FastTruncateInt32(sampleIndexF + 0.5f);
assert(sampleIndexI >= 0 && sampleIndexI <= SamplesCount);
return sampleIndexI;
}
void SetSWEWaveHeight(
int32_t centerIndex,
float height);
void RecalculateCoefficients(
Wind const & wind,
GameParameters const & gameParameters);
template<typename TDuration>
static GameWallClock::time_point CalculateNextAbnormalWaveTimestamp(
GameWallClock::time_point lastTimestamp,
TDuration rate);
void ApplyDampingBoundaryConditions();
void UpdateFields();
void GenerateSamples(
float currentSimulationTime,
Wind const & wind,
GameParameters const & gameParameters);
private:
std::shared_ptr<GameEventDispatcher> mGameEventHandler;
// What we store for each sample
struct Sample
{
float SampleValue; // Value of this sample
float SampleValuePlusOneMinusSampleValue; // Delta between next sample and this sample
};
// The samples (plus 1 to account for x==MaxWorldWidth)
std::unique_ptr<Sample[]> mSamples;
// Smoothing of wind incisiveness
RunningAverage<15> mWindIncisivenessRunningAverage;
//
// Calculated coefficients
//
// Calculated values
float mBasalWaveAmplitude1;
float mBasalWaveAmplitude2;
float mBasalWaveNumber1;
float mBasalWaveNumber2;
float mBasalWaveAngularVelocity1;
float mBasalWaveAngularVelocity2;
PrecalculatedFunction<SamplesCount> mBasalWaveSin1;
GameWallClock::time_point mNextTsunamiTimestamp;
GameWallClock::time_point mNextRogueWaveTimestamp;
// Parameters that the calculated values are current with
float mWindBaseAndStormSpeedMagnitude;
float mBasalWaveHeightAdjustment;
float mBasalWaveLengthAdjustment;
float mBasalWaveSpeedAdjustment;
std::chrono::minutes mTsunamiRate;
std::chrono::minutes mRogueWaveRate;
//
// Shallow water equations
//
// Height field
// - Height values are at the center of the staggered grid cells
std::unique_ptr<float[]> mHeightField;
// Velocity field
// - Velocity values are at the edges of the staggered grid cells
std::unique_ptr<float[]> mVelocityField;
private:
//
// Interactive waves
//
class SWEInteractiveWaveStateMachine
{
public:
SWEInteractiveWaveStateMachine(
int32_t centerIndex,
float lowHeight,
float highHeight,
float currentSimulationTime);
// Absolute coordinate, not sample coordinate
auto GetCenterIndex() const
{
return mCenterIndex;
}
void Restart(
float newTargetHeight,
float currentSimulationTime);
void Release(float currentSimulationTime);
/*
* Returns none when it may be retired.
*/
std::optional<float> Update(
float currentSimulationTime);
private:
float CalculateSmoothingDelay();
enum class WavePhaseType
{
Rise,
Fall
};
int32_t const mCenterIndex;
float const mLowHeight;
float mCurrentPhaseStartHeight;
float mCurrentPhaseTargetHeight;
float mCurrentHeight;
float mCurrentProgress; // Between 0 and 1, regardless of direction
float mStartSimulationTime;
WavePhaseType mCurrentWavePhase;
float mCurrentSmoothingDelay;
};
std::optional<SWEInteractiveWaveStateMachine> mSWEInteractiveWaveStateMachine;
//
// Abnormal waves
//
class SWEAbnormalWaveStateMachine
{
public:
SWEAbnormalWaveStateMachine(
int32_t centerIndex,
float lowHeight,
float highHeight,
float riseDelay, // sec
float fallDelay, // sec
float currentSimulationTime);
// Absolute coordinate, not sample coordinate
auto GetCenterIndex() const
{
return mCenterIndex;
}
/*
* Returns none when it may be retired.
*/
std::optional<float> Update(
float currentSimulationTime);
private:
enum class WavePhaseType
{
Rise,
Fall
};
int32_t const mCenterIndex;
float const mLowHeight;
float const mHighHeight;
float const mRiseDelay; // sec
float const mFallDelay; // sec
float mCurrentProgress; // Between 0 and 1, regardless of direction
float mCurrentPhaseStartSimulationTime;
float mCurrentPhaseDelay;
WavePhaseType mCurrentWavePhase;
};
std::optional<SWEAbnormalWaveStateMachine> mSWETsunamiWaveStateMachine;
std::optional<SWEAbnormalWaveStateMachine> mSWERogueWaveWaveStateMachine;
GameWallClock::time_point mLastTsunamiTimestamp;
GameWallClock::time_point mLastRogueWaveTimestamp;
};
}
|
920f1bf69a8f7d28b0d2287f2d2ec055da094aba | d0a3daad04d83c3266f92eb37ccbdcf2f6ce56af | /SampleProject/CommonHal/IUsbHidDevice.h | ba407901cbdac990d9ce2ac17d723882a78534c0 | [
"MIT"
] | permissive | Pursche/AvalonStudio | b51807f04d6b2d250ea8e9c13804fe19fef7e3ca | 424bdf30a59772d1a53c202eb5e04c32a3254bb4 | refs/heads/master | 2021-01-20T06:32:56.448625 | 2016-09-06T10:00:11 | 2016-09-06T10:00:11 | 67,428,410 | 0 | 0 | null | 2016-09-05T14:40:12 | 2016-09-05T14:40:11 | null | UTF-8 | C++ | false | false | 1,610 | h | IUsbHidDevice.h | /******************************************************************************
* Description:
*
* Author:
* Date: 27 April 2015
*
*******************************************************************************/
#pragma mark Compiler Pragmas
#ifndef _IUSBHIDDEVICE_H_
#define _IUSBHIDDEVICE_H_
#pragma mark Includes
#include <stddef.h>
#include <stdbool.h>
#include <stdint.h>
#include "CBuffer.h"
#include "Event.h"
#define LO_BYTE(x) ((uint8_t)(x & 0x00FF))
#define HI_BYTE(x) ((uint8_t)((x & 0xFF00) >> 8))
class UsbTransactionEventArgs : public EventArgs
{
public:
uint8_t reportId;
Buffer* data;
};
class IUsbHidDevice
{
#pragma mark Public Members
public:
virtual void Initialise (Buffer* deviceDescriptor, Buffer* configDescriptor,
Buffer* reportDescriptor,
Buffer* manufacturerString, Buffer* productString,
Buffer* serialString, uint8_t inEndpointAddress,
uint16_t inEndpointSize,
uint8_t outEndpointAddress,
uint16_t outEndpointSize) = 0;
virtual void WriteFeatureReport (uint8_t reportId, Buffer* buffer) = 0;
virtual Buffer* ReadFeatureReport (uint8_t reportId) = 0;
virtual void SendReport (Buffer* buffer) = 0;
virtual bool IsConnected () = 0;
virtual void InitialiseStack () = 0;
Event<UsbTransactionEventArgs> OnUsbOutput;
Event<UsbTransactionEventArgs> OnUsbInput;
#pragma mark Private Members
private:
};
#endif
|
b4db76fb391e27ed9468849143c14cabb4e0d050 | a9932499afdc4fe4fea8636f03fc3b178c7b36b8 | /ItemSnack.h | 51de3b9f7e6ca7637b81127b0883effd0469b1ac | [] | no_license | syashavanth/Vending-Machine | 868b0b11693644eb365ddc1ce4ee642888e5b0e2 | abd71957caf3ad839957dd87c1afd1ffd5a38b07 | refs/heads/master | 2020-03-16T23:50:29.513388 | 2018-07-29T02:54:13 | 2018-07-29T02:54:13 | 133,093,358 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 262 | h | ItemSnack.h |
#ifndef ITEMSNACK_H
#define ITEMSNACK_H
#include "Products.h"
class ItemSnack :public Products{
public:
ItemSnack(int = 1,float = 0.5f);
void printDetails();
virtual ~ItemSnack();
private:
};
#endif /* ITEMSNACK_H */
|
32374a8d57a48d6cf2ecfdc377f450d332625a00 | 4cdb2ea3869c5c63aa4f07acb5a36f06c5bd8dc8 | /src/lib/solution.cc | 8be8f347c0dce3e5f2b4b18b9b7aa732cf1b1f99 | [] | no_license | anujp10/EE_599_HW_2_1 | d45656ed80d5669205c09167bccb6a227344ab2b | 8322b195760714327042c3b08920f31af70e0f35 | refs/heads/master | 2020-12-26T22:15:59.988058 | 2020-02-01T20:09:45 | 2020-02-01T20:09:45 | 237,664,691 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 543 | cc | solution.cc | #include "solution.h"
int Solution::Add(int val1, int val2) {
int result;
result = val1 + val2;
return result;
}
std::string Solution::Add(std::string str1, std::string str2) {
std::string result;
if (str1.empty() || str2.empty())
return "Invalid input";
result = str1 + str2;
return result;
}
std::string Solution::Add(std::string str1, int val2) {
std::string result;
if (str1.empty())
return "Invalid input";
std::string str2 = std::to_string(val2);
result = str1 + str2;
return result;
} |
d6e7d11c5f90dd921f0acac52c30175e90b251fa | 2aa4c7c94866e7a958e4787dd4487aa7c1eb8d61 | /applications/ShallowWaterApplication/custom_utilities/shallow_water_variables_utility.h | 778d5d85299baeb9a9a00dc02dac9aadc849e471 | [
"BSD-3-Clause"
] | permissive | PFEM/Kratos | b48df91e6ef5a00edf125e6f5aa398505c9c2b96 | 796c8572e9fe3875562d77370fc60beeacca0eeb | refs/heads/master | 2021-10-16T04:33:47.591467 | 2019-02-04T14:22:06 | 2019-02-04T14:22:06 | 106,919,267 | 1 | 0 | null | 2017-10-14T10:34:43 | 2017-10-14T10:34:43 | null | UTF-8 | C++ | false | false | 12,060 | h | shallow_water_variables_utility.h | // | / |
// ' / __| _` | __| _ \ __|
// . \ | ( | | ( |\__ `
// _|\_\_| \__,_|\__|\___/ ____/
// Multi-Physics
//
// License: BSD License
// Kratos default license: kratos/license.txt
//
// Main authors: Miguel Maso Sotomayor
//
#if !defined(KRATOS_SHALLOW_WATER_VARIABLES_UTILITY_H_INCLUDED)
#define KRATOS_SHALLOW_WATER_VARIABLES_UTILITY_H_INCLUDED
// System includes
#include "includes/define.h"
#include "includes/model_part.h"
#include "utilities/openmp_utils.h"
#include "processes/find_nodal_neighbours_process.h"
// External includes
// Project includes
#include "shallow_water_application.h"
namespace Kratos
{
typedef std::size_t IndexType;
typedef std::vector<IndexType> IndexVectorType;
typedef std::map<int, Properties::Pointer> PropertiesMapType;
class ShallowWaterVariablesUtility
{
public:
KRATOS_CLASS_POINTER_DEFINITION(ShallowWaterVariablesUtility);
ShallowWaterVariablesUtility(ModelPart& rModelPart, const double& rDryHeight = 1e-3)
: mrModelPart(rModelPart)
{
KRATOS_TRY
std::cout << "Initializing shallow water variables utility" << std::endl;
mWaterHeightConvert = mrModelPart.GetProcessInfo()[WATER_HEIGHT_UNIT_CONVERTER];
mDryHeight = rDryHeight;
mZeroValue = 1e-8;
KRATOS_CATCH("")
}
~ShallowWaterVariablesUtility()
{}
/**
* This method computes the free surface elevation as HEIGHT + BATHYMETRY
*/
void ComputeFreeSurfaceElevation()
{
KRATOS_TRY
const int nnodes = static_cast<int>(mrModelPart.Nodes().size());
ModelPart::NodesContainerType::iterator nodes_begin = mrModelPart.NodesBegin();
#pragma omp parallel for
for(int i = 0; i < nnodes; i++)
{
auto node = nodes_begin + i;
node->FastGetSolutionStepValue(FREE_SURFACE_ELEVATION) = node->FastGetSolutionStepValue(HEIGHT) + (node->FastGetSolutionStepValue(BATHYMETRY) / mWaterHeightConvert);
}
KRATOS_CATCH("")
}
/**
* This method computes the water height as FREE_SURFACE_ELEVATION - BATHYMETRY
*/
void ComputeHeightFromFreeSurface()
{
KRATOS_TRY
const int nnodes = static_cast<int>(mrModelPart.Nodes().size());
ModelPart::NodesContainerType::iterator nodes_begin = mrModelPart.NodesBegin();
#pragma omp parallel for
for(int i = 0; i < nnodes; i++)
{
auto node = nodes_begin + i;
node->FastGetSolutionStepValue(HEIGHT) = node->FastGetSolutionStepValue(FREE_SURFACE_ELEVATION) - (node->FastGetSolutionStepValue(BATHYMETRY) / mWaterHeightConvert);
}
KRATOS_CATCH("")
}
/**
* This method computes the velocity as the MOMENTUM / HEIGHT
*/
void ComputeVelocity()
{
KRATOS_TRY
const int nnodes = static_cast<int>(mrModelPart.Nodes().size());
ModelPart::NodesContainerType::iterator nodes_begin = mrModelPart.NodesBegin();
#pragma omp parallel for
for(int i = 0; i < nnodes; i++)
{
auto node = nodes_begin + i;
node->GetSolutionStepValue(VELOCITY) = node->FastGetSolutionStepValue(MOMENTUM) / (node->FastGetSolutionStepValue(HEIGHT) * mWaterHeightConvert);
}
KRATOS_CATCH("")
}
/**
* This method computes the momentum as the VELOCITY * HEIGHT
*/
void ComputeMomentum()
{
KRATOS_TRY
const int nnodes = static_cast<int>(mrModelPart.Nodes().size());
ModelPart::NodesContainerType::iterator nodes_begin = mrModelPart.NodesBegin();
#pragma omp parallel for
for(int i = 0; i < nnodes; i++)
{
auto node = nodes_begin + i;
node->GetSolutionStepValue(MOMENTUM) = node->FastGetSolutionStepValue(VELOCITY) * (node->FastGetSolutionStepValue(HEIGHT) * mWaterHeightConvert);
}
KRATOS_CATCH("")
}
/**
* Set the dry nodes to zero
*/
void CheckDryConservedVariables()
{
KRATOS_TRY
const int nnodes = static_cast<int>(mrModelPart.Nodes().size());
ModelPart::NodesContainerType::iterator nodes_begin = mrModelPart.NodesBegin();
#pragma omp parallel for
for(int i = 0; i < nnodes; i++)
{
auto node = nodes_begin + i;
if (node->FastGetSolutionStepValue(HEIGHT) < mDryHeight &&
node->FastGetSolutionStepValue(RAIN) < mDryHeight )
{
node->FastGetSolutionStepValue(HEIGHT) = mZeroValue;
node->FastGetSolutionStepValue(MOMENTUM_X) = 0;
node->FastGetSolutionStepValue(MOMENTUM_Y) = 0;
}
}
KRATOS_CATCH("")
}
/**
* Set the dry nodes to zero
*/
void CheckDryPrimitiveVariables()
{
KRATOS_TRY
const int nnodes = static_cast<int>(mrModelPart.Nodes().size());
ModelPart::NodesContainerType::iterator nodes_begin = mrModelPart.NodesBegin();
#pragma omp parallel for
for(int i = 0; i < nnodes; i++)
{
auto node = nodes_begin + i;
if (node->FastGetSolutionStepValue(HEIGHT) < mDryHeight &&
node->FastGetSolutionStepValue(RAIN) < mDryHeight )
{
node->FastGetSolutionStepValue(HEIGHT) = mZeroValue;
node->FastGetSolutionStepValue(VELOCITY_X) = 0;
node->FastGetSolutionStepValue(VELOCITY_Y) = 0;
}
}
KRATOS_CATCH("")
}
/**
* This method looks for the dry elements and sets the proper flag
*/
void SetDryWetState()
{
KRATOS_TRY
// Getting the elements from the model
const int nelem = static_cast<int>(mrModelPart.Elements().size());
ModelPart::ElementsContainerType::iterator elem_begin = mrModelPart.ElementsBegin();
int nodes; // Number of element nodes
bool wet_node; // The nodal flag
// And now, if an element has all nodes dry, it is not active
#pragma omp parallel for
for(int k = 0; k < nelem; k++)
{
auto elem = elem_begin + k;
nodes = elem->GetGeometry().size();
wet_node = false;
for(int l = 0; l < nodes; l++)
{
if (elem->GetGeometry()[l].FastGetSolutionStepValue(HEIGHT) >= mDryHeight ||
elem->GetGeometry()[l].FastGetSolutionStepValue(RAIN) >= mDryHeight )
wet_node = true; // It means there is almost a wet node
}
if (wet_node)
{
elem->Set(FLUID, true);
elem->Set(ACTIVE, true);
}
else
{
elem->Set(FLUID, false);
elem->Set(ACTIVE, false);
}
}
KRATOS_CATCH("")
}
/**
* This method creates the dry properties as a copy of the wet properties
* The only difference between them is for visualization purpose
*/
void DefineDryProperties()
{
// Create a copy for each property
const int nprop = static_cast<int>(mrModelPart.NumberOfProperties());
ModelPart::PropertiesContainerType::iterator prop_begin = mrModelPart.PropertiesBegin();
IndexType last_id = 0;
IndexVectorType prop_id;
for (int i = 0; i < nprop; i++)
{
auto prop = prop_begin + i;
if (prop->Id() > last_id)
last_id = prop->Id();
prop_id.push_back(prop->Id());
}
for (auto id : prop_id)
{
// Get pointers to the properties and create the dry property
Properties::Pointer wet_prop = mrModelPart.pGetProperties(id); // This work around is inefficient. TODO: find another way
Properties::Pointer dry_prop(new Properties(*wet_prop));
dry_prop->SetId(++last_id);
// Add the new property and add them to the maps
mrModelPart.AddProperties(dry_prop);
mWetToDryPropertiesMap[wet_prop->Id()] = dry_prop;
mDryToWetPropertiesMap[dry_prop->Id()] = wet_prop;
}
}
/**
* This method assign the wet and dry properties
* Wet and dry are tween properties
* The only difference between them is for visualization purpose
* ExecuteBeforOutputStep
* @see DefineDryProperties
*/
void AssignDryWetProperties()
{
const int nelem = static_cast<int>(mrModelPart.Elements().size());
ModelPart::ElementsContainerType::iterator elem_begin = mrModelPart.ElementsBegin();
#pragma omp parallel for
for (int i = 0; i < nelem; i++)
{
auto elem = elem_begin + i;
if (elem->Is(FLUID))
{
auto search = mDryToWetPropertiesMap.find(elem->GetProperties().Id());
if (search != mDryToWetPropertiesMap.end()) // The element was dry
elem->SetProperties(search->second);
}
else
{
auto search = mWetToDryPropertiesMap.find(elem->GetProperties().Id());
if (search != mWetToDryPropertiesMap.end()) // The element was wet
{
elem->SetProperties(search->second);
}
}
}
}
/**
* This method sets the mesh position for visualization purpose
* ExecuteBeforeOutputStep
* @see ResetMeshPosition
*/
void SetMeshPosition()
{
// Move mesh to the current position
const int nodes = static_cast<int>(mrModelPart.Nodes().size());
ModelPart::NodesContainerType::iterator node_begin = mrModelPart.NodesBegin();
#pragma omp parallel for
for(int i = 0; i < nodes; i++)
{
auto node = node_begin + i;
if (node->FastGetSolutionStepValue(HEIGHT) <= mDryHeight)
{
double value = node->FastGetSolutionStepValue(BATHYMETRY);
node->Z() = value;
node->FastGetSolutionStepValue(DISPLACEMENT_Z) = value;
}
else
{
double value = node->FastGetSolutionStepValue(FREE_SURFACE_ELEVATION);
node->Z() = value;
node->FastGetSolutionStepValue(DISPLACEMENT_Z) = value;
}
}
}
/**
* This method resets the mesh to the original position (Z0 = 0)
* ExecuteAfterOutputStep
* @see SetMeshPosition
*/
void ResetMeshPosition()
{
// Move mesh to the original position
const int nodes = static_cast<int>(mrModelPart.Nodes().size());
ModelPart::NodesContainerType::iterator node_begin = mrModelPart.NodesBegin();
#pragma omp parallel for
for(int i = 0; i < nodes; i++)
{
auto node = node_begin + i;
node->Z() = node->Z0();
}
}
/**
* This method sets the all the elements active for visualization purpose
* ExecuteBeforeOutputStep
* @see AssignDryWetProperties
* @see SetDryWetState
*/
void SetElementsActive()
{
const int nelem = static_cast<int>(mrModelPart.Elements().size());
ModelPart::ElementsContainerType::iterator elem_begin = mrModelPart.ElementsBegin();
#pragma omp parallel for
for (int i = 0; i < nelem; i++)
{
auto elem = elem_begin + i;
elem->Set(ACTIVE, true);
}
}
protected:
private:
ModelPart& mrModelPart;
double mWaterHeightConvert;
double mDryHeight;
double mZeroValue;
PropertiesMapType mWetToDryPropertiesMap;
PropertiesMapType mDryToWetPropertiesMap;
}; // class ShallowWaterVariablesUtility
} // namespace Kratos
# endif // KRATOS_SHALLOW_WATER_VARIABLES_UTILITY_H_INCLUDED
|
a71b2b441d8c06e7476da88eb5e61d14326ec592 | 41f3c18ce759df5eb0d5a80fa4e8cf2883ecf98c | /lightoj/1190 - Sleepwalking.cpp | 7608e2d0ee7d2de1f092a545b5721931eb122177 | [] | no_license | tanvirtareq/programming | 6d9abafb844b1e80b7691157b0581a3b25b9cd59 | 040f636773df2d89fb7c169fe077f527f68140a4 | refs/heads/master | 2021-06-27T12:07:07.585682 | 2021-03-28T12:39:49 | 2021-03-28T12:39:49 | 217,275,688 | 1 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 2,817 | cpp | 1190 - Sleepwalking.cpp | #include<bits/stdc++.h>
#define ll long long
using namespace std;
ll n;
struct ii{
ll x, y;
ii operator - (ii a)
{
return {x-a.x, y-a.y};
}
};
ll cross(ii a, ii b)
{
return a.x*b.y-a.y*b.x;
}
ll dot(ii a, ii b)
{
return a.x*b.x+a.y*b.y;
}
ll distsq(ii a, ii b)
{
return dot(a-b, a-b);
}
ll intersect(ii a, ii b,ii c, ii d)
{
if(((cross(b-a, c-a)*cross(b-a, d-a))<0) and ((cross(d-c, b-c)*cross(d-c, a-c))<0)) return 1;
return 0;
}
int point_on_angle(ii a, ii b, ii c,ii p)
{
// return 0;
if(cross(c-b, p-b)*cross(a-b, p-b)<0) return 1;
return 0;
}
ll shoot(ii ar[], ii p, ii sh)
{
ll ct=0;
for(ll i=1;i<=n;i++)
{
ll j=i+1;
if(j>n) j=1;
// if((ar[i].y==p.y) and (p.x<=ar[i].x) and (ar[i].x<=sh.x)) ct+=2;
if((ar[i].y==p.y and ar[j].y!=p.y) and (p.x<=ar[i].x) and (ar[i].x<=sh.x))
{
ll k=i-1;
if(k<1) k=n;
if(point_on_angle(ar[k], ar[i], ar[j], p)) ct++;
else
ct+=2;
}
else if((ar[i].y==p.y and ar[j].y==p.y) and (p.x<=ar[i].x) and (ar[i].x<=sh.x))
{
while(ar[j].y==p.y)
{
j++;
if(j>n) j=1;
}
ll k=i-1;
if(k<1) k=n;
while(ar[k].y==p.y)
{
k--;
if(k<1) k=n;
}
if(point_on_angle(ar[k], ar[i], ar[j], p)) ct++;
}
else
{
if(intersect(ar[i], ar[j], p, sh)) ct++;
// cout<<ct<<endl;
}
}
// cout<<ct<<endl;
return ct;
}
ll eq(ii a, ii b)
{
return ((a.x==b.x) && (a.y==b.y));
}
ll onsegment(ii a, ii b, ii c)
{
if(eq(a, c) || eq(b, c)) return 1;
ll d=dot(b-a, c-a);
if(d<0) return 0;
if((cross(b-a, c-a)==0) and (distsq(a, c)<=distsq(b, a))) return 1;
return 0;
}
int main()
{
ll t;
cin>>t;
for(ll in=1; in<=t; in++)
{
cin>>n;
ii ar[n+10];
for(ll i=1; i<=n; i++)
cin>>ar[i].x>>ar[i].y;
ll q;
cout<<"Case "<<in<<":"<<endl;
cin>>q;
while(q--)
{
ii pt;
cin>>pt.x>>pt.y;
ii sh={10003, pt.y};
ll f=0;
for(ll i=1;i<=n;i++)
{
ll j=i+1;
if(j>n) j=1;
if(onsegment(ar[i], ar[j], pt)) f=1;
}
if(f) cout<<"Yes"<<endl;
else
{
ll ct=shoot(ar, pt, sh);
if(ct%2) cout<<"Yes"<<endl;
else cout<<"No"<<endl;
}
}
}
return 0;
}
|
a85c3c75cce669a7d454d5e2bec538864e4587a1 | 9f520bcbde8a70e14d5870fd9a88c0989a8fcd61 | /pitzDaily/109/pa | a808f16194ea40fc24be2274f46f7a8877fac2bd | [] | no_license | asAmrita/adjoinShapOptimization | 6d47c89fb14d090941da706bd7c39004f515cfea | 079cbec87529be37f81cca3ea8b28c50b9ceb8c5 | refs/heads/master | 2020-08-06T21:32:45.429939 | 2019-10-06T09:58:20 | 2019-10-06T09:58:20 | 213,144,901 | 1 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 104,792 | pa | /*--------------------------------*- C++ -*----------------------------------*\
| ========= | |
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
| \\ / O peration | Version: v1806 |
| \\ / A nd | Web: www.OpenFOAM.com |
| \\/ M anipulation | |
\*---------------------------------------------------------------------------*/
FoamFile
{
version 2.0;
format ascii;
class volScalarField;
location "109";
object pa;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
dimensions [0 2 -2 0 0 0 0];
internalField nonuniform List<scalar>
6400
(
-0.120695585305
-0.120697424573
-0.120702540191
-0.120712180441
-0.120725608752
-0.120742563571
-0.120763248599
-0.120788807781
-0.120819050325
-0.120853455356
-0.120897160007
-0.120952789183
-0.121016584405
-0.121088877275
-0.121171801799
-0.121267599184
-0.121376701056
-0.121498297558
-0.121631604389
-0.121772600573
-0.121914604513
-0.122056822054
-0.12220422055
-0.122363115501
-0.122538561023
-0.122730658696
-0.122935810882
-0.123151824267
-0.123379335333
-0.123620095877
-0.123875863131
-0.124145895479
-0.124423894741
-0.124703713897
-0.124984603838
-0.125261505991
-0.125531841081
-0.125807912799
-0.126089303358
-0.126359159844
-0.126618899633
-0.12689178906
-0.127190539472
-0.127504164428
-0.127823220502
-0.128142539608
-0.128457673406
-0.128767153836
-0.129069920663
-0.129365181999
-0.12965419298
-0.129928938729
-0.130182749993
-0.130404649445
-0.130597232916
-0.130778957635
-0.130945130491
-0.13107795321
-0.131174756516
-0.131246980869
-0.131300494571
-0.131336984287
-0.131358735331
-0.131369239129
-0.131374125948
-0.131369227425
-0.131350069824
-0.131318124022
-0.131279162429
-0.131237213913
-0.131193269471
-0.131146577129
-0.131096666509
-0.131046793657
-0.130997413799
-0.13095099097
-0.130909463384
-0.130880604667
-0.130861017943
-0.130852947547
-0.120692977354
-0.12069490419
-0.120699339758
-0.120708786859
-0.120723698148
-0.120742198953
-0.120763462957
-0.120787552146
-0.120816070784
-0.120850677148
-0.120894066523
-0.12094826579
-0.121012280461
-0.121085701674
-0.121169128579
-0.121263628229
-0.121372062494
-0.121494327904
-0.12162945805
-0.121772275151
-0.1219125766
-0.122052344438
-0.122198635791
-0.12235646679
-0.122531877292
-0.122725052065
-0.122930053573
-0.123146406386
-0.123374967364
-0.123616627353
-0.12387170512
-0.124141682786
-0.124421284576
-0.124700974924
-0.124982573417
-0.125259998246
-0.125529383808
-0.125806125971
-0.126088723373
-0.126356890677
-0.126607560738
-0.126875881375
-0.127184383842
-0.127504207484
-0.127825983048
-0.128148241931
-0.128465675513
-0.128777753212
-0.129081791585
-0.129373321327
-0.129654086434
-0.12992935202
-0.130200886231
-0.130426339445
-0.130619896947
-0.130809311428
-0.130969161497
-0.13109246582
-0.131187525868
-0.131258685469
-0.131308760286
-0.131346006744
-0.13136923902
-0.131379912429
-0.131385174455
-0.131380812726
-0.131361368191
-0.131327952534
-0.131287181587
-0.13124344984
-0.131197710134
-0.131149051626
-0.1310966028
-0.131043426227
-0.130992233009
-0.130944902899
-0.130904486135
-0.130874856789
-0.130855225625
-0.130848260547
-0.120685634948
-0.120688992643
-0.120692673606
-0.120701271799
-0.120715734885
-0.120736877795
-0.12076071656
-0.120784103811
-0.120810727499
-0.120844255737
-0.12088691974
-0.120940222864
-0.121004117456
-0.121077999892
-0.12116154576
-0.121252218218
-0.121358294842
-0.121488302499
-0.121627632949
-0.121769413629
-0.121905317146
-0.12203751277
-0.122180833433
-0.122341535517
-0.122517090463
-0.12270842051
-0.122914438079
-0.123132689858
-0.12336264036
-0.123605427034
-0.123860864913
-0.124131107005
-0.124414155403
-0.124692089347
-0.124970274064
-0.125252945383
-0.125520932343
-0.125792736147
-0.126076158641
-0.126347248366
-0.126608632906
-0.126883127761
-0.127183043044
-0.12749798129
-0.127818918145
-0.128141340578
-0.128461408327
-0.128776704053
-0.129084758165
-0.129383173108
-0.129671365312
-0.12994782418
-0.130206351304
-0.130437789445
-0.130651080889
-0.130841912804
-0.130995718899
-0.131116937412
-0.131210819505
-0.131281061782
-0.131332047772
-0.131368501431
-0.131389716291
-0.131402602281
-0.131410309533
-0.131406076397
-0.131385179488
-0.131349249622
-0.131304718693
-0.131256803439
-0.13120667393
-0.131153162616
-0.131096689262
-0.131040010109
-0.130985422545
-0.130935815569
-0.130894624367
-0.130863684487
-0.130843703686
-0.130836230333
-0.120676162704
-0.120679368391
-0.120681893782
-0.120689740228
-0.120702282
-0.120723103101
-0.120755325662
-0.120778526104
-0.120802892889
-0.120834479402
-0.120876053994
-0.120928754392
-0.120992669378
-0.121065637038
-0.121149295652
-0.121247253276
-0.121360105216
-0.121487580721
-0.121619667442
-0.121748015495
-0.121876689265
-0.122011892539
-0.122157003786
-0.122316602691
-0.12249246062
-0.122684892118
-0.122892676627
-0.123112929873
-0.12334503955
-0.123588977067
-0.123846792314
-0.124118225168
-0.12440146095
-0.124687363846
-0.124960134542
-0.125233838114
-0.125510060504
-0.125778809399
-0.126048941379
-0.126320882009
-0.126593584508
-0.126876464432
-0.127176860909
-0.127490946752
-0.127812499053
-0.128136853593
-0.128460161483
-0.128779547722
-0.129092414729
-0.129396423252
-0.129689705399
-0.129969700105
-0.130232242481
-0.130472792116
-0.130691100061
-0.130880698841
-0.131034902016
-0.131155913143
-0.131248723611
-0.131317885093
-0.131367832691
-0.131402393765
-0.131424525868
-0.131442203446
-0.131451584988
-0.131446638963
-0.131423374114
-0.131383022552
-0.131332247008
-0.131277548974
-0.131221180066
-0.131162192403
-0.131100309371
-0.13103631967
-0.13097413716
-0.130920711198
-0.1308780372
-0.130842493182
-0.130817647531
-0.130806883643
-0.120661338251
-0.120661461444
-0.120664684116
-0.120672640506
-0.120686574728
-0.120705969194
-0.12073430539
-0.120760754858
-0.1207871785
-0.120819488172
-0.120860362868
-0.120912726935
-0.120977083306
-0.121056086485
-0.121148540245
-0.121248345276
-0.121356310696
-0.121471397578
-0.121590663063
-0.121714813195
-0.121844442652
-0.12197953492
-0.122124609199
-0.122284587791
-0.122460973703
-0.122654756866
-0.12286392165
-0.1230867503
-0.123321198779
-0.123568362459
-0.123827642224
-0.124103981483
-0.124395315344
-0.12467317904
-0.124944841631
-0.125214190781
-0.125478492266
-0.12574538196
-0.126016665825
-0.126292255061
-0.12657250753
-0.126862019022
-0.127165077148
-0.127480449977
-0.127804036994
-0.128131566332
-0.128459208195
-0.128783821276
-0.129102739959
-0.129413533923
-0.129713786893
-0.130000525247
-0.130270094642
-0.130518622673
-0.130742190783
-0.130934063364
-0.131089714814
-0.13121131403
-0.131303862222
-0.131372157246
-0.131420814312
-0.131454175117
-0.131477476873
-0.131499302421
-0.131507136088
-0.131501703486
-0.131477115816
-0.131431923895
-0.131372781983
-0.131308492923
-0.131243395809
-0.131176009279
-0.13110343428
-0.131026999739
-0.130955795113
-0.130896086487
-0.130845183472
-0.130797604634
-0.130765914142
-0.130754052914
-0.120632943133
-0.120632194584
-0.120638727996
-0.120646469873
-0.120661636575
-0.120682973822
-0.12070822493
-0.120735438223
-0.120764602811
-0.120798444428
-0.120837884149
-0.120890984792
-0.12096437782
-0.121051219924
-0.121143458787
-0.121238294993
-0.121336904359
-0.121442425679
-0.121557288918
-0.121679680409
-0.121805799644
-0.121939104817
-0.122084433474
-0.122245447027
-0.122423007666
-0.122616856924
-0.122828855577
-0.123053858893
-0.123292243347
-0.123542120685
-0.123806875257
-0.124086065255
-0.124373794276
-0.124660542237
-0.124922455179
-0.125177318569
-0.12543703765
-0.125704215581
-0.125978147875
-0.1262581714
-0.126544708094
-0.12684037028
-0.127147668649
-0.1274662552
-0.127793367916
-0.128125312365
-0.128458389386
-0.128789401785
-0.12911569857
-0.129434857352
-0.129744231311
-0.1300405912
-0.130320005954
-0.13057771221
-0.130807868689
-0.131003980684
-0.1311629232
-0.131286886991
-0.131380329918
-0.13144795881
-0.131494803204
-0.131527365389
-0.131554414451
-0.131574402038
-0.131581316979
-0.131574629361
-0.131548167807
-0.131497948168
-0.131429105056
-0.131352536285
-0.131274994419
-0.131193336453
-0.131103554523
-0.131011937233
-0.130928695007
-0.130856586217
-0.130789146922
-0.130727071872
-0.130688453223
-0.130670762735
-0.12058884997
-0.120591872139
-0.120604060418
-0.120616030972
-0.120628091893
-0.120648997296
-0.120676183927
-0.120703858518
-0.120735237399
-0.120770769223
-0.120813710955
-0.120869066133
-0.120949718447
-0.121036686083
-0.121125116066
-0.121211922935
-0.121303532203
-0.121407096795
-0.121521284933
-0.121637483275
-0.121759375361
-0.121892202943
-0.122037517076
-0.122198216342
-0.12237646563
-0.122575021645
-0.122785874813
-0.123014853781
-0.123257066248
-0.1235151102
-0.123784437975
-0.124062361756
-0.124350733669
-0.124625365705
-0.124881398122
-0.12512972712
-0.125387706902
-0.125656367855
-0.125933531627
-0.126217949844
-0.126510120261
-0.126811754409
-0.127124304085
-0.127447604646
-0.12777964891
-0.128117252038
-0.128456947955
-0.128795677205
-0.129130958876
-0.129460466609
-0.129781429547
-0.13009022923
-0.130382153742
-0.130651207843
-0.130890449684
-0.131093744765
-0.131258713031
-0.131387130808
-0.131482436097
-0.131548450644
-0.131591769785
-0.131623352506
-0.131650016853
-0.131665795773
-0.131681332275
-0.131674119807
-0.131642440906
-0.131583906426
-0.13150343464
-0.131411757678
-0.13131598322
-0.131213065515
-0.131101486959
-0.13099143235
-0.130890180504
-0.13079661362
-0.130705967824
-0.130628776118
-0.130580392764
-0.130557070268
-0.120537757682
-0.120544011945
-0.120558675123
-0.120577388535
-0.120590772553
-0.120611262844
-0.120637410253
-0.120666148631
-0.120700510145
-0.120733686839
-0.120782734261
-0.12084903835
-0.120927613704
-0.121012173239
-0.12109354419
-0.121172525764
-0.121263151973
-0.121368464217
-0.12147692454
-0.121587298333
-0.12170581734
-0.121837906264
-0.121983462451
-0.122145862383
-0.122326257795
-0.122525627554
-0.122741648856
-0.122965885231
-0.123218124409
-0.123488641961
-0.123756616778
-0.124026001506
-0.124311528521
-0.124575994429
-0.12482244287
-0.12507223307
-0.125331526169
-0.12560189567
-0.125882101292
-0.126170827207
-0.126468379701
-0.126776014278
-0.127094588289
-0.127423820284
-0.127762057864
-0.128106526573
-0.128454089514
-0.128802008394
-0.129148107809
-0.12949022909
-0.129825489723
-0.130149763257
-0.130457331213
-0.130740928131
-0.130992871429
-0.131207234707
-0.131381656209
-0.131516597108
-0.131613186991
-0.131673800925
-0.13170893605
-0.131734616
-0.131757068223
-0.131777093988
-0.131797871172
-0.131801811015
-0.131766086694
-0.13169577691
-0.131599801962
-0.131487981587
-0.131367537997
-0.131237058731
-0.131099602719
-0.130964928156
-0.130836811119
-0.130712654653
-0.130596060842
-0.130500763284
-0.130442612349
-0.130413760613
-0.120482101687
-0.120490732225
-0.120505795006
-0.120520422949
-0.12053872368
-0.120565987661
-0.120590915743
-0.120620220093
-0.120659611095
-0.120696640478
-0.120742053516
-0.120815708588
-0.12089619786
-0.120975658337
-0.121050802753
-0.12112904633
-0.121218112562
-0.121320366182
-0.121423647881
-0.121530570612
-0.121646342653
-0.121775799238
-0.121919571069
-0.122081760604
-0.122271722532
-0.122469738952
-0.122690364977
-0.122924658602
-0.123175072126
-0.123442931103
-0.123716549933
-0.123995291154
-0.124254870188
-0.124506930299
-0.124754114262
-0.125006431479
-0.12526787249
-0.125540131696
-0.125823129276
-0.12611603414
-0.126418964902
-0.126732769388
-0.127057960325
-0.127394117796
-0.12773968632
-0.128092183118
-0.128448909815
-0.128807622069
-0.12916655136
-0.129523757892
-0.129876284184
-0.13021946239
-0.130546499107
-0.1308489203
-0.131118335491
-0.131348571851
-0.131536163532
-0.131678417512
-0.131772533937
-0.131819946727
-0.131841366882
-0.13186152468
-0.131884850118
-0.131908724741
-0.131929492776
-0.131947305559
-0.131927256284
-0.13184099178
-0.131724311695
-0.131586639782
-0.131433950756
-0.13126942569
-0.131100036721
-0.13093193405
-0.130766308007
-0.130604430958
-0.130458314435
-0.130341955338
-0.130267549514
-0.130233558966
-0.120421808369
-0.120432367883
-0.120449848341
-0.120464132909
-0.120483022119
-0.120510905282
-0.120536145409
-0.120565260921
-0.120602116415
-0.120652059453
-0.120700950374
-0.120773573272
-0.120854032816
-0.120928435798
-0.120997448171
-0.12107741527
-0.121169710239
-0.12126549711
-0.121362628792
-0.121466595711
-0.121581407293
-0.12170911818
-0.121851300634
-0.122009421159
-0.122205157717
-0.122412445546
-0.122621691605
-0.122866861819
-0.123120154905
-0.123393665999
-0.123666650185
-0.1239380302
-0.124191150663
-0.124431110434
-0.124677601975
-0.124932398069
-0.125196175705
-0.125470472909
-0.125756022229
-0.126052811773
-0.126361096054
-0.126681343318
-0.127013695706
-0.127357585185
-0.127711501967
-0.128073181887
-0.128440400785
-0.128811560511
-0.129185427401
-0.129560341773
-0.129933339279
-0.130299307139
-0.130650463035
-0.130977152073
-0.131270089211
-0.131521945639
-0.131725997039
-0.131873026185
-0.131953134638
-0.131974688809
-0.131984502589
-0.132006714022
-0.13203679799
-0.132065833438
-0.132088043014
-0.132101848323
-0.132092024004
-0.132030216415
-0.13188581395
-0.131713162432
-0.131520537535
-0.131315045496
-0.131104748196
-0.13089175517
-0.130677335676
-0.130470062802
-0.130285746176
-0.13013781225
-0.130037653899
-0.12998747983
-0.120353817953
-0.120364423298
-0.120382827826
-0.120401435474
-0.120426522244
-0.120448459582
-0.120473029171
-0.120503474713
-0.12053295444
-0.120587849093
-0.120647182122
-0.12071934247
-0.120799311129
-0.120871827142
-0.120938967734
-0.121017302385
-0.121110206698
-0.121201519967
-0.121293869089
-0.121393813723
-0.121507648669
-0.121635676217
-0.121781481747
-0.121937151946
-0.122121764029
-0.122345899601
-0.122562690594
-0.122803302691
-0.123055723424
-0.123312619927
-0.123596169798
-0.123864719407
-0.124109932757
-0.124345954487
-0.124592928462
-0.124849733836
-0.125115791772
-0.125392303232
-0.125680294258
-0.12598053025
-0.126293929946
-0.126620821022
-0.126960834178
-0.127313162839
-0.1276763243
-0.128048300388
-0.128427388378
-0.128812693273
-0.129203598381
-0.129598842938
-0.129995642044
-0.130388651631
-0.13076935132
-0.131127070758
-0.13145121711
-0.131731431834
-0.131953287893
-0.132090672071
-0.132132510237
-0.132128859207
-0.132140537007
-0.132176632786
-0.132220535044
-0.132258365213
-0.132280077861
-0.132280745991
-0.132259189906
-0.132215961637
-0.132090585138
-0.131881822173
-0.131638003828
-0.13138002452
-0.131116684806
-0.130844631994
-0.130567876195
-0.130302509114
-0.13006311545
-0.129864213459
-0.129718452225
-0.129642522689
-0.120277083876
-0.120285502086
-0.120298322234
-0.120322671745
-0.120356425969
-0.120376467373
-0.120400818601
-0.120434377002
-0.120462032502
-0.120512429864
-0.120579420486
-0.120652875052
-0.120731125346
-0.120803098956
-0.120874814414
-0.120953037381
-0.121042450343
-0.121129087517
-0.121217790463
-0.121313762308
-0.121423113389
-0.121547254099
-0.121701442004
-0.121869204382
-0.122043418913
-0.122264188483
-0.122489494373
-0.122719027446
-0.122986177104
-0.123247597585
-0.123514239261
-0.123767250895
-0.124007541469
-0.124249561548
-0.124498735962
-0.124757428027
-0.125025773237
-0.12530474327
-0.125595392354
-0.125898683136
-0.126216555598
-0.126550029697
-0.126898207686
-0.127259620058
-0.127632806429
-0.128016143459
-0.128408494047
-0.128809630947
-0.129219560868
-0.129637586096
-0.130061320779
-0.130485628678
-0.130902048727
-0.131299335672
-0.131664430925
-0.131979537883
-0.132208360649
-0.132303888449
-0.132297871113
-0.13228866798
-0.132320757786
-0.132385284246
-0.132451762452
-0.132503520061
-0.132523346328
-0.13250973667
-0.132465605421
-0.1324028297
-0.132300244028
-0.132093781551
-0.1318047023
-0.131474812967
-0.131142800911
-0.130793270602
-0.130433520579
-0.130090621443
-0.129770435861
-0.129493217069
-0.129287522125
-0.129174026368
-0.120190706061
-0.120196856461
-0.120201759294
-0.120229733542
-0.120262621366
-0.120288044372
-0.120314658789
-0.120351831761
-0.120384163172
-0.120431965291
-0.120501411398
-0.120574781478
-0.120650515344
-0.12071840412
-0.120795574448
-0.120880297591
-0.120965613215
-0.121048011688
-0.121133809791
-0.121227133244
-0.121331559583
-0.121447986216
-0.121597414947
-0.121787342772
-0.121966057575
-0.12216714928
-0.122405873085
-0.122638421078
-0.122887921029
-0.123153063705
-0.12341557766
-0.12366200341
-0.12389681146
-0.12414160413
-0.12439369024
-0.124654650347
-0.124925124865
-0.12520621174
-0.12549988034
-0.125806759232
-0.12612864045
-0.126467928106
-0.126824268607
-0.127195392435
-0.127579392403
-0.127975104377
-0.128382094138
-0.128800697196
-0.129231434726
-0.129674200694
-0.130127316181
-0.130586677466
-0.131045422842
-0.131492345485
-0.13191006437
-0.132259991111
-0.132468160108
-0.132486024305
-0.132454682653
-0.132464702969
-0.132541132711
-0.13265382947
-0.132752466856
-0.13282913502
-0.132845850651
-0.132808039193
-0.132728610579
-0.132627008087
-0.132525182659
-0.132342790926
-0.132026809865
-0.131610715321
-0.131194716045
-0.1307450807
-0.130268793033
-0.12982694825
-0.129391517282
-0.129002477881
-0.128707770659
-0.128544103505
-0.120096523308
-0.120103516178
-0.120113197247
-0.120130793349
-0.120158465251
-0.120186922525
-0.120216771488
-0.120254659378
-0.120295859361
-0.120342850302
-0.120413279434
-0.120486163077
-0.120559784636
-0.120624985831
-0.120699698753
-0.120790473132
-0.120876024858
-0.120956994734
-0.121040850685
-0.121132302598
-0.121233595198
-0.121343872055
-0.121485060887
-0.121682670859
-0.121876079032
-0.12206899529
-0.122308949007
-0.122547954985
-0.122785083641
-0.123044618941
-0.123291806704
-0.123530964964
-0.123772672811
-0.124021433282
-0.124276580168
-0.124539943173
-0.124813242806
-0.125096590475
-0.125392181941
-0.12570264413
-0.126029183445
-0.126373954084
-0.126737798033
-0.127118640112
-0.127514108821
-0.127923280464
-0.128346347522
-0.128783963949
-0.129236831053
-0.129705475404
-0.130188995243
-0.130685528342
-0.131192690217
-0.13170143012
-0.132184579138
-0.132549606287
-0.132694001444
-0.132632716733
-0.132610522478
-0.132671312942
-0.132825694225
-0.133015590259
-0.133150031123
-0.133290743407
-0.133258615187
-0.133148021994
-0.133001727628
-0.132839287567
-0.13269238556
-0.132553751536
-0.132387137759
-0.131777979063
-0.131276225394
-0.130698277743
-0.130062076345
-0.129518965129
-0.128917482996
-0.128359790336
-0.127923921407
-0.127661790081
-0.119990887187
-0.119998540178
-0.120016695259
-0.120025111973
-0.120046701775
-0.120075784183
-0.120107918678
-0.120148394659
-0.120200309137
-0.120245476338
-0.120315180233
-0.120387482974
-0.120460020308
-0.120525186038
-0.120598551464
-0.120690163375
-0.120775730151
-0.120856432727
-0.120939154962
-0.121028623541
-0.12112755883
-0.121235038588
-0.12136569388
-0.121554885849
-0.121771168497
-0.121968146191
-0.122189890543
-0.122447244988
-0.122691800578
-0.12292246463
-0.123156682009
-0.123392878249
-0.123636907177
-0.12388844957
-0.124146638738
-0.124412755211
-0.124688082475
-0.124974276659
-0.125272383501
-0.12558524498
-0.125916105623
-0.126266650778
-0.126637639531
-0.127027649702
-0.127434683399
-0.127858381523
-0.128299028865
-0.128757205516
-0.129233253048
-0.129727497733
-0.13023995747
-0.13077328931
-0.131332911685
-0.131913764415
-0.132467189015
-0.132798562483
-0.132771901524
-0.13272767686
-0.132765971997
-0.132932251687
-0.133207500363
-0.133531096201
-0.133550509961
-0.133485740827
-0.13341489831
-0.13329939335
-0.133135778122
-0.132944025126
-0.132732738023
-0.132469234311
-0.132144539787
-0.131975487228
-0.131643001744
-0.130914816148
-0.129785765393
-0.129186571657
-0.128337729343
-0.127512780635
-0.126826981694
-0.12637954274
-0.1198724057
-0.119879082087
-0.119894136419
-0.119904313095
-0.119922985083
-0.119953161283
-0.119986061646
-0.120024698264
-0.120086679927
-0.120137732192
-0.120206005129
-0.120278347541
-0.120350760698
-0.120418357708
-0.120491808554
-0.120581896247
-0.120666613602
-0.120747419962
-0.120829395613
-0.12091705147
-0.121013143436
-0.121118733738
-0.12124277936
-0.121420127211
-0.121646230211
-0.121857143011
-0.122063110724
-0.122306783979
-0.122560799373
-0.122791342902
-0.123015162622
-0.123246344529
-0.123490351369
-0.123743888955
-0.12400448621
-0.124272311607
-0.124549692922
-0.124837666142
-0.125138506824
-0.125453985427
-0.125788189171
-0.126144122381
-0.126522334387
-0.126920825341
-0.127338262267
-0.127776658857
-0.128237459621
-0.128719255624
-0.129218481796
-0.129734655094
-0.130272235901
-0.130838027416
-0.131446363461
-0.132110548656
-0.132764501788
-0.132891487888
-0.132809744342
-0.132783810234
-0.132968670814
-0.133313845618
-0.133625233688
-0.133564793339
-0.133470535523
-0.133353194298
-0.133161690937
-0.132870592802
-0.13250631196
-0.132124386833
-0.131758874824
-0.131393523475
-0.130966689479
-0.13028446572
-0.129529246649
-0.128848854068
-0.129068926401
-0.129360636072
-0.127958915982
-0.126386983223
-0.125265833489
-0.124427386424
-0.119742735336
-0.119748368153
-0.11976346276
-0.119772922139
-0.119790901302
-0.119820754379
-0.119853813132
-0.119888118972
-0.119949063859
-0.120011867608
-0.120083079425
-0.120156887685
-0.120230533499
-0.120303679638
-0.120377266914
-0.120465401484
-0.120549027301
-0.120630432534
-0.120711859635
-0.120797922174
-0.120891252484
-0.120993628738
-0.121112320104
-0.121277134055
-0.121496751071
-0.121731180977
-0.121938261157
-0.122162538757
-0.122403473703
-0.122629817598
-0.122849450947
-0.123083400905
-0.123329265157
-0.123584718277
-0.123848115197
-0.12411853351
-0.124397093667
-0.124686784527
-0.12498937611
-0.125307448045
-0.125644598088
-0.126004311489
-0.126388781696
-0.126795852301
-0.127223166369
-0.127676857235
-0.128160420093
-0.128667714723
-0.129187970001
-0.129722034136
-0.13027885503
-0.130868270193
-0.131503781341
-0.132200182094
-0.132906834352
-0.132914197945
-0.132862608739
-0.132944155424
-0.133338670888
-0.133337031033
-0.133268114644
-0.13316171017
-0.132833094673
-0.132298780048
-0.131592697795
-0.130728265962
-0.129761724086
-0.128776944785
-0.127841911858
-0.126969875707
-0.126118248491
-0.125262686807
-0.124589948296
-0.124201520034
-0.123929197219
-0.123935186135
-0.123843738305
-0.124556516631
-0.123364367107
-0.121493795724
-0.11960457291
-0.119608971611
-0.119619436594
-0.119629764502
-0.119651105874
-0.119680210401
-0.119714422154
-0.119746521465
-0.119804718261
-0.119873517862
-0.119947018966
-0.120021519985
-0.120094845471
-0.120175527629
-0.120252246496
-0.120338180372
-0.120421147023
-0.120504525645
-0.120585898539
-0.120670707161
-0.120761504793
-0.120860033588
-0.120973504589
-0.121127435746
-0.121337616091
-0.121582413971
-0.121805215239
-0.122018697875
-0.122240362536
-0.122454989155
-0.122670721322
-0.122904625347
-0.12315073716
-0.123407535764
-0.123673711211
-0.123947407174
-0.124228992769
-0.124520020593
-0.124824580221
-0.125144309579
-0.125483254097
-0.125846908084
-0.126237127712
-0.126651788945
-0.127082368626
-0.127540785136
-0.128049705672
-0.12859872881
-0.129145142559
-0.129689838621
-0.130257462637
-0.130855199923
-0.131491792723
-0.132177266716
-0.132990368134
-0.133041223874
-0.133060839637
-0.133046279842
-0.132923662876
-0.132752216863
-0.132412447411
-0.131840861212
-0.130903168674
-0.129625578173
-0.128083176351
-0.126349997241
-0.124507324658
-0.122645998787
-0.120834401149
-0.119096342313
-0.117441788087
-0.115909788704
-0.114633782508
-0.113825932884
-0.113818125591
-0.114967110672
-0.116681517891
-0.117659612797
-0.117944076373
-0.11625643911
-0.119459298032
-0.119462518459
-0.119468438322
-0.11947998771
-0.119504382569
-0.119531966992
-0.119566675866
-0.119600670056
-0.119653602284
-0.119724601767
-0.119798613458
-0.119872888513
-0.119943799526
-0.120025739392
-0.120111170574
-0.120197216081
-0.120279773589
-0.120365433766
-0.120449126277
-0.120533825504
-0.120623081196
-0.120717097882
-0.120825193487
-0.120968895981
-0.121164606906
-0.121399616766
-0.121638587647
-0.1218542648
-0.12206530941
-0.122272061905
-0.12247949231
-0.12271024917
-0.122957160455
-0.123210876096
-0.123479895043
-0.123757128639
-0.124040465441
-0.124334140592
-0.124641443573
-0.124964744629
-0.12530550979
-0.125669828394
-0.126062147209
-0.126484370494
-0.126933279119
-0.127412488048
-0.127937232084
-0.128490833327
-0.129052067428
-0.129621832232
-0.130207410691
-0.130810844289
-0.131425078266
-0.132079413606
-0.132726240385
-0.133509149861
-0.133177571253
-0.132576024292
-0.13206911019
-0.131448515112
-0.130495160396
-0.129085123392
-0.127241154301
-0.12505029401
-0.122612345582
-0.120037102941
-0.117425468674
-0.114860897649
-0.112380692731
-0.109967197861
-0.107603811034
-0.105356661358
-0.103214562079
-0.101353270019
-0.100319595007
-0.100781725054
-0.102673006777
-0.104586904905
-0.107444019037
-0.121332615431
-0.119308278795
-0.11931115978
-0.119314915764
-0.119329152712
-0.119352637513
-0.11937729915
-0.119408242065
-0.119446459857
-0.119493901601
-0.119564585947
-0.119638535171
-0.119712141836
-0.11978198605
-0.119860894108
-0.119952960744
-0.120041814614
-0.120125306904
-0.12021157531
-0.120297996515
-0.120384617197
-0.120474472961
-0.120564298495
-0.120666628871
-0.120801092651
-0.120982197229
-0.121203192622
-0.121440852735
-0.121662723241
-0.121861282012
-0.122059832994
-0.122268427922
-0.122490327767
-0.122734682504
-0.122990634395
-0.12326354819
-0.12354441802
-0.123829793169
-0.124126109843
-0.124436408125
-0.124763351941
-0.125108267889
-0.125475207956
-0.125875364442
-0.126316041512
-0.126793245489
-0.127289572269
-0.127814697765
-0.128372114804
-0.128957519016
-0.129570267659
-0.13019660172
-0.130802906238
-0.13131400005
-0.13184345284
-0.132000259897
-0.133555584441
-0.132630080211
-0.131412973309
-0.130356659002
-0.128937411619
-0.12705773189
-0.124676805033
-0.121906743635
-0.118878555918
-0.115710888221
-0.112503633085
-0.109323896237
-0.106194538698
-0.103082604902
-0.0999124279975
-0.0966159660875
-0.0932249126579
-0.0897819906666
-0.0863174197339
-0.0832312739822
-0.0811973673213
-0.0804183792496
-0.0786082427148
-0.0698476397893
-0.0528434077284
-0.119148458437
-0.119151073457
-0.119155214475
-0.119173395834
-0.119195290514
-0.119216549926
-0.119242061849
-0.119282790496
-0.119323488612
-0.119392527972
-0.119466313241
-0.119539652572
-0.119609166966
-0.119687066044
-0.119781054514
-0.119872679129
-0.1199582163
-0.120045414616
-0.120132376143
-0.120220796937
-0.120313058958
-0.120400326121
-0.120495799923
-0.120621747859
-0.120789260558
-0.120994920239
-0.121225998077
-0.121448250679
-0.121652958082
-0.121838327862
-0.122042766624
-0.12226166723
-0.122496558439
-0.122741043464
-0.123011620415
-0.123302782395
-0.123594047934
-0.123895357158
-0.124207822155
-0.12453726911
-0.124887999749
-0.125263269337
-0.125678951871
-0.126147744572
-0.126643916651
-0.127150873309
-0.127686706782
-0.12827661856
-0.128932455505
-0.129627178695
-0.13033142059
-0.13091669383
-0.131282775243
-0.132247322918
-0.131334221588
-0.130340865516
-0.129843605861
-0.128775624978
-0.127177082174
-0.124883814244
-0.122060094358
-0.118772796098
-0.115179990966
-0.111404887578
-0.107538474467
-0.10362485359
-0.0996650924916
-0.0956229591864
-0.0914311905724
-0.087014988525
-0.0823179720162
-0.077323489127
-0.0720644782232
-0.0664347077576
-0.060491591711
-0.0546940750955
-0.0484415614779
-0.0362454168528
-0.00711551134371
0.0303823843335
-0.11897641547
-0.118978627897
-0.11898406167
-0.119007315266
-0.119027714423
-0.119046346301
-0.119068769349
-0.119108287125
-0.119142387329
-0.119207860241
-0.119281514384
-0.119354240573
-0.119423770818
-0.11950062474
-0.119594418917
-0.119688127903
-0.119777593587
-0.119865746484
-0.119951976575
-0.120041051932
-0.120135807881
-0.120222766414
-0.120310334935
-0.120427742137
-0.120583209909
-0.120772475152
-0.120990780001
-0.121200992824
-0.12141245738
-0.121602611494
-0.121795992239
-0.122002514802
-0.122235445502
-0.122484024224
-0.122739346342
-0.123026474076
-0.123325716285
-0.123633155042
-0.123953332199
-0.124286637192
-0.124640873968
-0.125030935927
-0.125474533696
-0.125967253469
-0.126471111241
-0.126989420608
-0.127564432153
-0.128238050367
-0.129011584037
-0.129811053204
-0.130614837456
-0.131259427119
-0.130967051908
-0.130371272
-0.129432160521
-0.12803223317
-0.126814913536
-0.12508673431
-0.122649228684
-0.119470049136
-0.115754956574
-0.111631722421
-0.10726614064
-0.10275440608
-0.0981545845068
-0.093479618612
-0.0887122390099
-0.0838133356362
-0.0787257556949
-0.0733754345051
-0.0676652364968
-0.0614406185861
-0.0545066793096
-0.0467201808618
-0.0379733534349
-0.0283014912093
-0.0158493788829
0.00769215291065
0.0540516558476
0.106323092612
-0.11878441806
-0.118786380175
-0.11879363274
-0.118821486401
-0.1188400502
-0.118859201476
-0.118879912586
-0.11891545555
-0.11894554715
-0.119009385651
-0.119083021801
-0.119155313383
-0.11922441908
-0.119299753492
-0.119391725372
-0.119485226854
-0.119580033478
-0.119669886481
-0.119755221864
-0.119843844195
-0.119939039626
-0.120028790195
-0.120109114909
-0.120216599971
-0.120361631442
-0.120535422987
-0.120738282334
-0.120933469356
-0.121132053334
-0.121332923939
-0.121531683253
-0.121729049677
-0.121938470314
-0.122181560777
-0.122445147128
-0.122725086389
-0.123025476374
-0.123336347977
-0.123661933845
-0.124003326231
-0.124368985745
-0.124778699846
-0.125249473255
-0.12575324165
-0.126270122919
-0.126824387982
-0.127471186571
-0.128254218488
-0.129131322039
-0.129860586269
-0.13059700889
-0.130372110162
-0.129586316771
-0.128447188209
-0.127266417655
-0.12560825857
-0.123539171481
-0.120737486651
-0.117233270994
-0.113095779221
-0.108517028531
-0.103636237811
-0.0985998256092
-0.093484552622
-0.0883332704682
-0.083149630643
-0.0779079104017
-0.0725498976621
-0.0669842893605
-0.0610792109291
-0.0546460257002
-0.0473976658269
-0.0389528603731
-0.0290984679615
-0.0179679288306
-0.00528871857529
0.0119566133467
0.0427848398596
0.0957042851229
0.147346107672
-0.118568506646
-0.118572036595
-0.118579237545
-0.118605513953
-0.118625709599
-0.118650019972
-0.118672491512
-0.118705880575
-0.118739166046
-0.118796955303
-0.118870051694
-0.118941485698
-0.119010355635
-0.119083784738
-0.119172535322
-0.119262527296
-0.119358008906
-0.11945236002
-0.119539548261
-0.119628202159
-0.119720990006
-0.119815151692
-0.119897345939
-0.119988467083
-0.120123891439
-0.12028383391
-0.120470264612
-0.120651535258
-0.120832889886
-0.121031039522
-0.121235831795
-0.12144152036
-0.121636923173
-0.121856270907
-0.122109565596
-0.122390488269
-0.122692072996
-0.123007961418
-0.123334657732
-0.123683829789
-0.124065676632
-0.124499719717
-0.124985001154
-0.125498920906
-0.126043655632
-0.126657496595
-0.127386151621
-0.128164535219
-0.128921735309
-0.129773346829
-0.1294949869
-0.128640319666
-0.127529318607
-0.126359977512
-0.12467007597
-0.122355084576
-0.119363901136
-0.115532061953
-0.111025739485
-0.10600324171
-0.100671770686
-0.0951729460397
-0.0896271319031
-0.0840884803226
-0.0785740991846
-0.0730576229322
-0.0674752299117
-0.0617216253353
-0.0556553487324
-0.0491013801394
-0.0418318263536
-0.0335146798795
-0.0237152997938
-0.0121499052788
0.00105816559185
0.0163146112198
0.0372027668971
0.0722038453571
0.125734111944
0.1720545099
-0.118331136559
-0.118338288241
-0.118345385663
-0.118364426783
-0.118389780059
-0.118419339015
-0.118445711177
-0.118481401587
-0.118522001934
-0.118572409747
-0.118642270727
-0.118712420657
-0.118780733067
-0.118852367083
-0.11893807493
-0.119024885258
-0.119115336595
-0.119213426682
-0.119304647058
-0.119394335094
-0.119484868666
-0.11958407004
-0.119676100078
-0.119762300796
-0.119875804118
-0.120020003359
-0.120190167753
-0.120357459094
-0.120519818071
-0.120706068507
-0.120907328526
-0.121122646485
-0.121317491242
-0.121518720081
-0.121748466522
-0.122014699613
-0.122313611723
-0.122635766406
-0.122968730588
-0.123327601947
-0.123726912808
-0.124179878866
-0.124673244025
-0.125198827268
-0.125781183241
-0.126468343233
-0.127136994769
-0.127835513504
-0.128656311726
-0.12862110084
-0.12756581423
-0.126193153342
-0.125263544067
-0.123697693695
-0.121336213869
-0.118181326655
-0.114224992608
-0.109464208381
-0.104119178033
-0.0983929150783
-0.0924949676177
-0.0865588800092
-0.0806756047686
-0.0748694676467
-0.0691221140602
-0.0633696952388
-0.0575108019153
-0.0514073488829
-0.0448930435851
-0.0377751883056
-0.0298090609808
-0.0206410002952
-0.00981253100811
0.00300086240234
0.0177965140366
0.0351688462457
0.0586573623952
0.0955725122708
0.147266304996
0.188437590698
-0.118086751856
-0.118094146471
-0.118099615572
-0.118110834477
-0.118139089947
-0.118169823411
-0.118199003723
-0.118234815816
-0.118279834004
-0.118329926127
-0.118398052583
-0.11846683238
-0.118534996409
-0.118604981113
-0.11868789434
-0.118772944258
-0.118860552842
-0.11895955716
-0.119054550979
-0.119148364686
-0.119242307333
-0.119343520707
-0.119438432027
-0.11953249403
-0.119637406687
-0.119763151567
-0.119907475058
-0.120057315786
-0.120198778249
-0.120367730024
-0.120556001053
-0.120762068507
-0.120969317002
-0.121162583786
-0.12137666199
-0.121616162944
-0.121895304932
-0.122213173511
-0.122558042764
-0.122927177939
-0.123345858724
-0.123811872826
-0.124310598005
-0.124849334007
-0.125465119244
-0.12610423077
-0.126779174689
-0.127481406624
-0.127760139715
-0.126301745376
-0.124603485463
-0.123789464072
-0.122561394464
-0.120332359057
-0.117205726321
-0.113171814803
-0.108305534065
-0.102740445537
-0.0967325861853
-0.0904997968365
-0.0842300337503
-0.0780317295225
-0.0719593295177
-0.0660029885366
-0.0601092460501
-0.0541833624568
-0.0480989265249
-0.0417010538542
-0.0348134285836
-0.0272378758327
-0.018726487903
-0.00892928992592
0.00258739942484
0.0161377303769
0.0317766285227
0.0501232972033
0.0744965813054
0.111023138956
0.159450376194
0.196427490301
-0.117836833589
-0.117843027212
-0.117846722666
-0.117855834753
-0.117879532987
-0.117907780755
-0.117936910882
-0.117970888875
-0.118016434623
-0.118068309753
-0.118136587675
-0.118204491376
-0.118272341774
-0.118340653913
-0.118420937342
-0.118504240071
-0.118589421697
-0.118688847611
-0.118786331886
-0.118884481312
-0.118987173142
-0.119088703868
-0.119185816102
-0.119275268461
-0.119379452437
-0.119501113812
-0.119629828276
-0.119754545764
-0.119873983185
-0.120021939132
-0.120192561794
-0.120375833193
-0.120574525781
-0.120764631699
-0.120968001605
-0.121193254229
-0.121448185877
-0.121749701089
-0.122098895653
-0.122483958946
-0.122920208898
-0.123395287714
-0.123897987002
-0.124434972179
-0.125021279537
-0.125679617135
-0.126418494104
-0.12725111416
-0.125309258633
-0.123144694496
-0.122096402673
-0.121194686766
-0.119268190411
-0.116276805808
-0.11232066642
-0.107437464651
-0.101787387028
-0.0955858113287
-0.0891017404414
-0.0825452578924
-0.0760696405413
-0.0697476758015
-0.0635941787546
-0.0575664807106
-0.0515834782017
-0.0455315316757
-0.0392737117945
-0.0326525090857
-0.0254940740755
-0.0176065572933
-0.00875440988701
0.0013861151126
0.013209111966
0.0270170763778
0.0428884415881
0.061330730538
0.0851260765153
0.119411887586
0.163776667887
0.197535362143
-0.117579142919
-0.117586607842
-0.117586409599
-0.117598858379
-0.117614717531
-0.117637842265
-0.117664962679
-0.11769605477
-0.117740514905
-0.117790395769
-0.117858746425
-0.117925369085
-0.117992140332
-0.118058782435
-0.118136821667
-0.118217266525
-0.118298963771
-0.11839832902
-0.11849758274
-0.11859605636
-0.118702982952
-0.118803004168
-0.118905609293
-0.11899891359
-0.119091334598
-0.1192064297
-0.119335864944
-0.119445007353
-0.119545876058
-0.119667708312
-0.11982259488
-0.119989692713
-0.120166131633
-0.120339816505
-0.120521242255
-0.120730721685
-0.120964434425
-0.121247932126
-0.12159480028
-0.121996718273
-0.122446801751
-0.122923861271
-0.123413792041
-0.12393922112
-0.12450751658
-0.125126484263
-0.125966479574
-0.124693445833
-0.122519589301
-0.120458274996
-0.119691660336
-0.118106657341
-0.115380837664
-0.111569312656
-0.106776687305
-0.101128809314
-0.0948514579077
-0.0881958915391
-0.0814166642427
-0.0746959320134
-0.0681458512187
-0.0618015471054
-0.0556422709552
-0.0495995199943
-0.0435745228103
-0.0374454299394
-0.031074267373
-0.0243075907527
-0.0169773928305
-0.00889868712173
0.000150859710308
0.0104675713509
0.0224108466799
0.036273711964
0.0521481432685
0.0703924718299
0.0931703556401
0.124772557219
0.16506457933
0.196056637424
-0.117303075813
-0.117311539688
-0.117313121434
-0.117326328418
-0.117339895097
-0.117359860694
-0.117383820578
-0.117411952935
-0.11745337868
-0.117498344507
-0.117565665186
-0.117631124246
-0.117694717004
-0.117759981753
-0.117837097399
-0.117914725576
-0.117991679922
-0.118087889994
-0.118187819802
-0.118283792111
-0.118390585384
-0.118490924618
-0.118591137457
-0.118696707947
-0.118792978698
-0.118902834662
-0.119028762045
-0.119139175662
-0.119217903384
-0.11931013352
-0.119439738549
-0.119592482383
-0.119752264661
-0.119909876616
-0.120064356761
-0.120246941626
-0.120450702427
-0.120709320603
-0.121048756878
-0.121461564168
-0.12191674908
-0.122365184803
-0.122855659545
-0.123367525589
-0.123893115717
-0.124424119744
-0.12422064127
-0.121666288038
-0.118791814584
-0.11786199829
-0.116799768998
-0.114432228936
-0.110907390654
-0.106271438442
-0.100709559236
-0.0944249818816
-0.0876844935485
-0.0807434050153
-0.0738230611587
-0.0670648379181
-0.0605376614084
-0.0542414958676
-0.048127403475
-0.0421091746405
-0.0360784683684
-0.0299113870988
-0.023472807297
-0.016615215371
-0.00917753282778
-0.000983080628856
0.00817434652216
0.0185592693664
0.0304908010126
0.0442401377286
0.0598921165152
0.0776597152834
0.0991896951016
0.128137022527
0.164740236374
0.193336350724
-0.117012115127
-0.117017116356
-0.117024197537
-0.117037158214
-0.117051876555
-0.117071076784
-0.117092607591
-0.117117947632
-0.117155612861
-0.117194371457
-0.117258767881
-0.117323760392
-0.117383184282
-0.117445136681
-0.117522945288
-0.117599289874
-0.11767323942
-0.117760960938
-0.117856825277
-0.11795050484
-0.118053836831
-0.118158801014
-0.118265857597
-0.118372482838
-0.118477724576
-0.118583325574
-0.118705853212
-0.118826581818
-0.118892909012
-0.118957333858
-0.119048970614
-0.119176639263
-0.119318918035
-0.119469850084
-0.119602269923
-0.119746006982
-0.119914308652
-0.120135388107
-0.120460360333
-0.120878018429
-0.121327863376
-0.121761327546
-0.122229129561
-0.122736490405
-0.123291623321
-0.124013068114
-0.12109651606
-0.117747661195
-0.115787581645
-0.115125443788
-0.113328765736
-0.110202337373
-0.105881606177
-0.100480369049
-0.0942680523145
-0.0874980883987
-0.0804531557009
-0.0733701982872
-0.0664281096344
-0.059723590088
-0.0532847912113
-0.0470815488796
-0.0410440896314
-0.0350752739287
-0.0290627089972
-0.0228839799073
-0.0164089607125
-0.00949787544713
-0.00199938858811
0.00625057288844
0.0154374996157
0.0257909504191
0.0375870901133
0.0510669954509
0.0662942491842
0.0833539724025
0.103488019806
0.129881985484
0.163164991229
0.189686776825
-0.116708210125
-0.116712778618
-0.116721564999
-0.116734293422
-0.11675039251
-0.116770180275
-0.116789748354
-0.116812862719
-0.116848096001
-0.116880681375
-0.116939973
-0.117004917395
-0.117061882102
-0.117117206722
-0.117194184966
-0.117270385407
-0.117342709362
-0.117421542319
-0.117508578064
-0.117597370862
-0.117697894551
-0.117797318652
-0.117913352592
-0.118024511836
-0.11813527249
-0.11824098603
-0.118361018226
-0.11849061593
-0.118571534914
-0.118614797868
-0.118673183118
-0.118758473288
-0.118874153083
-0.119002962085
-0.119132859833
-0.11924275361
-0.119366437022
-0.119526748577
-0.119826468854
-0.120232813443
-0.120643703905
-0.121091228411
-0.121530547941
-0.121981543293
-0.122514793317
-0.121154955947
-0.117881598625
-0.114167333997
-0.113214230295
-0.112024731842
-0.109397547248
-0.105488749734
-0.100388591351
-0.0943202681764
-0.0875962710942
-0.0804937740407
-0.0732865883051
-0.0661779606431
-0.0593012865992
-0.052710673136
-0.0463994334083
-0.0403136532505
-0.0343693508338
-0.0284636559192
-0.0224840848915
-0.0163123556401
-0.00982550741691
-0.00289387830749
0.00462084105307
0.0128660835703
0.0220035549274
0.0322275863096
0.0437727641392
0.0568487147478
0.071495604423
0.0876951241278
0.106367202817
0.130320740402
0.160545479303
0.185193125555
-0.116396493366
-0.116399788815
-0.116407156037
-0.116420743193
-0.116436882695
-0.116456372091
-0.116474221048
-0.116494594914
-0.116530251981
-0.116563050816
-0.116611539979
-0.116675035847
-0.116731632029
-0.116784151972
-0.11685280841
-0.116926472679
-0.116997495841
-0.117069333673
-0.117148908808
-0.117228427182
-0.117326604222
-0.1174210898
-0.117525865285
-0.117635698843
-0.117749742541
-0.117866559418
-0.117989655575
-0.118130613459
-0.118244434505
-0.118281269321
-0.118319284138
-0.118370737201
-0.118446304586
-0.118529944075
-0.118634214652
-0.118734477361
-0.118821865048
-0.118906431572
-0.119131728609
-0.119529149872
-0.119920286561
-0.120334308546
-0.120786074848
-0.121293238321
-0.121910892567
-0.117933260569
-0.113396843648
-0.111134174835
-0.1104283366
-0.108439451432
-0.105035234308
-0.100344065662
-0.0945356383516
-0.0879207911863
-0.0808252873724
-0.0735288969038
-0.0662769271155
-0.05923076063
-0.0524791156894
-0.0460386652097
-0.039875028695
-0.0339172177288
-0.0280727786814
-0.0222373208132
-0.0163014049918
-0.0101532692408
-0.00367927805242
0.00323791425618
0.0107211800867
0.0188989965765
0.0279082639965
0.0379093796707
0.0490976341583
0.0616522934141
0.0755945485468
0.0908305544684
0.108021570795
0.129647324935
0.157001761539
0.179888294121
-0.116073473383
-0.116077050147
-0.116083910362
-0.116098922666
-0.116113129384
-0.116130249315
-0.116147027285
-0.116163517791
-0.116197779705
-0.116234115555
-0.116271365994
-0.116332022042
-0.116388315402
-0.116441670931
-0.116498892272
-0.11656689865
-0.116634896788
-0.11670070361
-0.116776889694
-0.116850276778
-0.116937947778
-0.117031441379
-0.117122737091
-0.117223300458
-0.11733426246
-0.117449256656
-0.117576894547
-0.117722786091
-0.117874252932
-0.117949772314
-0.117969533445
-0.118001408183
-0.118032295632
-0.118088043903
-0.118142523183
-0.118209181535
-0.118267018018
-0.118304150677
-0.118343227976
-0.118733828417
-0.119153335966
-0.119516414212
-0.119900328975
-0.120433443177
-0.118431739525
-0.114322469895
-0.109467833821
-0.108388852172
-0.107169172211
-0.104398418699
-0.100251225368
-0.0948301031596
-0.0884289183782
-0.0813990955045
-0.074065076992
-0.0666919866416
-0.0594855660211
-0.0525635260471
-0.0459738353459
-0.0397021612287
-0.033693466746
-0.0278656920006
-0.0221227269769
-0.0163620607034
-0.010479866504
-0.00437289080431
0.00206143854887
0.00892663979932
0.016328856886
0.0243767337451
0.0331826053032
0.0428746761477
0.0536108445591
0.0655408909764
0.0786724531802
0.0928624133232
0.108565467768
0.127959513541
0.15257835104
0.17376136769
-0.115744023162
-0.115746685929
-0.115756841583
-0.115771505497
-0.115781052001
-0.115794526637
-0.115810388809
-0.115824890946
-0.115850694331
-0.115886261963
-0.115917135603
-0.115973704012
-0.116028259823
-0.116079622636
-0.116128434644
-0.116190344191
-0.116251563444
-0.116311857137
-0.116385463651
-0.116457436083
-0.116530510394
-0.116615504351
-0.116698059726
-0.116791756013
-0.116891756992
-0.116996427329
-0.117117669261
-0.117256584369
-0.117415687182
-0.117566159521
-0.117611966014
-0.117614139483
-0.117621139448
-0.117637226233
-0.117655613939
-0.117678699984
-0.117704232081
-0.117727835575
-0.117724029056
-0.11789026438
-0.118337965012
-0.118703629051
-0.119129542083
-0.120131437494
-0.114906480565
-0.109222327104
-0.106066546402
-0.105458314902
-0.103452756537
-0.0999641804772
-0.0950923610998
-0.0890351565494
-0.0821701243459
-0.0748546685111
-0.0674004741341
-0.0600443623969
-0.0529486848702
-0.0461901359484
-0.0397818812886
-0.0336854793227
-0.0278315422221
-0.0221320291027
-0.0164909939474
-0.0108105314223
-0.00499446175541
0.00105036126374
0.0074141220951
0.0141854688831
0.0214531064088
0.0293056815709
0.037831948148
0.047130497769
0.0573248648671
0.0685374338672
0.0807672074235
0.093843508686
0.108056942905
0.125301657245
0.147282672764
0.166779457357
-0.115404516401
-0.115408646548
-0.115422478763
-0.115433016626
-0.115438602086
-0.1154495435
-0.115464414836
-0.115477784815
-0.115495199432
-0.115526326148
-0.115551092988
-0.115600600338
-0.115653239103
-0.115698573686
-0.115740450921
-0.11579868073
-0.115851609157
-0.115902611574
-0.115972016789
-0.116038727159
-0.116101956764
-0.116177843787
-0.11624846543
-0.116336570467
-0.116424266098
-0.116519811665
-0.116622075475
-0.116740521906
-0.116878128522
-0.117040531649
-0.117179869284
-0.117207508173
-0.117210278842
-0.117186332152
-0.117174140642
-0.117174071337
-0.117187053382
-0.117206363935
-0.117248143217
-0.117317124154
-0.117532491829
-0.117773710509
-0.118048063135
-0.116390698672
-0.111028781234
-0.10447701674
-0.103021381406
-0.102090075154
-0.0993361464993
-0.0951744253449
-0.0896310051648
-0.0830554480883
-0.0758516549447
-0.06836794289
-0.0608917850428
-0.0536232481903
-0.046682267098
-0.0401094503831
-0.0338900202496
-0.0279680067713
-0.0222651592358
-0.0166915636352
-0.0111544064548
-0.00556242901347
0.000171419212693
0.00612912703859
0.0123877822206
0.0190208567299
0.0260997852063
0.0336940012244
0.0418704471055
0.0507010090905
0.0602777066836
0.0706960713965
0.0819467434789
0.0938437766357
0.106550415953
0.121701163697
0.141110420682
0.158898030243
-0.115057323671
-0.115061321684
-0.115067355826
-0.115076652811
-0.115083317499
-0.115093540377
-0.115106994833
-0.115118280049
-0.115131192525
-0.115157065985
-0.115179373233
-0.115216003948
-0.115267016371
-0.11530708577
-0.115341459924
-0.115394790846
-0.115443972307
-0.11548680617
-0.115543151819
-0.115601140804
-0.115653461938
-0.115723262405
-0.115784954396
-0.115853955022
-0.115928883324
-0.116014557502
-0.116097260426
-0.116191115598
-0.116299533502
-0.116425590957
-0.11657546193
-0.116712336934
-0.116751197289
-0.116757230253
-0.11675133671
-0.116743522908
-0.116737310682
-0.116738304487
-0.116758344336
-0.116775970331
-0.116802062541
-0.116954033161
-0.117939253937
-0.112232564509
-0.105618163874
-0.10039160155
-0.0999973681292
-0.0983001136623
-0.0948893869844
-0.0900743891074
-0.0839506128477
-0.0769786211528
-0.0695507178861
-0.0619991584259
-0.0545775386862
-0.0474465106716
-0.0406872891078
-0.0343104032337
-0.0282798547304
-0.0225280262419
-0.0169723462325
-0.0115242979596
-0.00609640921679
-0.0006055401745
0.00502525498752
0.0108661689089
0.0169807994035
0.0234272305255
0.0302595338028
0.0375279464879
0.0452779404352
0.0535557853307
0.0624237871067
0.0719529220027
0.0821290231428
0.0927657321267
0.103937316134
0.117058502553
0.133998627892
0.150060622337
-0.114698991628
-0.114702970456
-0.11470265867
-0.11471168737
-0.114719969678
-0.114728420756
-0.114738555368
-0.114746683103
-0.114754777937
-0.114776227962
-0.114799746607
-0.114822729966
-0.114870412425
-0.114909954374
-0.114941028521
-0.114980745139
-0.115026836607
-0.115065668377
-0.115104713135
-0.115154683069
-0.115196996938
-0.115250196414
-0.115305782092
-0.11535321206
-0.115412242776
-0.11547396837
-0.115540672038
-0.115611621248
-0.115688634198
-0.115779432089
-0.115881392722
-0.116008547848
-0.11612228573
-0.116206177473
-0.116229475126
-0.116220220638
-0.11618214787
-0.116145617673
-0.116096465741
-0.115957809899
-0.115813585408
-0.11579845471
-0.115735610271
-0.108360429402
-0.0997587819945
-0.0968470353333
-0.0966454110201
-0.0941538587069
-0.0901635654021
-0.0847295659902
-0.0781362934687
-0.0708796936636
-0.0633277631863
-0.0557892872704
-0.048478336868
-0.0415175656078
-0.0349546045454
-0.028776082219
-0.0229308811407
-0.0173446263679
-0.0119340619045
-0.00661452467051
-0.00130547840142
0.00406711668915
0.00956948283986
0.0152596522051
0.0211875460726
0.027395889515
0.033921800702
0.0407975260593
0.0480497031909
0.0557036391817
0.0637985816126
0.0723875968711
0.0814552482283
0.0908070532374
0.100417608618
0.111493716245
0.125998951003
0.140342420512
-0.114337033342
-0.11434031931
-0.114343643452
-0.114348066925
-0.114352619385
-0.114356725637
-0.114361771381
-0.114366745662
-0.114370179176
-0.114385093853
-0.114407598745
-0.114421238318
-0.114459868632
-0.11450126545
-0.114530555234
-0.114554879947
-0.114595569841
-0.114627710272
-0.114652239222
-0.114693741956
-0.114729450005
-0.114761340722
-0.114803425574
-0.11483328649
-0.114875737813
-0.114912542452
-0.114960005767
-0.115003567975
-0.11504898286
-0.115102912526
-0.115162051886
-0.115222204902
-0.115289494119
-0.115349492136
-0.115367836568
-0.115339081184
-0.115277531254
-0.115192715286
-0.115047061906
-0.114806333832
-0.114586227105
-0.114637590215
-0.110931255921
-0.103544658081
-0.0947390371976
-0.0937392273812
-0.0929143510658
-0.0897412504355
-0.0851993137696
-0.0792136582806
-0.0722633392589
-0.0648191827052
-0.0572264762373
-0.04976247544
-0.0426007989445
-0.0358297383141
-0.0294689308676
-0.0234869719641
-0.0178228001239
-0.0123992479658
-0.00713517201294
-0.00195161147961
0.0032238965592
0.00845559483035
0.0137985826767
0.0192985543025
0.0249918238314
0.0309060991378
0.0370622110642
0.0434754278548
0.0501547577379
0.0571047561773
0.0643376606782
0.0718790479035
0.0796947075159
0.087563766886
0.095356193694
0.104176834185
0.11642831587
0.129813256289
-0.113966206322
-0.113969703171
-0.113975124077
-0.113976837315
-0.113976312115
-0.113977380515
-0.113979049877
-0.113981781073
-0.113982284665
-0.113989018041
-0.114007626631
-0.114020226523
-0.11404016455
-0.114080449881
-0.114106040883
-0.114121259412
-0.114151820604
-0.114178461312
-0.11419390512
-0.11421879632
-0.114244053351
-0.114258962852
-0.114286906038
-0.114304004033
-0.114321808247
-0.114340755436
-0.114358515646
-0.114373870126
-0.114389070795
-0.114401624477
-0.114417399588
-0.114422460205
-0.114423555644
-0.114408587978
-0.11437385119
-0.114299506612
-0.114185445064
-0.11402217144
-0.113809568456
-0.113611797912
-0.113464893351
-0.114492263801
-0.106888284874
-0.0970796474315
-0.0904029969921
-0.0905999694618
-0.0888689594708
-0.0851436217931
-0.080048879872
-0.0736002842904
-0.0663921155236
-0.0588418142675
-0.0512742788861
-0.0439286893736
-0.0369410317336
-0.0303696453129
-0.0242117537813
-0.0184230597862
-0.0129368119146
-0.00767611978
-0.00256405380673
0.00247135864638
0.00749376630734
0.0125572429551
0.0177056069456
0.0229722507699
0.0283801041666
0.0339422068407
0.0396634255096
0.0455425114925
0.051572228777
0.0577394408625
0.0640351483695
0.0704662387605
0.0770079402056
0.0834688032548
0.089677818518
0.0966032830626
0.106892987835
0.119460542947
-0.11359054314
-0.113591435755
-0.11359143614
-0.113589033896
-0.11358930598
-0.1135905803
-0.11359115139
-0.113592002024
-0.113589317216
-0.113587998549
-0.113599477836
-0.113614312738
-0.11361830117
-0.11364726505
-0.113674320685
-0.113685261557
-0.113697629691
-0.113720126853
-0.11373018456
-0.113734020327
-0.11374891631
-0.11375075394
-0.11375746367
-0.11376435843
-0.113754469021
-0.113755833023
-0.113744777574
-0.113735269094
-0.113717875613
-0.113692032719
-0.113665851149
-0.113626569232
-0.113575223729
-0.113501805425
-0.113400953051
-0.113267080466
-0.113082236729
-0.112841156465
-0.11255276171
-0.112283545755
-0.112046683209
-0.11209233593
-0.102838238003
-0.0907586686721
-0.0867875636461
-0.0871513368365
-0.0845760505233
-0.080390471288
-0.074763592889
-0.0679505871155
-0.0605661207259
-0.0529762968846
-0.0454836315849
-0.0382863515946
-0.0314874158998
-0.0251197224956
-0.0191632460089
-0.0135651245486
-0.00825628342051
-0.00316247417896
0.00178746575904
0.00665755576784
0.0115020530398
0.0163644494175
0.0212769268935
0.026260284526
0.0313240269482
0.0364669133808
0.041678741042
0.0469435139788
0.0522417190331
0.0575505651938
0.0628463787167
0.0681115539291
0.0732832860693
0.0780906835263
0.0820800825792
0.085546126301
0.0904773887658
0.0965597124429
-0.113207592292
-0.113207656194
-0.113203073121
-0.113193960719
-0.113197713604
-0.11319992782
-0.113199556849
-0.113198030313
-0.113191763878
-0.113183856445
-0.113186347975
-0.113197569983
-0.113200773977
-0.113208016159
-0.113232978724
-0.113243296034
-0.113240762526
-0.113251642938
-0.113256289666
-0.113245494964
-0.113244477702
-0.113237498716
-0.113218425184
-0.113208118475
-0.113183887926
-0.113157508099
-0.113126581711
-0.113089027084
-0.113042393366
-0.112986611509
-0.112920965744
-0.112841397821
-0.112744784583
-0.112620583394
-0.11246480848
-0.112266129308
-0.112012937027
-0.111684533975
-0.111265033126
-0.110764188337
-0.110575518804
-0.107628709249
-0.0977633790562
-0.0853137413876
-0.0836980254121
-0.0833969509144
-0.0801250563063
-0.0754963742193
-0.0693878532187
-0.0623051784655
-0.0548109901859
-0.04723565218
-0.0398540731829
-0.0328248666418
-0.0262229476155
-0.0200600614977
-0.0143035262612
-0.00889540920042
-0.00376697141454
0.00115161004819
0.00592454474626
0.0106071617572
0.0152438249783
0.0198670547361
0.0244970258533
0.0291417189282
0.0337974177618
0.0384493294764
0.0430724943478
0.0476337781805
0.0520939483596
0.0564037033029
0.0604891258727
0.064209288425
0.0672559581404
0.0689807172843
0.068447163596
0.065127581551
0.0593612315817
0.0519218392099
-0.112823463948
-0.112823267382
-0.11282023441
-0.112812220313
-0.11280987115
-0.112809646893
-0.112807080662
-0.112802175887
-0.112793439537
-0.112780775885
-0.112772277908
-0.112774887888
-0.11278054996
-0.112773785712
-0.112781338769
-0.112792894634
-0.112784786745
-0.112773074376
-0.112773032807
-0.112754836432
-0.11272932996
-0.112712935745
-0.112679431751
-0.112647228868
-0.112611029387
-0.1125577352
-0.112502771218
-0.11243808968
-0.112365681438
-0.112279042223
-0.112178913755
-0.112066675955
-0.111931172982
-0.111765063147
-0.111566275222
-0.11131750254
-0.11100015011
-0.110573839504
-0.109996881261
-0.109097880732
-0.108674953204
-0.103637789072
-0.0912048559018
-0.0805484228085
-0.0806626155236
-0.0793745827566
-0.075574751641
-0.0704818423274
-0.0639601587875
-0.0566863550592
-0.0491366290904
-0.041619111227
-0.0343748460814
-0.0275271163927
-0.021127229947
-0.0151698226865
-0.00961345043978
-0.00439792378028
0.000543081113565
0.00527357034505
0.00984984325654
0.0143178068741
0.018711233602
0.023050770076
0.027343248511
0.0315817682846
0.0357463566276
0.039803998091
0.0437064023899
0.0473859843271
0.0507521142592
0.053684080078
0.0559927696359
0.057322632834
0.0570017952435
0.0539984505772
0.0471001399282
0.0349123483415
0.0159477454271
-0.00662552675709
-0.112433218561
-0.112434523911
-0.112433475438
-0.112434258992
-0.112423985262
-0.112420719829
-0.112415673769
-0.112407623433
-0.112396943001
-0.112379274823
-0.112360239057
-0.112349946252
-0.112347775593
-0.112340220307
-0.112327226411
-0.112330875099
-0.112324485006
-0.112299060449
-0.112282083566
-0.112259271218
-0.112218700603
-0.112183918099
-0.112141620468
-0.112087351105
-0.112029711935
-0.111959893788
-0.111878406207
-0.111791100498
-0.111687775056
-0.11157219114
-0.111447111397
-0.111301425073
-0.111129632468
-0.110929156524
-0.110699276362
-0.110420356768
-0.110070429148
-0.10961455806
-0.108985451543
-0.107771901428
-0.107242951699
-0.101269692492
-0.0848089200173
-0.0767257452041
-0.0774085993014
-0.075129636248
-0.0709253540149
-0.0653592306125
-0.0585042781441
-0.0511007282327
-0.0435404486744
-0.0361152974304
-0.0290280041106
-0.0223718816032
-0.0161782452343
-0.0104283310256
-0.00507516925623
-5.85887484713e-05
0.00468361965767
0.00920847198841
0.013563377244
0.0177838049735
0.0218915753122
0.0258934981597
0.0297801288174
0.0335254052677
0.0370872719251
0.0404076928961
0.0434079666994
0.0459781749203
0.0479684911806
0.0491869826884
0.0493796097667
0.0481333470543
0.0447328616169
0.0380786081155
0.0265251871252
0.00893630937876
-0.00775671544452
-0.00710555443604
-0.112045386818
-0.112045496998
-0.112041316515
-0.112046821406
-0.112039202382
-0.112033566013
-0.112026180155
-0.112015155167
-0.112001339671
-0.111979801368
-0.111953876784
-0.111928731279
-0.111913538978
-0.111902124649
-0.111881614685
-0.111861749456
-0.111853266962
-0.111829173796
-0.11178975712
-0.111758059594
-0.111713534182
-0.111655159369
-0.111597889376
-0.111527288931
-0.111448692525
-0.111360294367
-0.111257628408
-0.111143710535
-0.111015515643
-0.110877718527
-0.110719792845
-0.110538486161
-0.110335536927
-0.11011215789
-0.10986285614
-0.109579551174
-0.109258896584
-0.108912072519
-0.108508418945
-0.10813889715
-0.106538243715
-0.0969635610116
-0.0788457832441
-0.0734713137236
-0.073829379727
-0.0707203773177
-0.0661519689794
-0.0601310002774
-0.0530247470591
-0.0455413693855
-0.0380101946294
-0.0307057356152
-0.023791528946
-0.0173361774237
-0.0113539375887
-0.00581601593345
-0.000672562429458
0.00413465400856
0.00866225736157
0.0129591215166
0.0170625898811
0.0209961732522
0.0247675494123
0.0283666040651
0.0317635931868
0.0349083116881
0.0377312196074
0.0401455796288
0.0420456942488
0.0432947111614
0.0437088405601
0.0430630707533
0.041118528847
0.0375669622748
0.031644580718
0.0214597507093
0.00562838530008
-0.00894292378021
-0.00899187666695
-0.00902224098506
-0.111658441287
-0.111659159804
-0.111655043437
-0.11165907373
-0.111660103368
-0.111649849698
-0.111638511627
-0.11162342385
-0.111605010467
-0.111581538763
-0.111550704908
-0.111516438994
-0.111485594149
-0.111462084842
-0.11143980756
-0.111404938348
-0.11137740848
-0.111350403003
-0.111302677875
-0.111250993358
-0.111198915042
-0.111128591469
-0.111050974004
-0.110965640932
-0.110867670799
-0.110757400338
-0.110635362301
-0.110497209883
-0.110350312921
-0.110185657427
-0.109995835379
-0.109787634695
-0.10955680523
-0.109308988179
-0.109040230397
-0.108757664979
-0.108483277352
-0.108249380964
-0.108047217524
-0.108540874904
-0.104066626631
-0.0915957661943
-0.073367443762
-0.0702066430821
-0.0698629301814
-0.0661530565658
-0.061220488415
-0.0547931971038
-0.0475113904598
-0.0399920660733
-0.0325270861803
-0.0253681019744
-0.0186420168239
-0.0123972204126
-0.00663353342984
-0.001315165177
0.00360839809521
0.00819173155455
0.0124844644807
0.0165260328135
0.0203421600879
0.0239422282685
0.0273166468181
0.0304343223978
0.0332407365888
0.035657689781
0.0375860765571
0.0389127589819
0.0395173576624
0.0392666849183
0.0379893930446
0.0354614801649
0.0314370181018
0.02553287695
0.0165623770433
0.00314485113034
-0.0099255120659
-0.00994481562355
-0.0107579545538
-0.0110071761052
-0.111273126781
-0.111272584617
-0.111270003266
-0.111266586352
-0.111269890511
-0.11126180438
-0.111249348953
-0.111230798176
-0.111207952965
-0.111182182694
-0.111147563481
-0.111108632553
-0.111064215143
-0.111025560513
-0.110993482739
-0.110958015393
-0.110911747317
-0.110870681519
-0.110819821738
-0.110753257275
-0.110680749032
-0.110602316466
-0.110508937218
-0.110404695738
-0.110288756219
-0.110160664256
-0.110016270263
-0.109859284251
-0.109684069201
-0.109489644816
-0.109270320614
-0.109029352334
-0.10876706351
-0.1084877005
-0.108192619247
-0.1079039848
-0.107655169982
-0.107462094538
-0.107319889277
-0.108468661441
-0.10103415041
-0.0852660935793
-0.0678436544487
-0.0665032898323
-0.0654651523754
-0.0613763051072
-0.0560895080678
-0.0493330897337
-0.0419446219208
-0.0344319237411
-0.0270692636987
-0.0200791978474
-0.0135568505335
-0.00753398021518
-0.00199854645465
0.00308949010074
0.00777935380908
0.0121203155034
0.0161535271806
0.0199074250365
0.0233941153006
0.026606105278
0.029512868053
0.0320581511756
0.0341593108
0.0357097854818
0.0365855287018
0.0366566568874
0.0358035536864
0.0339252356292
0.030917750246
0.0266149734121
0.0206506390873
0.0121595754199
0.000579723724213
-0.0104726795579
-0.0118128164094
-0.0125257179081
-0.0129264951214
-0.0130939820956
-0.110877989996
-0.110876429447
-0.110872181019
-0.110861937054
-0.110860829508
-0.110861657304
-0.110853964571
-0.11083450633
-0.110808829491
-0.110779384832
-0.110743657872
-0.110698845786
-0.110649990563
-0.110596285784
-0.110548659963
-0.110506441753
-0.110454801652
-0.11039507145
-0.110334535679
-0.110262641331
-0.110174001994
-0.110075810043
-0.109970894138
-0.10984906032
-0.109714867292
-0.109567255992
-0.109401853126
-0.109217120572
-0.109010143409
-0.108780333726
-0.108524691237
-0.108248511129
-0.107955827343
-0.107642072687
-0.107318265967
-0.107014666694
-0.10672442017
-0.10648930239
-0.106215711472
-0.107883654825
-0.0975609525704
-0.0781491566433
-0.0621311869659
-0.0622474636889
-0.0606416234636
-0.056331901464
-0.0507236592805
-0.0437324561557
-0.0363014445388
-0.0288395672711
-0.0216151677624
-0.0148175216656
-0.00851592003013
-0.00272831607729
0.00256652288002
0.00741037624711
0.0118493434734
0.0159257024777
0.0196704834398
0.0230992210568
0.0262079808144
0.0289692284852
0.0313277295313
0.0331984939014
0.0344691384881
0.0350077327005
0.0346753380837
0.0333415352965
0.0309039336677
0.0273154840117
0.0225973482492
0.0167450706877
0.00928134814058
-0.00108719510148
-0.0126233709709
-0.0176631814396
-0.0155594277766
-0.0152667687183
-0.0151756429652
-0.015160141952
-0.110480974609
-0.110475695906
-0.110466179992
-0.110454553528
-0.110447281094
-0.110448209535
-0.110445454464
-0.110429795661
-0.110405154716
-0.110373978824
-0.110337929974
-0.110291615488
-0.110240063932
-0.110179910801
-0.110118308311
-0.110058462068
-0.110001067284
-0.109931436806
-0.10985420648
-0.109771827433
-0.109676346135
-0.109562111554
-0.109436509843
-0.109300335945
-0.109147907188
-0.108975987718
-0.108784462051
-0.108568882752
-0.108332100555
-0.108067593034
-0.1077851426
-0.107474730434
-0.107139042672
-0.10678252228
-0.106425604208
-0.106066417347
-0.105705827411
-0.105406680129
-0.104913967895
-0.106963693116
-0.0934206740722
-0.0702559744586
-0.0561470597188
-0.0574813367586
-0.0554376529161
-0.0509949325977
-0.0451111759783
-0.0379789328602
-0.0305635976228
-0.0231976684898
-0.0161467423634
-0.00956538996658
-0.00350290543407
0.00203425176507
0.00707376730741
0.0116568627166
0.0158246919755
0.0196107669495
0.0230341277255
0.0260951987255
0.0287712427806
0.0310114246574
0.0327325883316
0.0338193700207
0.0341317905919
0.033521392409
0.0318533892002
0.0290282679446
0.0250018799415
0.0198247954333
0.0136889523217
0.00675550601631
-0.00133026190397
-0.0111474593165
-0.0221568156824
-0.019030882774
-0.0178964842481
-0.0173407177427
-0.0170665146743
-0.0169529494622
-0.110084523277
-0.110077528322
-0.11006528906
-0.11005322299
-0.110040278941
-0.110031474023
-0.110026385637
-0.110018475982
-0.109998099736
-0.109968359095
-0.109931261979
-0.109886808496
-0.109830365677
-0.109770060825
-0.109699997565
-0.109627656377
-0.109553051838
-0.109476076348
-0.109387083153
-0.109288313334
-0.109180665266
-0.109058199451
-0.108916731416
-0.108760608725
-0.108588217659
-0.108392973018
-0.108173472395
-0.107933733455
-0.107666081746
-0.107375383959
-0.107051566112
-0.106694374811
-0.1063094742
-0.105909591646
-0.105499037139
-0.105069452256
-0.104647396731
-0.104277436043
-0.103711309561
-0.106456093783
-0.0878610036758
-0.0614532149028
-0.0498821116877
-0.0522668717217
-0.0498912504586
-0.0453688722292
-0.0392633870492
-0.0320723181555
-0.0247231753645
-0.0174964381082
-0.0106519533606
-0.00431045812344
0.00149385802381
0.00676408509015
0.0115316727639
0.015835179064
0.0197089804758
0.0231759275734
0.0262410099446
0.0288870688116
0.0310696962667
0.0327117698374
0.0337003967865
0.0338915184798
0.0331257513069
0.0312549866058
0.0281756776095
0.0238599054514
0.0183749956826
0.0119153730353
0.00483238151262
-0.00272204063492
-0.0113741509991
-0.0192766674075
-0.0202612536251
-0.0198945999259
-0.0192513886658
-0.0187846600433
-0.0184998701635
-0.0183565714395
-0.109696792325
-0.109688558087
-0.109675734829
-0.10966124429
-0.109645181163
-0.109628051272
-0.10961547592
-0.109609747997
-0.109592996118
-0.109565079667
-0.109527636321
-0.109482378268
-0.109425793349
-0.109360277185
-0.109288630343
-0.109205831595
-0.109117148588
-0.109024796691
-0.108927910326
-0.108817251589
-0.108695610907
-0.108557611961
-0.108406760712
-0.108232277457
-0.108037927778
-0.107820407528
-0.107579331879
-0.107311540675
-0.107014011057
-0.106680030424
-0.106307815291
-0.105912192246
-0.105485872124
-0.105032110669
-0.104544919806
-0.104023359051
-0.103470790136
-0.102927106298
-0.102046631605
-0.105063976453
-0.0818290544401
-0.0522493129296
-0.0434813612877
-0.0466690534247
-0.0440378142721
-0.0394765688239
-0.033204977129
-0.0260229638123
-0.0187828053389
-0.0117343144131
-0.00512561630498
0.000953781600407
0.0064811378846
0.0114673682495
0.0159451641683
0.019948504892
0.0235031215097
0.0266192336597
0.0292855511787
0.0314648001061
0.0330882084302
0.0340503571198
0.0342092141774
0.0333986236805
0.0314558117594
0.0282597076803
0.0237723032005
0.0180766217876
0.0114044776972
0.00413061265231
-0.00331758910231
-0.0106745083161
-0.017936722423
-0.0251108144054
-0.0220273377964
-0.0210054186009
-0.0202922522449
-0.0198122139576
-0.0195196475849
-0.0193744896017
-0.109310297731
-0.109306077742
-0.109294240566
-0.109278837536
-0.109260137432
-0.109238925053
-0.109218350745
-0.109206784012
-0.109192983421
-0.109166673693
-0.109129532694
-0.109082519501
-0.109026779694
-0.108958427247
-0.108882072244
-0.108792155185
-0.108693144386
-0.108589262748
-0.108476958943
-0.108355500969
-0.108222659769
-0.108071814052
-0.107902487519
-0.107712983983
-0.107497648668
-0.107257733109
-0.106992824374
-0.106694107659
-0.106357453955
-0.105980753977
-0.105582476334
-0.105144869277
-0.104664131043
-0.104138957742
-0.103560398851
-0.102924785736
-0.102229308938
-0.101509768552
-0.100298741108
-0.103406528058
-0.0754411817796
-0.0427681937052
-0.0370563028671
-0.0407638955118
-0.0379338516879
-0.0333582994762
-0.0269684393279
-0.0198489090608
-0.0127532955719
-0.00591665679597
0.000431226454877
0.00622843408105
0.0114611192697
0.0161463793457
0.020315853523
0.0239971619921
0.0272055210399
0.0299364751381
0.0321601935401
0.0338168248112
0.0348111093423
0.0350087890485
0.0342425489657
0.0323359630829
0.0291456889053
0.0246112266253
0.0187966903278
0.011922140202
0.00440176144186
-0.00317327630506
-0.0103964601785
-0.017475987234
-0.0231222315314
-0.0240565078306
-0.0226092080217
-0.0215766803899
-0.0209027737608
-0.0204675914196
-0.0201821699883
-0.020039628455
-0.108932975408
-0.108932022338
-0.108921116627
-0.108905564971
-0.108885324602
-0.108861290878
-0.108836378132
-0.108813514572
-0.108797676364
-0.108773985407
-0.108737928782
-0.108690362415
-0.10863216039
-0.108563761654
-0.108480224486
-0.108389159935
-0.108283871893
-0.108170690902
-0.108044571494
-0.107910297424
-0.107762832064
-0.107600282456
-0.107412156865
-0.10720327536
-0.106968158492
-0.106707038534
-0.106413172064
-0.106081407952
-0.105708543539
-0.105310782433
-0.104872064752
-0.104379561841
-0.103837681741
-0.103239173343
-0.102576978199
-0.10184648713
-0.101058735593
-0.100235628126
-0.0989039903986
-0.102374478038
-0.0682667479546
-0.0330012978898
-0.0306281002507
-0.0346049218443
-0.0316429178951
-0.0270616124698
-0.0205904109181
-0.013573672216
-0.006651076604
-5.38734157657e-05
0.00601268143704
0.0115102422821
0.0164321657889
0.0208000789157
0.0246424869092
0.0279789742294
0.0308123425852
0.0331214251891
0.0348556049568
0.0359303150309
0.0362225201384
0.0355707608962
0.0337904894415
0.0307132056512
0.0262446010073
0.0204234350762
0.0134567089752
0.00572356268252
-0.00221394434635
-0.00961376322995
-0.0159267096546
-0.0216182560141
-0.0268179975634
-0.0245351870195
-0.0229990828055
-0.0218997740441
-0.0212088495386
-0.020804784666
-0.0205643136113
-0.0204331998667
-0.108565065713
-0.108564893701
-0.108555281138
-0.108539441363
-0.108518663743
-0.108493208593
-0.108465562634
-0.108436355
-0.108410386062
-0.108387487909
-0.108353895518
-0.108306647849
-0.108246850293
-0.108175180221
-0.108089800367
-0.107993067921
-0.107886859688
-0.107762639244
-0.107628825352
-0.107481682073
-0.107319658585
-0.107140586701
-0.106937054452
-0.106707790837
-0.106453354297
-0.106169052783
-0.105848395769
-0.105486160889
-0.105092542718
-0.104657698538
-0.104167765387
-0.103624147064
-0.103021549487
-0.102354082765
-0.101614212639
-0.100810792105
-0.0999423676102
-0.0990332823373
-0.0975236375131
-0.101467567967
-0.0607278412741
-0.0232047653053
-0.0242182027924
-0.0282375654712
-0.0252206141651
-0.0206296636091
-0.0141071553758
-0.00722329463067
-0.000495703752924
0.00584040027576
0.0116094681351
0.0167927576282
0.0213897194983
0.0254247987378
0.0289214821396
0.0318896584584
0.0343178273512
0.0361660796582
0.0373609692616
0.0377915753741
0.0373071566423
0.0357235527912
0.032852298026
0.0285578945692
0.0228297239776
0.0158421843726
0.00797315221309
-0.000231858146381
-0.00812355364535
-0.0150331154236
-0.0204459717441
-0.0240391874293
-0.0256703695773
-0.0243306152228
-0.0229888350594
-0.0219865791589
-0.0213173420226
-0.0209276584417
-0.0207211051667
-0.0206167387132
-0.10821106409
-0.108206774583
-0.108196670391
-0.108180147496
-0.108158805975
-0.10813284238
-0.108102495362
-0.108071052856
-0.108039097093
-0.108008941098
-0.107977486333
-0.107932001571
-0.107872061683
-0.107798522165
-0.107712005161
-0.107610921951
-0.1074968535
-0.107368503726
-0.107225121291
-0.107069029543
-0.106894229446
-0.10669732126
-0.106476615467
-0.106229857859
-0.10595627623
-0.105648964658
-0.105302331658
-0.104917128567
-0.104490337322
-0.104010614717
-0.103476269184
-0.102881433226
-0.102222900106
-0.101493901799
-0.100691234657
-0.099825974353
-0.0988699915691
-0.0978327088692
-0.0960609212058
-0.100229814609
-0.0531589659037
-0.0134702268962
-0.0178474389166
-0.0217166566941
-0.0187141774118
-0.0140989054139
-0.00755214120751
-0.00082362044769
0.00569233576084
0.0117509092461
0.0172102708719
0.0220674569724
0.0263272008071
0.0300149913196
0.0331475323986
0.0357233677897
0.0377147888916
0.0390612330031
0.0396646501972
0.0393869102579
0.0380512644295
0.0354587469599
0.0314354988876
0.0259094261694
0.0189895431346
0.0110128754249
0.00253267828854
-0.00576155932386
-0.0131777081602
-0.0192077106214
-0.0236506931951
-0.0260143734632
-0.0260023995325
-0.0242745738489
-0.0229029582133
-0.0219501997388
-0.0213111070631
-0.0209325588987
-0.0207439052329
-0.0206531528424
-0.107862060104
-0.107855966488
-0.107844875645
-0.107828680401
-0.107807514609
-0.107782037445
-0.107751977093
-0.107717522773
-0.107683684485
-0.107645715695
-0.107608352443
-0.107565073169
-0.107506862444
-0.107433460652
-0.107344963432
-0.107241919096
-0.107122260268
-0.106987966135
-0.106838278111
-0.106671738277
-0.106483418884
-0.106271597209
-0.106034748574
-0.105771824972
-0.105477807189
-0.105147065666
-0.104775507156
-0.104361268378
-0.103896328803
-0.103378958284
-0.102802827465
-0.102163231687
-0.101454817332
-0.100674707249
-0.0998209037877
-0.098888744041
-0.0978467743115
-0.0967141535786
-0.0949198748274
-0.0993403117643
-0.045212548319
-0.00368896684368
-0.0115212411223
-0.0150865893794
-0.0121613282233
-0.0075014049388
-0.000955993359987
0.00560102931008
0.0118929870118
0.0176619968439
0.0228028532261
0.0273246850911
0.0312368118579
0.0345638920969
0.0373141757906
0.0394731452189
0.0409950189001
0.0417967807535
0.041754455344
0.0407027746195
0.0384428590434
0.034772953703
0.029558038208
0.0228243258972
0.0148352721032
0.00610881221612
-0.00263953043644
-0.010622472379
-0.0171757679335
-0.0219524307343
-0.0250162571869
-0.0271503625502
-0.0255337147361
-0.0238865148757
-0.0226430792112
-0.0217883893064
-0.0212122951146
-0.0208603022986
-0.0206793619185
-0.0206215402129
-0.107520216665
-0.107513540565
-0.107501972796
-0.107487652243
-0.107468438357
-0.107444561964
-0.107415749999
-0.107381264284
-0.107342770662
-0.107302564285
-0.107255579677
-0.107207399784
-0.107149437144
-0.107077684325
-0.106988941981
-0.106883674542
-0.1067618216
-0.106621491372
-0.106464353748
-0.106287532612
-0.106088653089
-0.105863594015
-0.10561237952
-0.105331075841
-0.105015693091
-0.104662324968
-0.104264257464
-0.103818265147
-0.10332061201
-0.102767517103
-0.102152040883
-0.101469040635
-0.10071806094
-0.0998939587011
-0.0989856019725
-0.0979797828174
-0.0968816452071
-0.0957386033729
-0.0940020603023
-0.0989701411404
-0.0369787272529
0.00597862888209
-0.00526919847613
-0.00838152754354
-0.0055942458658
-0.000866903509486
0.00565304693009
0.0120280574272
0.0180871365875
0.0235583162723
0.0283748268035
0.0325543908357
0.0361102029307
0.039064156994
0.0414143888567
0.043131587377
0.0441500732735
0.0443628747419
0.0436193570413
0.0417284607108
0.0384756340515
0.0336731724496
0.0272545856136
0.0193804029536
0.0104971360796
0.00130670227772
-0.00734823139864
-0.0146500181392
-0.0200717814747
-0.0237180884161
-0.0257792236516
-0.0259540589872
-0.0246139533857
-0.0232546824807
-0.022228185181
-0.0215073266991
-0.0210240852519
-0.0207229578873
-0.0205752773536
-0.0205313105587
-0.107187754236
-0.107182330136
-0.107174394084
-0.107163331876
-0.107147108969
-0.107125127442
-0.107097187109
-0.107062916621
-0.107021358671
-0.106977857005
-0.106926669022
-0.106868178573
-0.106802163995
-0.106731664087
-0.106643272916
-0.106537531017
-0.106412419708
-0.10626825171
-0.106103542647
-0.105918048714
-0.105708253757
-0.105471560827
-0.105205229363
-0.104905223757
-0.104569589078
-0.104192963976
-0.103769551181
-0.103295190806
-0.102765923316
-0.102178755333
-0.101527577217
-0.100808328643
-0.100018433995
-0.0991474185162
-0.098175199457
-0.0971185807819
-0.0959722634584
-0.094763584642
-0.0928496916545
-0.0982109531376
-0.0290641495909
0.0153422693216
0.000879271436411
-0.00164437825547
0.000953634379544
0.00577606915372
0.0122489056593
0.0184365719732
0.0242568734175
0.0294252847125
0.033914207667
0.0377466752798
0.0409390278273
0.0435083673846
0.0454410844998
0.0466912650372
0.047171623224
0.0467500016832
0.0452490940375
0.042454713618
0.0381462244602
0.0321729009292
0.0245734545742
0.0156810185905
0.00614555129296
-0.00315665537327
-0.0113136513566
-0.0176066496285
-0.0217092805631
-0.0240907426074
-0.0263191709629
-0.0249105063186
-0.023667516056
-0.0225451493773
-0.0217076796428
-0.0211305501331
-0.0207478144467
-0.0205054531221
-0.0203819325973
-0.0203406666732
-0.106884899172
-0.106881320137
-0.106874788788
-0.106864557145
-0.106849383152
-0.106827816641
-0.106799402814
-0.106763864034
-0.106720585999
-0.106670263891
-0.106616704865
-0.106554388365
-0.10648331401
-0.106402686407
-0.106310458114
-0.106203429539
-0.106076057416
-0.105927173747
-0.105757534692
-0.105562834312
-0.105343252841
-0.105094834227
-0.10481416115
-0.104496151844
-0.104140661829
-0.103742839738
-0.103294862133
-0.102793050759
-0.102234854591
-0.101616856757
-0.100932873055
-0.100177104377
-0.0993485030437
-0.0984211888642
-0.0973989557898
-0.0962933264528
-0.0950689201518
-0.0937681198577
-0.0917229126523
-0.0972153095138
-0.0212721749179
0.0246097435884
0.00695167581782
0.00509185516306
0.00745521126593
0.0124022245513
0.0188081424401
0.024807612595
0.0303857474946
0.0352494332982
0.0394097976791
0.0428922292323
0.0457153877496
0.0478895401492
0.049387672038
0.0501455019498
0.0500526152361
0.0489510658573
0.0466380525329
0.0428811618551
0.0374677727377
0.0303146710274
0.0216095788321
0.011893830522
0.00201709973312
-0.0070244446653
-0.0143315903445
-0.0194644862973
-0.0227406361415
-0.0244409918176
-0.024365521474
-0.0235586299851
-0.0226121225493
-0.0217456707125
-0.0210872953969
-0.0206266258479
-0.0203078726712
-0.0201173870655
-0.0200275459172
-0.019979146158
-0.106607323165
-0.106608401998
-0.10660172439
-0.106591307416
-0.106575449851
-0.106552607578
-0.106522307258
-0.106484343092
-0.106438462221
-0.106383569016
-0.106323896995
-0.106259656559
-0.106188936504
-0.106099926152
-0.106000384802
-0.105885776207
-0.105753829137
-0.105601259713
-0.10542586077
-0.105223605506
-0.104994757331
-0.104735469503
-0.104439540011
-0.104104864363
-0.103730980568
-0.103311682277
-0.102841317377
-0.102314660425
-0.101729365763
-0.10108314319
-0.100368176684
-0.0995759280054
-0.0986951684872
-0.0977159426542
-0.0966515780836
-0.0954876804141
-0.0942228089117
-0.0929039194315
-0.0908685591171
-0.0965335928112
-0.0132681964761
0.0339265155945
0.0129588712808
0.0118141516538
0.0138950702159
0.0189912732978
0.025310790623
0.0311245851532
0.0364591298374
0.0410187181902
0.0448515327557
0.0479826711766
0.0504322232495
0.0522015069714
0.0532484811393
0.0534887155797
0.0527873939798
0.0509606803723
0.0477825087648
0.0430089168382
0.0364534675838
0.0281375376626
0.0184465589028
0.00816413712234
-0.00167855189146
-0.0100734879973
-0.0162901395508
-0.020201803976
-0.0227509727665
-0.0249627557884
-0.0233268347805
-0.022402813371
-0.0215706382559
-0.0208770122781
-0.0203525707812
-0.0199704551172
-0.0196923506048
-0.0195013056607
-0.0194107622973
-0.0193026824782
-0.106345155342
-0.106349389709
-0.106344927283
-0.106336027398
-0.106319635079
-0.106295171206
-0.106262611815
-0.106222068664
-0.106173496239
-0.106116564095
-0.106050991253
-0.105979558236
-0.105903679521
-0.105816689933
-0.105711997211
-0.10558911355
-0.105449359606
-0.105290513446
-0.105107414104
-0.104899149451
-0.104662823414
-0.104390614241
-0.104081832452
-0.103732382423
-0.103341628078
-0.102904364413
-0.102412569854
-0.101863142966
-0.101254620483
-0.100583285331
-0.0998322071063
-0.0989901007083
-0.0980602534536
-0.0970415370345
-0.0959325294743
-0.0947454020738
-0.0934830381551
-0.092192322724
-0.0902413360361
-0.0962594146258
-0.00510382563228
0.0431381087805
0.0188407326826
0.0185013227491
0.0202558972346
0.0255243417488
0.0317395817696
0.0373731526945
0.0424642889418
0.046722712683
0.0502306911229
0.0530108343441
0.0550836103698
0.0564393178512
0.0570192482504
0.0567172082736
0.0553731005054
0.0527781992876
0.0486876033033
0.0428568748748
0.0351528856984
0.0257516526912
0.0152913828462
0.00482352001697
-0.00447405350622
-0.011751331937
-0.0169128291823
-0.020473197016
-0.0225957837262
-0.0220613745561
-0.0216713964939
-0.021050213584
-0.0204374821839
-0.0199121119594
-0.0195035434342
-0.0191943357436
-0.0189639371743
-0.0187780933319
-0.0186789105748
-0.0186201564351
-0.106092307212
-0.106099024769
-0.106098903015
-0.106092076228
-0.106075364883
-0.106049939872
-0.106016032263
-0.105973792719
-0.105923234877
-0.105864236124
-0.105796169964
-0.105718659326
-0.105633712923
-0.105541279729
-0.105435104289
-0.105309660919
-0.105164188283
-0.104996948897
-0.104806569122
-0.104591326106
-0.104344737094
-0.104063425958
-0.103743789845
-0.103382056594
-0.102976825273
-0.102521734603
-0.102011568637
-0.101441680889
-0.1008121166
-0.100108146155
-0.0993044809953
-0.0984173307261
-0.0974469126119
-0.096386859821
-0.0952469218598
-0.0940516849023
-0.0927923706382
-0.0915858574419
-0.0897808020931
-0.0963107757024
0.00302865061267
0.052029963475
0.0245289222992
0.0251176110901
0.0265107215742
0.0319809701224
0.0380785036788
0.0435405882352
0.0483902420843
0.0523525980526
0.0555400164351
0.0579709030032
0.0596650019898
0.0605995000624
0.0606974854306
0.0598294756818
0.0578096741026
0.0544062486076
0.0493613991395
0.0424435924308
0.0336047264472
0.0232278135457
0.0122485642081
0.00197403330757
-0.00636470738474
-0.0122530250908
-0.0167010035754
-0.0208238823371
-0.0224660951891
-0.0209606952
-0.0202904821366
-0.0197345235288
-0.0192561205041
-0.0188593509926
-0.018548046602
-0.0183078776627
-0.018126046761
-0.0179651403805
-0.017875576448
-0.0178618129585
-0.105862347661
-0.105864652063
-0.105864467453
-0.105855844828
-0.105838314463
-0.105813016877
-0.105779595469
-0.105737287949
-0.105686033621
-0.105625751098
-0.105556063402
-0.105476220997
-0.105385506435
-0.105284693822
-0.105172648363
-0.105046424957
-0.1048969847
-0.104724286077
-0.104527560629
-0.10430338859
-0.1040480241
-0.103757933513
-0.103428355937
-0.103055932346
-0.102637405399
-0.102167671736
-0.101638510424
-0.101050238386
-0.100391963468
-0.0996346456871
-0.0987897735691
-0.0978664038224
-0.0968525551018
-0.0957512870459
-0.0945847734612
-0.0933590209639
-0.0921156263088
-0.0909967622456
-0.0893147340208
-0.0966052138244
0.010924537426
0.0604823720275
0.0300129162198
0.0316347540502
0.0326334571843
0.0383426583239
0.0443131771595
0.0496157310746
0.0542276934099
0.0579011821859
0.0607737203791
0.0628585104165
0.0641733241977
0.0646802857827
0.064282743974
0.062826704365
0.0601008325654
0.0558535385617
0.0498233727611
0.0418130274809
0.0319072049268
0.0207657427838
0.00967516128242
0.000175664374838
-0.00669360573624
-0.0110946017133
-0.0150002547184
-0.0213057499555
-0.0197598036174
-0.0191867816732
-0.0187167193763
-0.0183360377236
-0.0179923454932
-0.0177088721315
-0.0174827300528
-0.0173058174582
-0.01716798293
-0.0170323284218
-0.0169700328326
-0.0169835813761
-0.105647215792
-0.105645317667
-0.105640351563
-0.105629318285
-0.105611299284
-0.105586268639
-0.105553491584
-0.105512124637
-0.1054615002
-0.105401080079
-0.105330711201
-0.105249866295
-0.105157637016
-0.105052780127
-0.104936188383
-0.104804330762
-0.104648474079
-0.104472515714
-0.104270096311
-0.104038669238
-0.103775050956
-0.103476658282
-0.103139206093
-0.102756430581
-0.10232668887
-0.101839939516
-0.101293047859
-0.100679808443
-0.0999764113999
-0.0991820911489
-0.0983067632626
-0.0973439356262
-0.0962847460789
-0.0951390528865
-0.0939166210889
-0.0926495824774
-0.0913999290984
-0.0902841675741
-0.0885827978813
-0.096613086699
0.0182731818433
0.0685083353861
0.0353450878138
0.0380406374946
0.038609721575
0.0445978278228
0.0504325903992
0.055589708183
0.059969323922
0.0633628836339
0.0659274518773
0.0676706517433
0.0686070220793
0.0686817081117
0.0677769688286
0.0657132882844
0.0622547878115
0.0571347019314
0.0500990985402
0.0410088396807
0.0301317129131
0.0184443306006
0.00754064749544
-0.00090098596992
-0.0063611775165
-0.0108429100603
-0.0155534108978
-0.0164737730763
-0.0171816456431
-0.0171958255974
-0.0170555476758
-0.0168647893965
-0.0166522019793
-0.0164700231703
-0.016319226452
-0.0161991838826
-0.0161079643928
-0.0160122665576
-0.0159714398568
-0.0159880789516
-0.105443413202
-0.105438969855
-0.105429313363
-0.105418129291
-0.105399701372
-0.105374165249
-0.10534096612
-0.105299844558
-0.105249854253
-0.105190225885
-0.10512001238
-0.105038969046
-0.104946187477
-0.10484019798
-0.104719982723
-0.104580002228
-0.104422571733
-0.104241940504
-0.104032439981
-0.103796169111
-0.103527245976
-0.103222441671
-0.102875984614
-0.102484962856
-0.102041886065
-0.101537565938
-0.100971150002
-0.100326549697
-0.0995921624382
-0.0987687693741
-0.0978612874324
-0.0968529744825
-0.0957369736258
-0.0945227480177
-0.0932269603506
-0.0919137267061
-0.0905833300367
-0.0893330802068
-0.0873069634944
-0.0960838291136
0.0250125495937
0.0763808614113
0.0406187699785
0.0443312776824
0.0444390050714
0.0507419674851
0.0564295479435
0.0614566891182
0.0656101058349
0.0687338038213
0.0709981531351
0.0724055611621
0.072965873594
0.0726055439146
0.071184340586
0.0684965092214
0.0642831539206
0.0582683655348
0.0502189640218
0.0400835475393
0.0283816574656
0.0164624159728
0.00611884924584
-0.0010677737384
-0.00490000078803
-0.00897583289141
-0.017055756711
-0.015103043115
-0.0153004813094
-0.0153844533668
-0.0154182680362
-0.0153692333865
-0.0152771661641
-0.015186610004
-0.0151050968706
-0.0150351333136
-0.0149753712266
-0.0149334411363
-0.0149250874084
-0.0149475111548
-0.105249415945
-0.105245405468
-0.105234832224
-0.105223486206
-0.105204339865
-0.105178031613
-0.105144147663
-0.105102381069
-0.105052297491
-0.104993057391
-0.10492364652
-0.104842985393
-0.104749879756
-0.104642838476
-0.104519210161
-0.104378178398
-0.104218105352
-0.104031293927
-0.103819327807
-0.103579559095
-0.103303059661
-0.102992224846
-0.102641208762
-0.102241231272
-0.101781664711
-0.101264596703
-0.100679586275
-0.100008641766
-0.0992469064947
-0.0983982104305
-0.0974507989873
-0.096379009878
-0.0951953087087
-0.0939030456012
-0.0925524782377
-0.091163747375
-0.0896948244802
-0.0882328965842
-0.0856139161879
-0.0944103656286
0.0314279148651
0.084540970493
0.0458533506555
0.0504977920346
0.0501281533165
0.0567720575804
0.0622994933128
0.0672137470928
0.0711471058715
0.0740113557948
0.0759836993004
0.0770622413489
0.0772506655854
0.0764550782545
0.0745115409524
0.0711875691682
0.0662039107314
0.0592838283183
0.0502311822515
0.0391120067605
0.026756306226
0.0148949143086
0.00529553234986
-0.00121279559901
-0.0052201633673
-0.00843574648082
-0.0108437936073
-0.0125159964262
-0.0132321164233
-0.0136047949172
-0.0138052255838
-0.0138986859132
-0.013921260238
-0.0139227119012
-0.013917288801
-0.0139090638258
-0.0138969230958
-0.0139000578295
-0.0139048768319
-0.0139096485186
-0.105071729617
-0.105067677929
-0.105057383673
-0.105044636203
-0.105024502349
-0.104997319676
-0.104962708297
-0.104920406475
-0.104869985941
-0.10481078689
-0.104742027123
-0.104662090319
-0.10456952948
-0.104462372662
-0.104338807558
-0.104196897981
-0.104032770932
-0.103844430479
-0.103630305767
-0.103382894203
-0.103104238938
-0.102792459011
-0.102433138168
-0.10201855683
-0.101553746837
-0.101027458855
-0.100419093098
-0.0997280199883
-0.0989490101012
-0.0980662114855
-0.0970605542792
-0.0959295915625
-0.0946780682997
-0.0933215079579
-0.0919001656462
-0.0904127211212
-0.0888621313324
-0.0873719933917
-0.0848643335659
-0.0940516853707
0.0388597912772
0.0931777095531
0.0509394513724
0.0565353589437
0.0556767513236
0.0626805174363
0.0680399942047
0.0728605690828
0.0765789875685
0.0791937998757
0.0808822520727
0.0816398678293
0.0814625654403
0.0802346920104
0.0777672303548
0.0738004581806
0.0680372671006
0.0602083203081
0.0501680599518
0.0381196144101
0.0252468737984
0.0136412486248
0.00491683114869
-0.00102322722461
-0.00623385437049
-0.00998291578768
-0.00971103513834
-0.0107994161514
-0.0114980876034
-0.0119668356499
-0.0122723997026
-0.0124817036481
-0.0126157998495
-0.0127107143536
-0.0127846725353
-0.0128434707452
-0.0128917331522
-0.0129233095188
-0.0129289832822
-0.0128932677001
-0.104907680316
-0.104904967639
-0.104894568679
-0.104880001142
-0.104859411023
-0.104831397464
-0.104796141242
-0.104753536525
-0.104703215341
-0.104644487542
-0.104576302376
-0.10449734438
-0.104405654176
-0.104299274933
-0.104176332125
-0.104033833111
-0.10386853452
-0.103678868334
-0.103460946947
-0.10321160615
-0.102932549778
-0.102613403754
-0.102244213547
-0.101829737564
-0.101363362265
-0.10081944838
-0.100197938937
-0.0994971025215
-0.0986921806145
-0.0977711543185
-0.0967202651379
-0.0955288030762
-0.0942016008241
-0.0927627653351
-0.0912373901226
-0.0896558985926
-0.0880828348127
-0.0867578776188
-0.0846614496362
-0.0949425211183
0.0466391015674
0.101395215348
0.0556242366858
0.0624027599535
0.0610535009809
0.068455129543
0.0736517507378
0.078398760355
0.0819051433839
0.0842791195377
0.0856910047353
0.086136324264
0.0856017943821
0.0839486298725
0.0809614155825
0.0763526741774
0.0698106565393
0.0610850218168
0.0501027396436
0.0372403267105
0.024122061193
0.0132285941726
0.00576840453357
0.000882197891622
-0.00394752124593
-0.0118461572675
-0.00919429876045
-0.00943567787179
-0.00992412301609
-0.0104114910549
-0.0108036468719
-0.0111103061772
-0.0113595477879
-0.0115469118826
-0.0116942589646
-0.011808567071
-0.0118973399163
-0.0119493183806
-0.0119775243387
-0.0119603336988
-0.104759498074
-0.104757075614
-0.104745867171
-0.104730218017
-0.104709117427
-0.104679849177
-0.104643781191
-0.104601077997
-0.104551414171
-0.104493878227
-0.104427130618
-0.104349522848
-0.104259144919
-0.104154164896
-0.104031795494
-0.103888607489
-0.103722395379
-0.103531470714
-0.103312594457
-0.103062471035
-0.102779392865
-0.102456228138
-0.102089457753
-0.101679237239
-0.101203734274
-0.100650102619
-0.100025634271
-0.0993164066711
-0.098494487949
-0.0975403357085
-0.0964360879847
-0.0951798300832
-0.0937698078101
-0.0922156278534
-0.0905537810435
-0.0888441662952
-0.0872133585408
-0.0860339065799
-0.0842501371325
-0.0962332953842
0.0535251618495
0.10842802633
0.0597258870187
0.0680018296915
0.0662071643964
0.0740929109116
0.0791428043631
0.0838330537494
0.0871258130109
0.0892644108806
0.0904050549435
0.0905471696137
0.0896667613243
0.0876006964407
0.0841055889788
0.078865596702
0.0715567998789
0.0619588582267
0.0500952974268
0.0365396118301
0.0233987704556
0.0136344280189
0.00776729614524
0.00180901398043
-0.00479750671324
-0.00518708942995
-0.00661374798224
-0.00747327446187
-0.00821252310489
-0.00883837129389
-0.0093658985553
-0.00978665996074
-0.0101419024261
-0.0104175587921
-0.0106338267723
-0.0108014361434
-0.0109261664065
-0.0109913113784
-0.0110439861106
-0.0110687975632
-0.104625087981
-0.104622976341
-0.104611854941
-0.104597120053
-0.104573429154
-0.104541927597
-0.104504760214
-0.104462527494
-0.10441459106
-0.104359469254
-0.104295312043
-0.104220071721
-0.104131635011
-0.104027752776
-0.103905503812
-0.103761466645
-0.103593616748
-0.103400720584
-0.103180490288
-0.102932285018
-0.10265116851
-0.102329752617
-0.101968337188
-0.10155858142
-0.101080746898
-0.10053074618
-0.0999091255913
-0.0991953525938
-0.0983556992973
-0.0973758262187
-0.0962380520409
-0.0949117133292
-0.0933853944905
-0.0916866049788
-0.0898339640721
-0.0878928928468
-0.0860682578364
-0.0847808940447
-0.0829206334215
-0.0966800272165
0.0590172515566
0.114310925379
0.0632774259943
0.0732895846571
0.0711480973544
0.0796290028007
0.0845358027491
0.0891729443524
0.0922411429403
0.0941430824425
0.0950137999754
0.094861468007
0.0936497445903
0.0911897320289
0.0872083018548
0.0813604477769
0.0733127660184
0.0628872117611
0.0502476543744
0.0362706306134
0.0236010024694
0.0154729615864
0.0122587494947
0.00676186795334
-0.00769871214745
-0.00418268739815
-0.00477258471623
-0.00562499504227
-0.00650363009719
-0.00727473294233
-0.00793729003128
-0.00849220107686
-0.00894239899912
-0.00929894026132
-0.00957707565098
-0.00979103959407
-0.00994376653037
-0.0100384878078
-0.0101157068345
-0.0101667042415
-0.104510138948
-0.104505376425
-0.104495819815
-0.104481325501
-0.104454490152
-0.10442288579
-0.104387423374
-0.104348524255
-0.104304357858
-0.104252560199
-0.104190811851
-0.104116850663
-0.104028446137
-0.103923309466
-0.103798187007
-0.103650072495
-0.103479304764
-0.103286253205
-0.103068664238
-0.102822638605
-0.10254307863
-0.102228707459
-0.101875694514
-0.101470040456
-0.100998013717
-0.100455685614
-0.0998427510963
-0.0991380267466
-0.0983053027216
-0.0973181642678
-0.0961346711432
-0.0947242271622
-0.093091980507
-0.0912208943439
-0.08908133141
-0.0867876674667
-0.084514397015
-0.0827338783306
-0.0803557264331
-0.0951641597527
0.0630914181106
0.119320780349
0.0663192206759
0.0783453141481
0.0760052642085
0.0851539032434
0.0898743340347
0.0944362812886
0.0972520407353
0.0989047959187
0.0995009980032
0.0990626413691
0.0975387011579
0.0947129873712
0.0902802584858
0.0838654961852
0.075129627733
0.0639478244543
0.050651264008
0.0365178190953
0.024742602593
0.0175313786261
0.0133297498151
0.0085128981608
0.00468010479014
-3.46088385755e-05
-0.00208117273888
-0.00354462580425
-0.00471753092278
-0.00571319419562
-0.00651857377093
-0.00719940165019
-0.0077463564811
-0.00817905843053
-0.00851321015597
-0.00876683396277
-0.00894236634112
-0.00907877145177
-0.00917647199956
-0.00924643355928
-0.104416281489
-0.104408731079
-0.104400504904
-0.104386683978
-0.104360753977
-0.104330623718
-0.104298821563
-0.10426412369
-0.104223035753
-0.104172602973
-0.104110511183
-0.104034569796
-0.103942750382
-0.103833097733
-0.103703290728
-0.103552362013
-0.103381615272
-0.103190184611
-0.10297499871
-0.102730896767
-0.102455666105
-0.102148182084
-0.1018020743
-0.101405939561
-0.100949676192
-0.100431293779
-0.099846600862
-0.0991639834625
-0.0983466227703
-0.0973559772704
-0.0961427423503
-0.0946910930224
-0.092965461644
-0.0908692509649
-0.0883870418718
-0.0855918619419
-0.0826005098567
-0.07985860516
-0.0764822442456
-0.0913280508228
0.065577055521
0.123289736251
0.0689566522614
0.0835092235072
0.0810501963409
0.0908031365618
0.0952156772482
0.0996407659329
0.102149447674
0.103523473171
0.103831605749
0.10311382111
0.101300756932
0.0981472983805
0.0933134442193
0.086391424689
0.0770370444736
0.0651843354731
0.0513130966572
0.0370735626619
0.0264767325979
0.020547245011
0.01309588221
0.00521545201194
0.00469690466381
0.00220220387373
8.6881322489e-05
-0.00161235774998
-0.00299925082655
-0.00416285275484
-0.00513542409312
-0.00592612697783
-0.00656848472733
-0.00707880620667
-0.00746903049587
-0.00776155613161
-0.00797063548642
-0.00813256308272
-0.00824028277225
-0.00830585336489
-0.104341803822
-0.104332847788
-0.104324117903
-0.10431008148
-0.104285816854
-0.104257842193
-0.104230983855
-0.104199303975
-0.104158819378
-0.104106932683
-0.104041918379
-0.103961887015
-0.103865311396
-0.103751431845
-0.103618585046
-0.103466873028
-0.103296886937
-0.103106586526
-0.10289265363
-0.102652427157
-0.102385076415
-0.102087324778
-0.101753000167
-0.101373219308
-0.100941874115
-0.100457151199
-0.099906721559
-0.0992597174967
-0.0984775615434
-0.0975150986407
-0.0963275614049
-0.0948781191992
-0.0930718317795
-0.0907815378752
-0.0879550876302
-0.0845630281477
-0.0805731055936
-0.0762916018973
-0.0713281640823
-0.0843306472643
0.0634410553823
0.124967603651
0.0714889251906
0.0893667460473
0.0866050681418
0.0967137459497
0.10062127703
0.104805232682
0.106920621145
0.10796770351
0.107967085321
0.106977510864
0.104907266232
0.101480380615
0.0963194052357
0.088979560869
0.0791073462619
0.0667124759294
0.0524877916256
0.0384436076997
0.029342268385
0.0263804029008
0.0192863383828
0.000744664400725
0.00531393292124
0.00394767864739
0.00209111609293
0.000237343938676
-0.00137929707228
-0.00270441292022
-0.00380911109909
-0.00471020899988
-0.00544153561746
-0.00602597756437
-0.00646984816815
-0.00680395752363
-0.00705328048593
-0.00723555233009
-0.00735864237006
-0.00741637712742
-0.104276405504
-0.104268956615
-0.104258751932
-0.104240644955
-0.104219767712
-0.104200929707
-0.104178825979
-0.104147639798
-0.104105047336
-0.104048832735
-0.103978449611
-0.103892637617
-0.103791570285
-0.10367509466
-0.103541740561
-0.103391213028
-0.103222626335
-0.103034055586
-0.102823478798
-0.102589476785
-0.102330985298
-0.102045333539
-0.101727747312
-0.101371797408
-0.100971933907
-0.100525436182
-0.100019031008
-0.0994233038919
-0.0987068252828
-0.0978251059591
-0.0967242002689
-0.0953359246076
-0.0935331454979
-0.0911683729945
-0.0880954817134
-0.0840706151208
-0.0788081068526
-0.0720686112397
-0.0636619034179
-0.0681776960895
0.0520634094744
0.125398503651
0.0761610849906
0.0970382910775
0.092985125058
0.102981260892
0.106113527399
0.10989981937
0.111497408277
0.112149784018
0.111807677622
0.110549642492
0.108254311431
0.104615866172
0.0992195388116
0.0915864640056
0.0813532862024
0.068606090228
0.05433597596
0.0410233455046
0.0327070996765
0.0281169588256
0.021635922854
0.0165290879787
0.0102840130083
0.00691991709788
0.00432325977611
0.00211110524882
0.000213932089642
-0.00133826145876
-0.00258508619603
-0.00358809200648
-0.00439713386508
-0.00505172485616
-0.00555978043474
-0.00594103071912
-0.00622296639567
-0.00641849788032
-0.0065579232458
-0.00660933631515
-0.10421699259
-0.104213413685
-0.104204001586
-0.104188809698
-0.104175932302
-0.104161474093
-0.104137938512
-0.104102363259
-0.104053302094
-0.10399066559
-0.10391572203
-0.103827519784
-0.103725682085
-0.103608940193
-0.103476138776
-0.103326502639
-0.103159159667
-0.102972804851
-0.102766410532
-0.102539634774
-0.102291792803
-0.102020697247
-0.101722465497
-0.101393411514
-0.101031207498
-0.100632028036
-0.100183326891
-0.0996630935123
-0.0990428939598
-0.098283033183
-0.097337268415
-0.0961273270201
-0.0944952630034
-0.0922693058818
-0.0892079514118
-0.0848814245457
-0.0786167906308
-0.069597797778
-0.0563324231892
-0.057626452318
0.0259030796193
0.129467978703
0.085819830705
0.106928710806
0.100215259277
0.109648317099
0.111709547391
0.11489410108
0.115831017422
0.116013760694
0.115307244249
0.113796948576
0.111334957337
0.107583861411
0.102095455906
0.0943563812313
0.0839900515108
0.0710941938991
0.056868590399
0.0446865270151
0.0381662543234
0.0287985635449
0.0174114108018
0.0163457329007
0.0127141252066
0.00925076285198
0.00632046466078
0.00382923060867
0.00170497889393
-5.83973905593e-05
-0.00147067546341
-0.00258497601776
-0.00346623789471
-0.00417433105068
-0.0047394167596
-0.00517211907698
-0.00549047292913
-0.00569288247687
-0.00584290331811
-0.00589968153315
-0.104169785129
-0.104169754977
-0.104163418238
-0.10415436132
-0.104145299154
-0.104127292295
-0.104097104017
-0.104055061498
-0.104001915642
-0.10393783241
-0.103861771158
-0.10377278457
-0.103670029229
-0.103552708327
-0.103419718545
-0.103270377992
-0.10310397243
-0.102920239336
-0.102719089312
-0.10250099128
-0.102264748324
-0.102009583503
-0.101733770325
-0.101436323075
-0.101115430137
-0.100769198422
-0.100389830771
-0.0999634341899
-0.0994703586285
-0.0988881405219
-0.0981795389716
-0.0972637895581
-0.0960124568034
-0.0942429597296
-0.091651856932
-0.0876659616239
-0.0814082783656
-0.0715096414713
-0.0560479624899
-0.0574429671158
0.0352634273295
0.16039030866
0.105028335619
0.119478752682
0.108317999615
0.116690341439
0.117246627415
0.119577940215
0.119674081072
0.119304112263
0.118178049847
0.116406832824
0.11379370858
0.109988982681
0.104514873736
0.0968536495164
0.0866603990875
0.0741319835798
0.0605688945111
0.0503788215566
0.0487657919982
0.0393368713438
0.0114534268679
0.0174160515877
0.0147808468227
0.0114417843224
0.00822893290188
0.00541032958891
0.00303528945979
0.00108254867031
-0.000486894925532
-0.00171917955239
-0.00267485785342
-0.00343239522887
-0.00403113883254
-0.00449271696801
-0.00484552157453
-0.0050724253916
-0.00522295757673
-0.00530340597007
-0.104137111251
-0.104137610436
-0.104132829001
-0.104126442135
-0.104116285493
-0.104092055258
-0.104057862487
-0.104014403232
-0.103960261933
-0.103894760053
-0.103817148093
-0.103726632942
-0.103622508006
-0.103504013044
-0.103370060258
-0.103220335588
-0.103056116645
-0.102877464126
-0.102683500031
-0.102474171517
-0.102249738666
-0.102010788548
-0.101758158898
-0.101492352192
-0.101213644471
-0.100923273718
-0.100621055978
-0.100302377086
-0.0999623757417
-0.0995978095487
-0.0991968508474
-0.0987100655927
-0.0980609293091
-0.0970978589653
-0.0955234982182
-0.0927983303638
-0.0878618830739
-0.0789375583506
-0.0614539361688
-0.0636397209621
0.0672264659594
0.208156029613
0.129204491693
0.132753937208
0.11703884774
0.123809338243
0.122589810055
0.123812761066
0.123011146402
0.122046017728
0.120557853597
0.118589644987
0.1159725807
0.112312810207
0.107153066993
0.0999566533597
0.0904381504151
0.0789252260317
0.0669437602383
0.0574664887995
0.0533123740365
0.0445143585037
0.0351880076651
0.0250305255181
0.0189676578293
0.0141484103696
0.010203770588
0.00692547510026
0.00422991647596
0.0020658729929
0.000350619111594
-0.000995620713029
-0.00202631737873
-0.00282814871741
-0.00346415914805
-0.00394837782434
-0.00431334066783
-0.00456410510349
-0.00472418892378
-0.00482087863999
-0.104112063365
-0.104111338691
-0.10410941791
-0.104104636454
-0.104091457507
-0.104063716756
-0.104028422813
-0.103983121565
-0.103927234464
-0.103859848132
-0.103780442283
-0.103688002288
-0.103582200785
-0.103461932426
-0.103327377386
-0.103179603383
-0.103020007184
-0.102846450227
-0.10265869419
-0.102456888704
-0.102243245212
-0.102019191392
-0.10178867876
-0.101552875467
-0.101314639283
-0.10107864688
-0.100854314791
-0.100647090462
-0.100469740887
-0.100344159601
-0.100297637111
-0.100335404467
-0.100459355019
-0.100601164016
-0.100633345817
-0.100174830333
-0.0983823339914
-0.0933460155151
-0.0781393546949
-0.0797998206796
0.121639694027
0.262978879473
0.149079556349
0.145475224575
0.125466435475
0.130871613168
0.127080882165
0.127103183611
0.125146990525
0.123522217597
0.121485511805
0.119215152436
0.116404851053
0.112728441523
0.107729679979
0.100994185648
0.0924188861891
0.082734040606
0.0740580213974
0.068867571603
0.0583695199974
0.0383109399948
0.0348761887295
0.02825649688
0.0220456419476
0.0165903183137
0.0120282188396
0.00828610293396
0.0052654924176
0.00288242549493
0.00102833907626
-0.000414188722514
-0.0015158159298
-0.00235315025578
-0.00301823123766
-0.00353757763957
-0.00392127537482
-0.00418248299828
-0.00434118730348
-0.00441951332925
-0.104097291819
-0.104096325629
-0.104094553285
-0.104087899792
-0.104072032461
-0.104043418323
-0.104006778454
-0.103959690532
-0.10390190972
-0.103832671191
-0.103751270864
-0.103657104961
-0.103549349787
-0.103428252058
-0.103294572936
-0.103149939326
-0.102994285054
-0.102825431184
-0.102642277345
-0.102447109825
-0.1022420013
-0.102030774831
-0.101818692796
-0.101609701793
-0.101405788974
-0.101217653461
-0.101062249565
-0.100959690102
-0.10093394735
-0.101037476366
-0.101342166502
-0.101927886415
-0.102875181818
-0.104293872006
-0.106303175056
-0.109079653659
-0.112753522942
-0.117252535841
-0.124448441678
-0.116916628734
0.17043106525
0.288554426831
0.144622307479
0.150423307579
0.130289903288
0.135795604727
0.129827316016
0.12919775488
0.126438267808
0.124481853204
0.122359675973
0.120242445813
0.117861331534
0.114911158858
0.111078709437
0.105944968026
0.0996704362118
0.0927995385926
0.0890695380081
0.0931018152735
0.0771427957984
0.0281225339626
0.036744518792
0.0309735852887
0.0246702978792
0.0186919307787
0.0135863239909
0.00940836369441
0.00607327767653
0.00349986475166
0.00153678864334
2.56705360706e-05
-0.00112968654481
-0.00200697838764
-0.00268609886308
-0.00321881013652
-0.0036199930689
-0.00389621837334
-0.0040541196999
-0.00411087745773
-0.104090677069
-0.104089966956
-0.104085074674
-0.104075782753
-0.104059502556
-0.104030406168
-0.103992732006
-0.103943607443
-0.103884009885
-0.103813390351
-0.103731089295
-0.103636017422
-0.103527418341
-0.103405923803
-0.103272379634
-0.103130006761
-0.102978174015
-0.102812665838
-0.102632925307
-0.102442715117
-0.102243154048
-0.102040201811
-0.101844284686
-0.101657922112
-0.101479295388
-0.101324810755
-0.101220304104
-0.101195870704
-0.101292049461
-0.101580462902
-0.102172485005
-0.103212568092
-0.104875984917
-0.107416791501
-0.111284825431
-0.117168094221
-0.126017582802
-0.138361622379
-0.143077411544
-0.157775910448
0.260679100566
0.293893065797
0.108571028107
0.184379395074
0.122966270864
0.148075547732
0.127516290067
0.131811174613
0.124592178496
0.123293718581
0.119240538207
0.117097633922
0.113315675105
0.109920973727
0.105162054285
0.100092760917
0.0946979717271
0.0939301261599
0.0965202993245
0.112893571813
0.106458270424
0.0737024192757
0.0481858399325
0.0358443266152
0.0273238312977
0.0204334914201
0.0147501762563
0.0102145280456
0.00662794687408
0.0038753773681
0.00185739552407
0.000343099406267
-0.000844264048413
-0.00176253651973
-0.00246289900792
-0.00300278849903
-0.00341069386555
-0.00369365058483
-0.00386554146981
-0.0039344115818
-0.104088878658
-0.104087170182
-0.104078959332
-0.104068250745
-0.104051790826
-0.104027555214
-0.103990095029
-0.10393810881
-0.103878038791
-0.103807385684
-0.103724649354
-0.103628009903
-0.103517020703
-0.103392498751
-0.103257574278
-0.103117780715
-0.102971944682
-0.102810450084
-0.102632267445
-0.102443636697
-0.102247976573
-0.102050305288
-0.101860700627
-0.10168305572
-0.101518952609
-0.101382940334
-0.101306080373
-0.101323263119
-0.101485675982
-0.101877436528
-0.102633245212
-0.103935426667
-0.106017190292
-0.109259897135
-0.114330212363
-0.122384072063
-0.135692536208
-0.147501709772
-0.164284941627
-0.343824704911
0.245610867599
0.144512935307
0.00726676188669
0.217278513694
0.0759981837527
0.16066734727
0.11073534297
0.133222214766
0.119173403561
0.12360202748
0.120105273233
0.12219661466
0.121083975078
0.123454488808
0.124425168981
0.12828410401
0.130671601306
0.13892083607
0.137846758964
0.150230480412
0.0691693507156
0.0404587534474
0.0436887776043
0.0354689998382
0.0279671085688
0.0211912207743
0.0153568647635
0.0106388623154
0.00688666454227
0.00399946512503
0.00197195170212
0.000496075209072
-0.000686369298128
-0.00162945773137
-0.00234914570331
-0.00289388850376
-0.00330241049413
-0.00359202534621
-0.00378130990107
-0.00386223879429
)
;
boundaryField
{
frontAndBack
{
type empty;
}
upperWall
{
type zeroGradient;
}
lowerWall
{
type zeroGradient;
}
inlet
{
type zeroGradient;
}
outlet
{
type adjointOutletPressurePower;
value nonuniform List<scalar>
20
(
0.0140041337604
0.0966796216503
0.138289112873
0.164299256706
0.181685612111
0.19054199928
0.192593378329
0.191772379294
0.189574882133
0.186375500334
0.182296355433
0.177386621788
0.171644893157
0.165042981787
0.157536836133
0.14905021381
0.139604316204
0.129355542199
0.119491135348
0.0937668368144
)
;
}
}
// ************************************************************************* //
| |
6314ba28c5307380cbce9b4535ce7c3b6a46ee9a | 94e8e0d10dd993cb08785d1bab6aafc1055f509d | /Master2010/Master2010/samples/S11/S11.metaprogramation.h | e7ee814b80f563061a3683e2cfe0054780e809ae | [] | no_license | albertomila/continous-formation | 1d416170d2ad85ad1e2ea5eef0f2436cd299c716 | e3a57f0fc22dc16b1e9cce1ed100795ca664359d | refs/heads/master | 2020-06-14T00:46:23.147271 | 2019-07-08T18:38:54 | 2019-07-08T18:38:54 | 194,838,856 | 0 | 0 | null | null | null | null | ISO-8859-1 | C++ | false | false | 9,184 | h | S11.metaprogramation.h | #pragma once
#include "stdafx.h"
#include <cassert>
template <bool>
struct static_assert_;
template <>
struct static_assert_ <true>
{
};
template <class T, class U>
struct meme_type
{
enum { VAL = false };
};
template <class T>
struct meme_type<T, T>
{
enum { VAL = true };
};
template <class S, class D>
class est_convertible
{
typedef __int8 oui_type;
typedef __int32 non_type;
typedef __int16 non_type16;
typedef __int64 non_type64;
//struct non_type { char _[3]; } ;
static oui_type test(D);
static non_type test(...);
static S createurBidon();
static int number();
static oui_type test2(int);
static non_type test2(float);
static non_type16 test2(long);
static non_type64 test2(...);
public:
enum { VAL = sizeof(test(createurBidon())) == sizeof(oui_type) };
enum { VAL1 = sizeof(oui_type) };
enum { VAL2 = sizeof(test(createurBidon())) };
};
///////////////////////////////////////FACTORIELLE
template <int N>
struct Factorielle
{
enum
{
VAL= N * Factorielle<N-1>::VAL
};
};
template <>
struct Factorielle<0>
{
enum
{
VAL= 1
};
};
////////////////////////////////////////STATIC ASSERT
template <class T>
void unused(const T &)
{ }
///////////////////////////////////////STATIC IF ELSE
template <bool Condition, class SiVrai, class SiFaux>
struct static_if_else;
template <class SiVrai, class SiFaux>
struct static_if_else <true, SiVrai, SiFaux>
{
typedef SiVrai type;
};
template <class SiVrai, class SiFaux>
struct static_if_else <false, SiVrai, SiFaux>
{
typedef SiFaux type;
};
/////////////////////////////////////////EST CONST
template <class T>
struct est_const
{
static const bool VAL = false;
};
template <class T>
struct est_const<const T>
{
static const bool VAL = true;
};
template <class T>
struct est_const<const T*>
{
static const bool VAL = true;
};
template <class T>
struct est_const<const T&>
{
static const bool VAL = true;
};
//////////////////////////////////////////SUPRIMER CONST
template <class T>
struct supprimer_const
{
typedef T type;
};
template <class T>
struct supprimer_const<const T>
{
typedef T type;
};
//////////////////////////////////////////SUPRIMER REF
template <class T>
struct supprimer_reference
{
typedef T type;
};
template <class T>
struct supprimer_reference<T&>
{
typedef T type;
};
//////////////////////////////////////////LISTE DE TYPES
class Vide {};
template <class T, class U>
struct type_list
{
typedef T Tete;
typedef U Queue;
};
typedef type_list <
char, type_list <
unsigned char, type_list <
signed char, type_list <
wchar_t, Vide
>
>
>
> types_caracteres;
typedef type_list <
short, type_list <
unsigned short, type_list <
int, type_list <
unsigned int, type_list <
long, type_list <
unsigned long, Vide
>
>
>
>
>
> types_entiers_numeriques;
typedef type_list <
float, type_list <
double, type_list <
long double, Vide
>
>
> types_virgule_flottante;
//////////////////////////////////////////SIZE DE LE LISTE DE TYPES
template <class>
struct static_length;
template <>
struct static_length<Vide>
{
enum { VAL = 0 };
};
template <class T, class Q>
struct static_length< type_list<T, Q> >
{
enum { VAL = 1 + static_length<Q>::VAL };
};
///////////////////////////////////////////GET TYPE BY INDEX
template <class TList, unsigned int i>
struct type_par_indice;
template <class T, class Q>
struct type_par_indice<type_list<T,Q>,0>
{
typedef T type;
};
template <class T, class Q, unsigned int i>
struct type_par_indice<type_list<T,Q>,i>
{
typedef typename
type_par_indice<Q,i-1>::type type;
};
///////////////////////////////////////////GET INDEX BY TYPE
template <class TList, class T>
struct indice_par_type;
template <class T>
struct indice_par_type<Vide, T>
{
enum { VAL = -1 };
};
template <class T, class Q>
struct indice_par_type<type_list<T, Q>, T>
{
enum { VAL = 0 };
};
template <class T, class Q, class U>
struct indice_par_type <type_list<T, Q>, U>
{
private: // constante privée, une sorte de temporaire
enum
{
pos_dans_queue = indice_par_type<Q, U>::VAL
};
public: // l'indice en tant que tel
enum
{
VAL = pos_dans_queue == -1 ? -1 : 1 + pos_dans_queue
};
};
///////////////////////////////////////////IS PRIMITIVE
template <class T>
struct est_primitif
{
static const bool VAL = indice_par_type<types_primitifs, T>::VAL != -1;
};
/////////////////////////////////////////// INSERT TYPE INTO LIST
template <class TList, class T>
struct static_insert;
template <>
struct static_insert <Vide, Vide>
{
typedef Vide type;
};
template <class T>
struct static_insert <Vide, T>
{
typedef type_list<T, Vide> type;
};
template <class T, class Q>
struct static_insert <Vide, type_list<T, Q> >
{
typedef type_list<T, Q> type;
};
template <class T, class Q, class U>
struct static_insert<type_list<T, Q>,U>
{
typedef type_list <
T, typename static_insert<Q, U>::type
> type;
};
/////////////////////////////////////////// REMOVE TYPE FROM LIST
template <class TList, class T>
struct static_remove;
template <class T>
struct static_remove<Vide, T>
{
typedef Vide type;
};
template <class T, class Q>
struct static_remove<type_list<T, Q>, T>
{
typedef Q type;
};
template <class T, class Q, class U>
struct static_remove<type_list<T, Q>, U>
{
typedef type_list<
T, typename static_remove<Q, U>::type
> type;
};
/////////////////////////////////////////// SIGNE OF TYPE CHAR
typedef
static_if_else <
(static_cast<char>(-1)<0),
char,
Vide
>::type char_signe;
typedef
static_if_else <
(static_cast<char>(-1)>=0),
char,
Vide
>::type char_non_signe;
typedef type_list <
signed char, type_list <
short , type_list <
int, type_list <
long, type_list <
char_signe, Vide
>
>
>
>
> types_entiers_signes;
/////////////////////////////////////////// CONCATENATE 2 LISTS
typedef
static_insert <
types_entiers_signes, types_virgule_flottante
>::type types_signes;
/////////////////////////////////////////// FINAL PRIMITIVE TYPE LIST
typedef
static_insert <
types_entiers_numeriques, static_insert <
types_virgule_flottante, void
>::type
>::type types_primitifs;
///////////////////////////////////////////EXAMPLE
/*
template <class T>
struct type_traits
{
static const bool est_const = ::est_const<T>::VAL;
static const bool est_volatile = ::est_volatile<T>::VAL;
static const bool est_reference = ::est_reference<T>::VAL;
static const bool est_primitif = ::est_primitif<T>::VAL;
static const bool est_entier = ::est_entier<T>::VAL;
static const bool est_virgule_flottante = ::est_virgule_flottante<T>::VAL;
static const bool est_signe = ::est_signe<T>::VAL;
static const bool est_non_signe = ::est_non_signe<T>::VAL;
private:
template <class U>
struct traits_pointeur
{
static const bool VAL = false;
typedef Vide type_pointe;
};
template <class U>
struct traits_pointeur<U*>
{
static const bool VAL = true;
typedef U type_pointe;
};
template <class U>
struct traits_pointeur_methodes
{
static const bool VAL = false;
};
template <class U, class V>
struct traits_pointeur_methodes<U V::*>
{
static const bool VAL = true;
};
public:
static const bool est_pointeur = traits_pointeur<T>::VAL;
static const bool est_pointeur_methode = traits_pointeur_methodes<T>::VAL;
typedef typename supprimer_const<T>::type type_sans_const;
typedef typename supprimer_reference<T>::type type_sans_reference;
typedef typename traits_pointeur<T>::type_pointe type_pointe;
typedef typename
static_if_else <
est_pointeur || est_pointeur_methode || est_primitif,
T,
typename
static_if_else <
!est_reference,
const type_sans_reference &,
type_sans_reference &
>::type
>::type meilleur_type_parametre;
};
*/
///////////////////////////////////////////MAIN
BEGIN_TEST(Metaprogramming)
std::cout << Factorielle<6>::VAL << std::endl;
// assert(false);
static_assert_<(sizeof(short) < sizeof(int))> short_doit_etre_plus_petit_que_int;
unused(short_doit_etre_plus_petit_que_int);
int length = static_length<types_caracteres>::VAL;
using signedChar = type_par_indice<types_caracteres,2>::type;
//type_traits<int> typetraints;
END_TEST() |
c0d046768acd6ca2806afcfc9f2973679b4d5fb2 | bf88a2c11d09070423bf0af929b764a86d7de510 | /redfish-core/lib/thermal_metrics.hpp | c127b83fa4e2486f496340666c063aff7f25c9a3 | [
"Apache-2.0"
] | permissive | sunharis/bmcweb | 1f930f07ed964f43f2d1c7d8b06a68800071a915 | 3307e047b2d8a12e3ebd4655d8dfda8594baa9e6 | refs/heads/1030 | 2023-07-08T13:54:13.843382 | 2023-05-24T13:39:38 | 2023-05-24T13:39:38 | 590,741,955 | 0 | 1 | Apache-2.0 | 2023-01-19T04:54:55 | 2023-01-19T04:54:54 | null | UTF-8 | C++ | false | false | 884 | hpp | thermal_metrics.hpp | #pragma once
#include "sensors.hpp"
namespace redfish
{
inline void requestRoutesThermalMetrics(App& app)
{
BMCWEB_ROUTE(app,
"/redfish/v1/Chassis/<str>/ThermalSubsystem/ThermalMetrics/")
.privileges({{"Login"}})
.methods(boost::beast::http::verb::get)(
[](const crow::Request&,
const std::shared_ptr<bmcweb::AsyncResp>& asyncResp,
const std::string& param) {
const std::string& chassisId = param;
auto sensorAsyncResp = std::make_shared<SensorsAsyncResp>(
asyncResp, chassisId,
sensors::dbus::paths.at(sensors::node::thermal),
sensors::node::thermal);
// TODO Need to get Chassis Redundancy information.
getThermalData(sensorAsyncResp);
});
}
} // namespace redfish |
d43b435e73f243c236ed44ce6b04dde4ce3460f2 | 0db0823d49a3dbd06994ae84de26ee02cfe41bf7 | /src/indexed.cpp | 51643a6a50b546f4332a79c4c08c6149e4479946 | [] | no_license | ChrisAichinger/boost-range-for-humans | 473fd4512cdeb715fd3f334b79866a1c387c2f48 | 7cff14659ea857f3470d6e98c8ac39fc2284045e | refs/heads/master | 2021-09-09T00:54:34.533482 | 2016-05-16T16:54:14 | 2016-05-16T16:54:14 | 58,947,744 | 2 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 1,147 | cpp | indexed.cpp | #include <iostream>
#include <string>
#include <vector>
@ifdef PIPE
@define INDEX indexed
@else
@define INDEX index
@endif
// The INDEX() implementation in Boost < 1.56 can't be recommended.
// It's clunky and doesn't work with range-based for loops.
// If you can't upgrade, grab the backported "boost-range-indexed-1.56.hpp" and
// "boost-range-traversal-1.56.hpp from this repo. They have to be included
// before other Boost Range headers.
#include "boost-range-indexed-1.56.hpp"
#include <boost/range/adaptors.hpp>
const std::string str = "beebop";
int main() {
// INDEX() is analogous to Python's enumerate(). Given a Range,
// it gives access to the elements as well as their indices.
// Boost 1.56 or higher is required for this to work properly.
//
// The (optional) parameter sets the index of the first element (default: 0)
std::cout << "Enumeration of a string" << std::endl;
for (const auto & element : CALL1(boost::adaptors::INDEX,str,0)) {
std::cout << element.index()
<< " : "
<< element.value()
<< std::endl;
}
return 0;
}
|
083c789d6877428c659cb51cf2472308fd27d822 | 4054bea96d1754b6cb5e0ac74e26822f3d997990 | /Arduino_SIH_Node_Engine_Speed_Control/Arduino_SIH_Node_Engine_Speed_Control.ino | 420c5b44daafcccbab5ae203e07539cefbc22fca | [] | no_license | Srinivasaraghavansj/Car-ECU-Simulation-System-Attempt | afc7007f8d621fc174b544a8747f2e5d06ec2cf0 | f58dad3fba687acf61cbef301dc5574f3631ae2b | refs/heads/main | 2023-06-06T19:22:56.774716 | 2021-06-21T15:09:43 | 2021-06-21T15:09:43 | 378,972,043 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 1,082 | ino | Arduino_SIH_Node_Engine_Speed_Control.ino | #include <SoftwareSerial.h>
#include <Servo.h>
Servo acc;
SoftwareSerial mySerial(10, 11); // RX, TX
int servopin = 9;
int throttle = 0;
int relaypin = 7;
bool engine = 0;
String c1 = "";
void setup() {
Serial.begin(9600);
mySerial.begin(9600);
pinMode(A0,INPUT);
pinMode(relaypin,OUTPUT);
digitalWrite(relaypin, HIGH);
acc.attach(servopin);
}
void loop() {
while (mySerial.available()) {c1 = mySerial.readStringUntil('Z'); }
engine = ((String)c1.substring(0)).toInt();
Serial.println((String)engine);
if(engine == 1) digitalWrite(relaypin, LOW);
else digitalWrite(relaypin, HIGH);
throttle = map(analogRead(A0),0,1023,0,180);
if(throttle <= 0) throttle = 0;
if(throttle >= 0)
if(throttle > 180) throttle = 180;
else throttle;
acc.write(throttle);
//Serial.println((String)throttle);
//Serial.println((String)analogRead(A0));
String s = "Z" + (String)throttle;
char buf[4];
s.toCharArray(buf, 5);
mySerial.write(buf);
Serial.println((String)buf);
delay(5);
}
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.