blob_id
stringlengths 40
40
| directory_id
stringlengths 40
40
| path
stringlengths 4
201
| content_id
stringlengths 40
40
| detected_licenses
sequencelengths 0
85
| license_type
stringclasses 2
values | repo_name
stringlengths 7
100
| snapshot_id
stringlengths 40
40
| revision_id
stringlengths 40
40
| branch_name
stringclasses 260
values | visit_date
timestamp[us] | revision_date
timestamp[us] | committer_date
timestamp[us] | github_id
int64 11.4k
681M
⌀ | star_events_count
int64 0
209k
| fork_events_count
int64 0
110k
| gha_license_id
stringclasses 17
values | gha_event_created_at
timestamp[us] | gha_created_at
timestamp[us] | gha_language
stringclasses 80
values | src_encoding
stringclasses 28
values | language
stringclasses 1
value | is_vendor
bool 1
class | is_generated
bool 2
classes | length_bytes
int64 8
9.86M
| extension
stringclasses 52
values | content
stringlengths 8
9.86M
| authors
sequencelengths 1
1
| author
stringlengths 0
119
|
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
73cf976b07116fd4aab8bc7bea00552a92c67448 | cf8ddfc720bf6451c4ef4fa01684327431db1919 | /SDK/ARKSurvivalEvolved_Buff_AoE_FoliageTrap_Fertile01_structs.hpp | 7d3b08d5699880dd27bf4e2b697ad5bc643eb19e | [
"MIT"
] | permissive | git-Charlie/ARK-SDK | 75337684b11e7b9f668da1f15e8054052a3b600f | c38ca9925309516b2093ad8c3a70ed9489e1d573 | refs/heads/master | 2023-06-20T06:30:33.550123 | 2021-07-11T13:41:45 | 2021-07-11T13:41:45 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 266 | hpp | #pragma once
// ARKSurvivalEvolved (329.9) SDK
#ifdef _MSC_VER
#pragma pack(push, 0x8)
#endif
#include "ARKSurvivalEvolved_Basic.hpp"
#include "ARKSurvivalEvolved_Buff_Base_AoE_WithDelay_classes.hpp"
namespace sdk
{
}
#ifdef _MSC_VER
#pragma pack(pop)
#endif
| [
"[email protected]"
] | |
a15a4544f6811e5712e4412be5fd0b813e239ee4 | ec06487d59db30efff373008f375be89e3deb9ac | /dbusinterface/dbustype.cpp | 14693b187fc4d9538d00a413bc3468549f390588 | [] | no_license | tsuibin/dde-desktop | 38b85e608c8e0fc83545b0e5231bd010eeb36d87 | 6d6dc34a646770449e16405d56cec216fff9a41d | refs/heads/master | 2021-01-18T09:49:46.589477 | 2016-05-27T01:37:22 | 2016-05-27T02:42:03 | 60,068,596 | 1 | 0 | null | 2016-05-31T07:44:08 | 2016-05-31T07:44:08 | null | UTF-8 | C++ | false | false | 2,099 | cpp |
#include "dbustype.h"
DesktopItemInfo::DesktopItemInfo(){
}
DesktopItemInfo::~DesktopItemInfo(){
}
void DesktopItemInfo::registerMetaType()
{
qRegisterMetaType<DesktopItemInfo>("DesktoItemInfo");
qDBusRegisterMetaType<DesktopItemInfo>();
}
QDBusArgument &operator<<(QDBusArgument &argument, const DesktopItemInfo &obj)
{
argument.beginStructure();
argument << obj.DisplayName << obj.BaseName;
argument << obj.URI << obj.MIME;
argument << obj.Icon << obj.IconName << obj.thumbnail << obj.Size;
argument << obj.FileType << obj.IsBackup << obj.IsHidden;
argument << obj.IsReadOnly << obj.IsSymlink;
argument << obj.CanDelete << obj.CanExecute;
argument << obj.CanRead << obj.CanRename;
argument << obj.CanTrash << obj.CanWrite;
argument.endStructure();
return argument;
}
const QDBusArgument &operator>>(const QDBusArgument &argument, DesktopItemInfo &obj)
{
argument.beginStructure();
argument >> obj.DisplayName >> obj.BaseName;
argument >> obj.URI >> obj.MIME;
argument >> obj.Icon >> obj.IconName >> obj.thumbnail >>obj.Size;
argument >> obj.FileType >> obj.IsBackup >> obj.IsHidden;
argument >> obj.IsReadOnly >> obj.IsSymlink;
argument >> obj.CanDelete >> obj.CanExecute;
argument >> obj.CanRead >> obj.CanRename;
argument >> obj.CanTrash >> obj.CanWrite;
argument.endStructure();
return argument;
}
ConflictInfo::ConflictInfo(){
}
ConflictInfo::~ConflictInfo(){
}
void ConflictInfo::registerMetaType()
{
qRegisterMetaType<ConflictInfo>("ConflictInfo");
qDBusRegisterMetaType<ConflictInfo>();
}
QDBusArgument &operator<<(QDBusArgument &argument, const ConflictInfo &obj)
{
argument.beginStructure();
argument << obj.code << obj.applyToAll;
argument << obj.userData;
argument.endStructure();
return argument;
}
const QDBusArgument &operator>>(const QDBusArgument &argument, ConflictInfo &obj)
{
argument.beginStructure();
argument >> obj.code >> obj.applyToAll;
argument >> obj.userData;
argument.endStructure();
return argument;
}
| [
"[email protected]"
] | |
e123b488302b2fabc4ddade994ff1c58fe2854c9 | 80a1aa8a528667fd75a7c93a1211e5f030370c9b | /YFVMprj/src/Mem/Memory.cpp | d0905a90d5db726df4da62f6f92eeb2bf8be9151 | [] | no_license | nklofy/YFVM | 7102e3f9698a1e75651d67780644cf56c37dbff1 | 5f236f015b5005da9c2075d21dfd3c52a2dc1384 | refs/heads/master | 2020-07-15T00:19:35.416941 | 2017-03-10T15:42:17 | 2017-03-10T15:42:17 | 73,872,602 | 2 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 226 | cpp | /*
* Memory.cpp
*
* Created on: Nov 19, 2016
* Author: luyunfei
*/
#include "Memory.h"
Memory::Memory() {
// TODO Auto-generated constructor stub
}
Memory::~Memory() {
// TODO Auto-generated destructor stub
}
| [
"[email protected]"
] | |
d66e664185b19c4d4d31e53e172c6fd4b9088ec5 | 0008a76e151837b35645296649ccdbca772b464b | /ImClient/ImClient/BaseMember.h | 94555b17fce8d7dcf61deb60019e3d2d3b858755 | [] | no_license | yuechuanbingzhi163/IMClient | 952add8364132f707dc3b413e780142c86926401 | 06197a859ca02fd01ba8429365be86f12dc0a879 | refs/heads/master | 2020-12-03T04:10:10.153459 | 2014-12-14T04:16:25 | 2014-12-14T04:16:25 | null | 0 | 0 | null | null | null | null | GB18030 | C++ | false | false | 1,280 | h | #pragma once
//联系人基类使用继承体系更易于扩展
#include "..\\DataStorage\LocalData.h"
#define OAMEMBERSRC "OA"
#define WCNMEMBERSRC "WCN"
#define TEMPMEMBERSRC "TEMP"
#define BASEMEMBERSRC "BASE"
class IMember
{
virtual void FromJson(const Json::Value& val) = 0;
};
//friendsinfo结构包含一个好友的信息, 不论是OA用户还是WCN用户信息都包含在这个结构中
// 可以冲设计DataStorage中数据结构
class BaseMember:public IMember
{
public:
BaseMember(void);
virtual ~BaseMember(void);
virtual LPCSTR GetMemberType();
public:
void SetTag(UINT_PTR tag);
UINT_PTR GetTag();
//void SetTag_(UINT_PTR tag_);
//UINT_PTR GetTag_();
virtual void FromJson(const Json::Value& val);
//从数据库表对应结构获取
virtual void FromFriendInfo(const friendsinfo& f);
//转化为对应的friendsinfo结构
virtual void GetFriendInfo(friendsinfo& f);
std::string m_strType;
std::string m_strMemmberSource;
std::string m_strId;
std::string m_strNickName;
std::string m_strSex;
std::string m_strPicUrl;
std::string m_strSignature;
bool m_bTempmember;
std::string m_strMobile;
std::string m_strTelephone;
std::string m_strAddress;
std::string m_strEmail;
bool m_bInit;
protected:
UINT_PTR m_pTag;
};
| [
"[email protected]"
] | |
bce8d7d3f5015ab20ceb2cc040b7fabcd4a62e3b | befcfd3f86f58cbefae1d8b4b8f978f072978b9e | /class_binding/src/myclassbind.cpp | 88e7dfd76bea94d0afbb3958f929b720ef90d3d2 | [] | no_license | sziraqui/napi_samples | 0c46abf176c5ab48eeaece081e187e3ccc322b12 | 11bdc124a2ce8ade8bf9b4ecea6b7f134a63b690 | refs/heads/master | 2020-05-30T13:30:20.710650 | 2019-06-08T18:54:51 | 2019-06-08T18:54:51 | 189,762,579 | 1 | 1 | null | null | null | null | UTF-8 | C++ | false | false | 2,548 | cpp | #include <napi.h>
#include "myclassbind.h"
Napi::FunctionReference Bind::Elog::constructor;
// Exporting class constructor and its methods
Napi::Object Bind::Elog::Init(Napi::Env env, Napi::Object exports) {
/** When passing variables from Node to C++, HandleScope manages the scope of variable created in C++
* This helps Garbage Collector to decide when to free up memory used by the created variable
* HandleScope causes the variables that are created locally to be freed up by GC.
*/
Napi::HandleScope scope = Napi::HandleScope(env);
// Define constructor for node side
// DefineClass and InstanceMethod are inherited from Napi::ObjectWrap
Napi::Function con = DefineClass(env, "Elog", {
InstanceMethod("exp", &Bind::Elog::Exp),
InstanceMethod("log", &Bind::Elog::Log)
});
//To disable C++ destructor of node side class
constructor = Napi::Persistent(con);
constructor.SuppressDestruct();
// Set key for calling constructor on node side
exports.Set("Elog", con);
return exports;
}
// Binding existing classes constructor
Bind::Elog::Elog(const Napi::CallbackInfo& info) : Napi::ObjectWrap<Bind::Elog>(info) {
Napi::Env env = info.Env();
Napi::HandleScope scope = Napi::HandleScope(env);
// Get arguments from node side
if(info.Length() < 1 || !info[0].IsNumber()) {
Napi::TypeError::New(env, "Exactly one argument as Number is expected").ThrowAsJavaScriptException();
}
Napi::Number num = info[0].As<Napi::Number>();
// Call the underlying C++ class constructor
this->elog = new ActualElog(num.DoubleValue());
}
// Binding Exp method of existing class
Napi::Value Bind::Elog::Exp(const Napi::CallbackInfo& info) {
Napi::Env env = info.Env();
Napi::EscapableHandleScope scope(env);
// There are no arguments to original method
// Executing the code from existing class
double val = this->elog->Exp(); // local variable may be deleted because of HandleScope
return scope.Escape(Napi::Number::New(env, val));
}
// Binding Log method of existing class and use of EscapableHandleScope
Napi::Value Bind::Elog::Log(const Napi::CallbackInfo& info) {
Napi::Env env = info.Env();
Napi::EscapableHandleScope scope(env); // to prevent a local variable from being GCed
// There are no arguments to method method
// Executing the code from existing class
double val = this->elog->Log();
return scope.Escape(Napi::Number::New(env, val)); // prevent val from being deleted after returning
} | [
"[email protected]"
] | |
a765552a82b474667f0163b6a22d3f0e60467686 | 0e01bc221b0284094a5efe76cdcddea52ea18a2f | /maxProfit.cpp | 9e0ad0fd8893fd736a42fef8fbbba7ecc5d5fc98 | [] | no_license | Kirthik13/LeetCode-1 | 0552895bd94469bbf48c3fd4129b960344612dcf | 6574e9edc224dbb50796096d2ae912c5dd7ee2db | refs/heads/master | 2022-12-23T00:56:27.785616 | 2020-09-30T15:13:56 | 2020-09-30T15:13:56 | 299,960,472 | 0 | 0 | null | 2020-09-30T15:13:17 | 2020-09-30T15:13:16 | null | UTF-8 | C++ | false | false | 637 | cpp | #include <iostream>
#include <vector>
class Solution
{
public:
int maxProfit(std::vector<int>& prices)
{
int n = prices.size();
if (n == 0 || n == 1)
{
return 0;
}
int res = 0;
int tmp = 0;
for (int i = 1; i < n; ++i)
{
tmp += prices[i] - prices[i-1];
if (tmp > 0)
{
res = std::max(res, tmp);
}
else
{
tmp = 0;
}
}
return res;
}
};
int main(int argc, char **argv)
{
Solution sln;
return 0;
}
| [
"[email protected]"
] | |
364c6b94a53cdd65209f2e20ea31fb1c298ebc45 | bdd9f3cdabe0c768641cf61855a6f24174735410 | /src/engine/client/application/TerrainEditor/src/win32/DialogControlPointEditor.cpp | 78cef5e1cab16987b9103776b3cdfc74343a64d1 | [] | no_license | SWG-Source/client-tools | 4452209136b376ab369b979e5c4a3464be28257b | 30ec3031184243154c3ba99cedffb2603d005343 | refs/heads/master | 2023-08-31T07:44:22.692402 | 2023-08-28T04:34:07 | 2023-08-28T04:34:07 | 159,086,319 | 15 | 47 | null | 2022-04-15T16:20:34 | 2018-11-25T23:57:31 | C++ | UTF-8 | C++ | false | false | 9,397 | cpp | //===================================================================
//
// DialogControlPointEditor.cpp
// asommers
//
// copyright 2002, sony online entertainment
//
//===================================================================
#include "FirstTerrainEditor.h"
#include "DialogControlPointEditor.h"
#include "DialogControlPointEdit.h"
//===================================================================
namespace
{
const char* const numericFormatString = "%1.2f";
}
//===================================================================
DialogControlPointEditor::DialogControlPointEditor (const ArrayList<Vector2d>& pointList) :
CDialog(DialogControlPointEditor::IDD, 0),
m_pointList (pointList.size ()),
m_heightList (0),
m_hasHeights(false)
{
//{{AFX_DATA_INIT(DialogControlPointEditor)
//}}AFX_DATA_INIT
m_pointList = pointList;
}
//-------------------------------------------------------------------
DialogControlPointEditor::DialogControlPointEditor (const ArrayList<Vector2d>& pointList, const ArrayList<float>& heightList) :
CDialog(DialogControlPointEditor::IDD, 0),
m_pointList (pointList.size ()),
m_heightList (heightList.size()),
m_hasHeights(true)
{
//{{AFX_DATA_INIT(DialogControlPointEditor)
//}}AFX_DATA_INIT
m_pointList = pointList;
m_heightList = heightList;
}
//-------------------------------------------------------------------
void DialogControlPointEditor::DoDataExchange(CDataExchange* pDX)
{
CDialog::DoDataExchange(pDX);
//{{AFX_DATA_MAP(DialogControlPointEditor)
DDX_Control(pDX, IDC_LIST_CONTROL_POINTS, m_listCtrl);
//}}AFX_DATA_MAP
}
//-------------------------------------------------------------------
BEGIN_MESSAGE_MAP(DialogControlPointEditor, CDialog)
//{{AFX_MSG_MAP(DialogControlPointEditor)
ON_BN_CLICKED(IDC_BUTTON_ADD, OnButtonAdd)
ON_BN_CLICKED(IDC_BUTTON_DELETE, OnButtonDelete)
ON_BN_CLICKED(IDC_BUTTON_DOWN, OnButtonDown)
ON_BN_CLICKED(IDC_BUTTON_UP, OnButtonUp)
ON_NOTIFY(NM_DBLCLK, IDC_LIST_CONTROL_POINTS, OnDblclkListControlPoints)
ON_BN_CLICKED(IDC_BUTTON_IMPORT_APPEND, OnButtonImportAppend)
ON_BN_CLICKED(IDC_BUTTON_IMPORT_CLEAR, OnButtonImportClear)
//}}AFX_MSG_MAP
END_MESSAGE_MAP()
//-------------------------------------------------------------------
BOOL DialogControlPointEditor::OnInitDialog()
{
CDialog::OnInitDialog();
IGNORE_RETURN (m_listCtrl.DeleteAllItems ());
IGNORE_RETURN (m_listCtrl.InsertColumn (0, "x", LVCFMT_LEFT, 80, 0));
IGNORE_RETURN (m_listCtrl.InsertColumn (1, "z", LVCFMT_LEFT, 80, 1));
if(m_hasHeights)
{
IGNORE_RETURN (m_listCtrl.InsertColumn (2,"height", LVCFMT_LEFT,80,2));
}
CString buffer;
DEBUG_FATAL(m_hasHeights && (m_pointList.size() != m_heightList.size()),("DialogControlPointEditor::OnInitDialog() - height and pointlist not the same size"));
int i;
for (i = 0; i < m_pointList.size (); ++i)
{
buffer.Format (numericFormatString, m_pointList [i].x);
IGNORE_RETURN (m_listCtrl.InsertItem (i, buffer));
buffer.Format (numericFormatString, m_pointList [i].y);
IGNORE_RETURN (m_listCtrl.SetItemText (i, 1, buffer));
if(m_hasHeights)
{
buffer.Format (numericFormatString, m_heightList[i]);
IGNORE_RETURN (m_listCtrl.SetItemText (i,2,buffer));
}
}
m_listCtrl.SetFocus ();
return FALSE; // return TRUE unless you set the focus to a control
// EXCEPTION: OCX Property Pages should return FALSE
}
//-------------------------------------------------------------------
void DialogControlPointEditor::OnButtonAdd()
{
Vector2d pointSum(0.0f,0.0f);
float heightSum = 0.0f;
if (m_pointList.size ())
{
int i;
for (i = 0; i < m_pointList.size (); ++i)
{
pointSum += m_pointList [i];
if(m_hasHeights)
{
heightSum += m_heightList[i];
}
}
pointSum /= static_cast<float> (m_pointList.size ());
if(m_hasHeights)
{
heightSum /= static_cast<float> (m_heightList.size ());
}
}
const int i = m_listCtrl.GetItemCount ();
CString buffer;
buffer.Format (numericFormatString, pointSum.x);
IGNORE_RETURN (m_listCtrl.InsertItem (i, buffer));
buffer.Format (numericFormatString, pointSum.y);
IGNORE_RETURN (m_listCtrl.SetItemText (i, 1, buffer));
if(m_hasHeights)
{
buffer.Format (numericFormatString, heightSum);
IGNORE_RETURN (m_listCtrl.SetItemText (i, 2, buffer));
}
m_listCtrl.SetItemState (i, LVIS_SELECTED | LVIS_FOCUSED, LVIS_SELECTED | LVIS_FOCUSED);
m_listCtrl.EnsureVisible (i, false);
}
//-------------------------------------------------------------------
void DialogControlPointEditor::OnButtonDelete()
{
POSITION pos = m_listCtrl.GetFirstSelectedItemPosition ();
if (pos != NULL)
{
int item = m_listCtrl.GetNextSelectedItem (pos);
m_listCtrl.DeleteItem (item);
item = max (0, item - 1);
m_listCtrl.SetItemState (item, LVIS_SELECTED | LVIS_FOCUSED, LVIS_SELECTED | LVIS_FOCUSED);
m_listCtrl.EnsureVisible (item, false);
}
}
//-------------------------------------------------------------------
void DialogControlPointEditor::OnButtonDown()
{
POSITION pos = m_listCtrl.GetFirstSelectedItemPosition ();
if (pos != NULL)
{
int item = m_listCtrl.GetNextSelectedItem (pos);
if (item < m_listCtrl.GetItemCount () - 1)
{
CString temp = m_listCtrl.GetItemText (item, 0);
m_listCtrl.SetItemText (item, 0, m_listCtrl.GetItemText (item + 1, 0));
m_listCtrl.SetItemText (item + 1, 0, temp);
temp = m_listCtrl.GetItemText (item, 1);
m_listCtrl.SetItemText (item, 1, m_listCtrl.GetItemText (item + 1, 1));
m_listCtrl.SetItemText (item + 1, 1, temp);
if(m_hasHeights)
{
temp = m_listCtrl.GetItemText (item, 2);
m_listCtrl.SetItemText (item, 2, m_listCtrl.GetItemText (item + 1, 2));
m_listCtrl.SetItemText (item + 1, 2, temp);
}
m_listCtrl.SetItemState (item + 1, LVIS_SELECTED | LVIS_FOCUSED, LVIS_SELECTED | LVIS_FOCUSED);
m_listCtrl.EnsureVisible (item + 1, false);
}
}
}
//-------------------------------------------------------------------
void DialogControlPointEditor::OnButtonUp()
{
POSITION pos = m_listCtrl.GetFirstSelectedItemPosition ();
if (pos != NULL)
{
int item = m_listCtrl.GetNextSelectedItem (pos);
if (item > 0)
{
CString temp = m_listCtrl.GetItemText (item, 0);
m_listCtrl.SetItemText (item, 0, m_listCtrl.GetItemText (item - 1, 0));
m_listCtrl.SetItemText (item - 1, 0, temp);
temp = m_listCtrl.GetItemText (item, 1);
m_listCtrl.SetItemText (item, 1, m_listCtrl.GetItemText (item - 1, 1));
m_listCtrl.SetItemText (item - 1, 1, temp);
if(m_hasHeights)
{
temp = m_listCtrl.GetItemText (item, 2);
m_listCtrl.SetItemText (item, 2, m_listCtrl.GetItemText (item - 1, 2));
m_listCtrl.SetItemText (item - 1, 2, temp);
}
m_listCtrl.SetItemState (item - 1, LVIS_SELECTED | LVIS_FOCUSED, LVIS_SELECTED | LVIS_FOCUSED);
m_listCtrl.EnsureVisible (item - 1, false);
}
}
}
//-------------------------------------------------------------------
void DialogControlPointEditor::OnButtonImportAppend()
{
}
//-------------------------------------------------------------------
void DialogControlPointEditor::OnButtonImportClear()
{
}
//-------------------------------------------------------------------
void DialogControlPointEditor::OnDblclkListControlPoints(NMHDR* /*pNMHDR*/, LRESULT* pResult)
{
POSITION pos = m_listCtrl.GetFirstSelectedItemPosition ();
if (pos != NULL)
{
const int item = m_listCtrl.GetNextSelectedItem (pos);
CString sx = m_listCtrl.GetItemText (item, 0);
CString sz = m_listCtrl.GetItemText (item, 1);
float x = static_cast<float> (atof (sx));
float z = static_cast<float> (atof (sz));
if(m_hasHeights)
{
CString sHeight = m_listCtrl.GetItemText (item, 2);
float height = static_cast<float> (atof (sHeight));
DialogControlPointEdit dlg (Vector2d (x,z),height);
if (dlg.DoModal ())
{
Vector2d point = dlg.getPoint ();
sx.Format (numericFormatString, point.x);
sz.Format (numericFormatString, point.y);
m_listCtrl.SetItemText (item, 0, sx);
m_listCtrl.SetItemText (item, 1, sz);
CString sHeight;
float height = dlg.getHeight();
sHeight.Format(numericFormatString, height);
m_listCtrl.SetItemText (item, 2, sHeight);
}
}
else
{
DialogControlPointEdit dlg (Vector2d (x, z));
if (dlg.DoModal ())
{
Vector2d point = dlg.getPoint ();
sx.Format (numericFormatString, point.x);
sz.Format (numericFormatString, point.y);
m_listCtrl.SetItemText (item, 0, sx);
m_listCtrl.SetItemText (item, 1, sz);
}
}
}
*pResult = 0;
}
//-------------------------------------------------------------------
void DialogControlPointEditor::OnOK()
{
//-- copy list ctrl to pointlist
m_pointList.clear ();
int i;
for (i = 0; i < m_listCtrl.GetItemCount (); ++i)
{
const CString sx = m_listCtrl.GetItemText (i, 0);
const CString sz = m_listCtrl.GetItemText (i, 1);
const float x = static_cast<float> (atof (sx));
const float z = static_cast<float> (atof (sz));
m_pointList.add (Vector2d (x, z));
}
if(m_hasHeights)
{
m_heightList.clear();
for (i = 0; i < m_listCtrl.GetItemCount (); ++i)
{
const CString sHeight = m_listCtrl.GetItemText (i, 2);
const float height = static_cast<float> (atof (sHeight));
m_heightList.add (height);
}
}
CDialog::OnOK();
}
//===================================================================
| [
"[email protected]"
] | |
70429f623da9a98d10b85d0038269c78840163bd | 93343c49771b6e6f2952d03df7e62e6a4ea063bb | /HDOJ/1276_autoAC.cpp | 07c1b7839ba2b45aa8757d6a90636eaafdeb766e | [] | no_license | Kiritow/OJ-Problems-Source | 5aab2c57ab5df01a520073462f5de48ad7cb5b22 | 1be36799dda7d0e60bd00448f3906b69e7c79b26 | refs/heads/master | 2022-10-21T08:55:45.581935 | 2022-09-24T06:13:47 | 2022-09-24T06:13:47 | 55,874,477 | 36 | 9 | null | 2018-07-07T00:03:15 | 2016-04-10T01:06:42 | C++ | UTF-8 | C++ | false | false | 1,220 | cpp | #include<iostream>
#include<string.h>
#include<algorithm>
#include<stdio.h>
using namespace std;
int p[5005];
int main()
{
int m,n,t,k,i;
scanf("%d",&t);
while(t--)
{
scanf("%d",&m);
for(i=1;i<=5001;i++)
{
p[i]=1;
}
n=m;
while(n>3)
{
k=0;n=0;
for(i=1;i<=m;i++)
{
if(p[i])
{
k=k+1;
if(k%2==0)
p[i]=0;
n=n+p[i];
}
}
k=0;
if(n<=3)
break;
else
n=0;
for(i=1;i<=m;i++)
{
if(p[i])
{
k=k+1;
if(k%3==0)
p[i]=0;
}
n=n+p[i];
}
}
for(i=1;i<=m;i++)
{
if(p[i])
{
if(i==1)
printf("%d",i);
else
printf(" %d",i);
}
}
printf("\n");
}
return 0;
}
| [
"[email protected]"
] | |
a1ace18830c6c6ba575c446b72ef3ee7dd0c163e | 9aeb5c20fa2713fdaa8e523fe83746cd75275aa0 | /src/engineDX7/modeler.cpp | ec18ac1cd6e63b35dc3f8fa69ad6ed2cfc0cc471 | [
"MIT",
"LicenseRef-scancode-unknown-license-reference"
] | permissive | Xynth22/Allegiance | 788db2018451a55ee56e03b8bc12895cf356449c | 2dd3602edfb669163304dc0ccbb205ab112bcd90 | refs/heads/master | 2021-01-23T10:34:55.058820 | 2017-09-07T00:45:21 | 2017-09-07T00:45:21 | 102,621,070 | 0 | 0 | null | 2017-09-06T14:47:51 | 2017-09-06T14:47:50 | null | UTF-8 | C++ | false | false | 81,744 | cpp | #include "pch.h"
// BT - STEAM
#include "FileHash.h"
#include "FileHashTable.h"
//////////////////////////////////////////////////////////////////////////////
//
// Function defined in xfile.cpp
//
//////////////////////////////////////////////////////////////////////////////
TRef<Geo> ImportXFile(Modeler* pmodeler, ZFile* pfile, Number* pnumberFrame, bool& bAnimation);
//////////////////////////////////////////////////////////////////////////////
//
// ModelerSite
//
//////////////////////////////////////////////////////////////////////////////
class ModelerSiteImpl : public ModelerSite {
public:
//
// ModelerSite members
//
void Error(const ZString& str)
{
ZError(str);
}
};
//////////////////////////////////////////////////////////////////////////////
//
// Factories
//
//////////////////////////////////////////////////////////////////////////////
class AnimatedImagePaneRectFactory : public IFunction {
private:
public:
TRef<IObject> Apply(ObjectStack& stack)
{
TRef<Image> pimage = Image::Cast((Value*)(IObject*)stack.Pop());
TRef<RectValue> prect = RectValue::Cast( (IObject*)stack.Pop());
return (Pane*)
new AnimatedImagePane(
pimage,
prect->GetValue()
);
}
};
//////////////////////////////////////////////////////////////////////////////
//
//
//
//////////////////////////////////////////////////////////////////////////////
class AnimatedImagePaneFactory : public IFunction {
private:
public:
TRef<IObject> Apply(ObjectStack& stack)
{
TRef<Image> pimage = Image::Cast((Value*)(IObject*)stack.Pop());
return (Pane*)new AnimatedImagePane(pimage);
}
};
//////////////////////////////////////////////////////////////////////////////
//
//
//
//////////////////////////////////////////////////////////////////////////////
class PaneImageFactory : public IFunction {
private:
TRef<Engine> m_pengine;
public:
PaneImageFactory(
Modeler* pmodeler
) :
m_pengine(pmodeler->GetEngine())
{
}
TRef<IObject> Apply(ObjectStack& stack)
{
TRef<Pane> ppane; CastTo(ppane, (IObject*)stack.Pop());
TRef<Boolean> pbooleanZBuffer = Boolean::Cast((IObject*)stack.Pop());
TRef<Boolean> pbooleanColorKey = Boolean::Cast((IObject*)stack.Pop());
SurfaceType stype = SurfaceType2D() | SurfaceType3D();
if (pbooleanZBuffer->GetValue()) {
stype.Set(SurfaceTypeZBuffer());
}
return (Value*)
CreatePaneImage(
m_pengine,
stype,
pbooleanColorKey->GetValue(),
ppane
);
}
};
//////////////////////////////////////////////////////////////////////////////
//
//
//
//////////////////////////////////////////////////////////////////////////////
class FrameImageButtonPaneFactory : public IFunction {
private:
TRef<Modeler> m_pmodeler;
TRef<Number> m_ptime;
public:
FrameImageButtonPaneFactory(
Modeler* pmodeler,
Number* ptime
) :
m_pmodeler(pmodeler),
m_ptime(ptime)
{
}
TRef<IObject> Apply(ObjectStack& stack)
{
StringValue* pstring = StringValue::Cast((IObject*)stack.Pop());
Number* pnumber = Number::Cast((IObject*)stack.Pop());
bool bLoop = GetBoolean((IObject*)stack.Pop());
bool bFinish = GetBoolean((IObject*)stack.Pop());
TRef<INameSpace> pns = m_pmodeler->GetNameSpace(pstring->GetValue());
TRef<ModifiableNumber> pnumberFrame; CastTo(pnumberFrame, pns->FindMember("frame"));
TRef<Image> pimage = pns->FindImage("image");
return
CreateFrameImageButtonPane(
m_ptime,
pimage,
pnumberFrame,
pnumber->GetValue(),
bLoop,
bFinish
);
}
};
//////////////////////////////////////////////////////////////////////////////
//
//
//
//////////////////////////////////////////////////////////////////////////////
class PointX : public Number {
private:
PointValue* GetPoint() { return PointValue::Cast(GetChild(0)); }
public:
PointX(PointValue* ppoint) :
Number(ppoint)
{
}
void Evaluate()
{
GetValueInternal() = GetPoint()->GetValue().X();
}
};
class PointXFactory : public IFunction {
private:
public:
TRef<IObject> Apply(ObjectStack& stack)
{
TRef<PointValue> ppoint = PointValue::Cast((IObject*)stack.Pop());
return new PointX(ppoint);
}
};
//////////////////////////////////////////////////////////////////////////////
//
//
//
//////////////////////////////////////////////////////////////////////////////
class PointY : public Number {
private:
PointValue* GetPoint() { return PointValue::Cast(GetChild(0)); }
public:
PointY(PointValue* ppoint) :
Number(ppoint)
{
}
void Evaluate()
{
GetValueInternal() = GetPoint()->GetValue().Y();
}
};
class PointYFactory : public IFunction {
private:
public:
TRef<IObject> Apply(ObjectStack& stack)
{
TRef<PointValue> ppoint = PointValue::Cast((IObject*)stack.Pop());
return new PointY(ppoint);
}
};
//////////////////////////////////////////////////////////////////////////////
//
//
//
//////////////////////////////////////////////////////////////////////////////
class ImageSize : public PointValue {
private:
Image* GetImage() { return Image::Cast(GetChild(0)); }
public:
ImageSize(Image* pimage) :
PointValue(pimage)
{
}
void Evaluate()
{
GetValueInternal() = Point::Cast(GetImage()->GetBounds().GetRect().Size());
}
};
class ImageSizeFactory : public IFunction {
private:
public:
TRef<IObject> Apply(ObjectStack& stack)
{
TRef<Image> pimage = Image::Cast((Value*)(IObject*)stack.Pop());
return new ImageSize(pimage);
}
};
//////////////////////////////////////////////////////////////////////////////
//
//
//
//////////////////////////////////////////////////////////////////////////////
class MDLFileImageFactory : public IFunction {
private:
TRef<Modeler> m_pmodeler;
public:
MDLFileImageFactory(Modeler* pmodeler) :
m_pmodeler(pmodeler)
{
}
TRef<IObject> Apply(ObjectStack& stack)
{
TRef<StringValue> pstring = StringValue::Cast((IObject*)stack.Pop());
return (Value*)
CreateMDLFileImage(
m_pmodeler,
pstring->GetValue()
);
}
};
//////////////////////////////////////////////////////////////////////////////
//
//
//
//////////////////////////////////////////////////////////////////////////////
class StringImageFactory : public IFunction {
private:
public:
TRef<IObject> Apply(ObjectStack& stack)
{
TRef<Number> pjustify = Number::Cast((IObject*)stack.Pop());
TRef<Number> pwidth = Number::Cast((IObject*)stack.Pop());
TRef<FontValue> pfont = FontValue::Cast((IObject*)stack.Pop());
TRef<ColorValue> pcolor = ColorValue::Cast((IObject*)stack.Pop());
TRef<StringValue> pstring = StringValue::Cast((IObject*)stack.Pop());
Justification justification;
justification.SetWord((DWORD)pjustify->GetValue());
return (Value*)
CreateStringImage(
justification,
pfont->GetValue(),
pcolor,
(int)pwidth->GetValue(),
pstring
);
}
};
//////////////////////////////////////////////////////////////////////////////
//
//
//
//////////////////////////////////////////////////////////////////////////////
class TextFileImageFactory : public IFunction {
private:
public:
TRef<IObject> Apply(ObjectStack& stack)
{
TRef<Number> pjustify = Number::Cast((IObject*)stack.Pop());
TRef<Number> pwidth = Number::Cast((IObject*)stack.Pop());
TRef<FontValue> pfont = FontValue::Cast((IObject*)stack.Pop());
TRef<ColorValue> pcolor = ColorValue::Cast((IObject*)stack.Pop());
TRef<StringValue> pstring = StringValue::Cast((IObject*)stack.Pop());
Justification justification;
justification.SetWord((DWORD)pjustify->GetValue());
TRef<ZFile> pfile = new ZFile(pstring->GetValue());
ZString str;
if (pfile->IsValid()) {
str = ZString((PCC)pfile->GetPointer(), pfile->GetLength());
} else {
str = "Unable to open file " + pstring->GetValue();
}
//
// remove all of the 0xd characters from the string
//
int index = 0;
while (index < str.GetLength()) {
if (str[index] == 0xd) {
str = str.Left(index) + str.Right(str.GetLength() - index - 1);
} else {
index++;
}
}
//
//
//
return (Value*)
CreateStringImage(
justification,
pfont->GetValue(),
pcolor,
(int)pwidth->GetValue(),
new StringValue(str)
);
}
};
//////////////////////////////////////////////////////////////////////////////
//
//
//
//////////////////////////////////////////////////////////////////////////////
class JustifyImageFactory : public IFunction {
private:
public:
TRef<IObject> Apply(ObjectStack& stack)
{
TRef<Image> pimage = Image::Cast((Value*)(IObject*)stack.Pop());
TRef<Number> pjustify = Number::Cast( (IObject*)stack.Pop());
Justification justification;
justification.SetWord((DWORD)pjustify->GetValue());
return (Value*)
CreateJustifyImage(
pimage,
justification
);
}
};
//////////////////////////////////////////////////////////////////////////////
//
//
//
//////////////////////////////////////////////////////////////////////////////
class GaugeImageFactory : public IFunction {
private:
public:
TRef<IObject> Apply(ObjectStack& stack)
{
TRef<Number> pjustify = Number::Cast((IObject*)stack.Pop());
TRef<Image> pimage = Image::Cast((Value*)(IObject*)stack.Pop());
TRef<Number> pnumber = Number::Cast((IObject*)stack.Pop());
Justification justification;
justification.SetWord((DWORD)pjustify->GetValue());
return
(Value*)CreateGaugeImage(
justification,
pimage,
false,
pnumber
);
}
};
//////////////////////////////////////////////////////////////////////////////
//
//
//
//////////////////////////////////////////////////////////////////////////////
class GaugeImageRectFactory : public IFunction {
private:
public:
TRef<IObject> Apply(ObjectStack& stack)
{
TRef<Number> pjustify = Number::Cast( (IObject*)stack.Pop());
TRef<Image> pimage = Image::Cast((Value*)(IObject*)stack.Pop());
TRef<RectValue> prect = RectValue::Cast( (IObject*)stack.Pop());
TRef<Boolean> pbool = Boolean::Cast( (IObject*)stack.Pop());
TRef<Number> pnumber = Number::Cast( (IObject*)stack.Pop());
Justification justification;
justification.SetWord((DWORD)pjustify->GetValue());
return
(Value*)CreateGaugeImage(
justification,
pimage,
prect->GetValue(),
pbool->GetValue(),
pnumber
);
}
};
//////////////////////////////////////////////////////////////////////////////
//
//
//
//////////////////////////////////////////////////////////////////////////////
class UndetectableImageFactory : public IFunction {
private:
public:
TRef<IObject> Apply(ObjectStack& stack)
{
TRef<Image> pimage = Image::Cast((Value*)(IObject*)stack.Pop());
return (Value*)CreateUndetectableImage(pimage);
}
};
//////////////////////////////////////////////////////////////////////////////
//
//
//
//////////////////////////////////////////////////////////////////////////////
class ClipImageFactory : public IFunction {
private:
public:
TRef<IObject> Apply(ObjectStack& stack)
{
TRef<Image> pimage = Image::Cast((Value*)(IObject*)stack.Pop());
TRef<RectValue> prect = RectValue::Cast( (IObject*)stack.Pop());
return (Value*)CreateClipImage(pimage, prect);
}
};
//////////////////////////////////////////////////////////////////////////////
//
//
//
//////////////////////////////////////////////////////////////////////////////
class PickImageFactory : public IFunction {
private:
public:
TRef<IObject> Apply(ObjectStack& stack)
{
TRef<Image> pimage = Image::Cast((Value*)(IObject*)stack.Pop());
return (Value*)CreatePickImage(pimage);
}
};
//////////////////////////////////////////////////////////////////////////////
//
//
//
//////////////////////////////////////////////////////////////////////////////
class ColorImageFactory : public IFunction {
private:
public:
TRef<IObject> Apply(ObjectStack& stack)
{
TRef<ColorValue> pcolor = ColorValue::Cast((IObject*)stack.Pop());
return (Value*)CreateColorImage(pcolor);
}
};
//////////////////////////////////////////////////////////////////////////////
//
//
//
//////////////////////////////////////////////////////////////////////////////
class ExtentImageFactory : public IFunction {
private:
public:
TRef<IObject> Apply(ObjectStack& stack)
{
TRef<RectValue> prect = RectValue::Cast((IObject*)stack.Pop());
TRef<ColorValue> pcolor = ColorValue::Cast((IObject*)stack.Pop());
return (Value*)CreateExtentImage(prect, pcolor);
}
};
//////////////////////////////////////////////////////////////////////////////
//
//
//
//////////////////////////////////////////////////////////////////////////////
/* !!! remove
class EmptyImageFactory : public IFunction {
private:
public:
TRef<IObject> Apply(ObjectStack& stack)
{
return (Value*)Image::GetEmpty();
}
};
*/
//////////////////////////////////////////////////////////////////////////////
//
//
//
//////////////////////////////////////////////////////////////////////////////
class ImportXFileFactory : public IFunction {
private:
TRef<Modeler> m_pmodeler;
public:
ImportXFileFactory(Modeler* pmodeler) :
m_pmodeler(pmodeler)
{
}
TRef<IObject> Apply(ObjectStack& stack)
{
ZString str = GetString((IObject*)stack.Pop());
TRef<Number> pnumber = Number::Cast((IObject*)stack.Pop());
bool bAnimation;
TRef<IObject> pobject = m_pmodeler->LoadXFile(str, pnumber, bAnimation);
ZAssert(pobject != NULL);
return pobject;
}
};
//////////////////////////////////////////////////////////////////////////////
//
//
//
//////////////////////////////////////////////////////////////////////////////
class ImportMDLFactory : public IFunction {
private:
TRef<Modeler> m_pmodeler;
public:
ImportMDLFactory(Modeler* pmodeler) :
m_pmodeler(pmodeler)
{
}
TRef<IObject> Apply(ObjectStack& stack)
{
ZString str = GetString((IObject*)stack.Pop());
TRef<INameSpace> pns = m_pmodeler->GetNameSpace(str);
if (pns) {
return pns->FindMember("object");
}
return NULL;
}
};
//////////////////////////////////////////////////////////////////////////////
// KGJV 32B
//
// ImportImageFromFile file factory (png,...)
//////////////////////////////////////////////////////////////////////////////
unsigned DLL_CALLCONV
myReadProc(void *buffer, unsigned size, unsigned count, fi_handle handle) {
ZFile *zf = (ZFile *)handle;
return zf->Read(buffer,size*count); // fread(buffer, size, count, (FILE *)handle);
}
//unsigned DLL_CALLCONV
//myWriteProc(void *buffer, unsigned size, unsigned count, fi_handle handle) {
// ZFile *zf = (ZFile *)handle;
// return fwrite(buffer, size, count, (FILE *)handle);
//}
int DLL_CALLCONV
mySeekProc(fi_handle handle, long offset, int origin) {
ZFile *zf = (ZFile *)handle;
return zf->Seek(offset, origin);
}
long DLL_CALLCONV
myTellProc(fi_handle handle) {
ZFile *zf = (ZFile *)handle;
return zf->Tell(); //ftell((FILE *)handle);
}
class ImportImageFromFileFactory : public IFunction {
private:
TRef<Modeler> m_pmodeler;
TRef<PrivateEngine> m_pengine;
public:
ImportImageFromFileFactory(Modeler* pmodeler) :
m_pmodeler(pmodeler)
{
CastTo(m_pengine, m_pmodeler->GetEngine());
}
TRef<IObject> Apply(ObjectStack& stack)
{
ZString str = GetString((IObject*)stack.Pop());
bool b = GetBoolean((IObject*)stack.Pop());
TRef<ZFile> zf = m_pmodeler->GetFile(str,"",true);
FreeImageIO fio;
fio.read_proc = myReadProc;
fio.seek_proc = mySeekProc;
fio.tell_proc = myTellProc;
FREE_IMAGE_FORMAT fif = FreeImage_GetFileTypeFromHandle(&fio,zf);
if (fif != FIF_UNKNOWN)
{
FIBITMAP * dib = FreeImage_LoadFromHandle(fif,&fio,zf,PNG_IGNOREGAMMA);
if (dib)
{
int bpp = FreeImage_GetBPP(dib);
assert((bpp == 16) || (bpp==24) || (bpp==32));
debugf("%s = %d bpp\n",(const char *)str,bpp);
UINT redm = FreeImage_GetRedMask(dib);
UINT grnm = FreeImage_GetGreenMask(dib);
UINT blum = FreeImage_GetBlueMask(dib);
UINT alpm = (bpp==32)?0xFF000000:0;
PixelFormat* ppf = m_pengine->GetPixelFormat(
bpp,
redm,
grnm,
blum,
alpm
);
// engine handles bitmaps mirrored ... yeeee
FreeImage_FlipHorizontal(dib);
FreeImage_FlipVertical(dib);
FreeImage_FlipHorizontal(dib);
TRef<Surface> psurface =
m_pengine->CreateSurface(
WinPoint(FreeImage_GetWidth(dib),FreeImage_GetHeight(dib)),
ppf,
NULL,
FreeImage_GetPitch(dib),
FreeImage_GetBits(dib),
zf
);
//FreeImage_Unload(dib); never free
if (b) {
// could use FreeImage_HasBackgroundColor/FreeImage_GetBackgroundColor here
// or extend MDL syntax to pass the transp color
psurface->SetColorKey(Color(0, 0, 0));
}
return (Value*)new ConstantImage(psurface, ZString());
}
}
debugf("ImportImageFromFileFactory: error reading file %s\n",(const char *)str);
return NULL;
}
};
//////////////////////////////////////////////////////////////////////////////
//
//
//
//////////////////////////////////////////////////////////////////////////////
class ImportImageFactory : public IFunction {
private:
TRef<Modeler> m_pmodeler;
TRef<PrivateEngine> m_pengine;
public:
ImportImageFactory(Modeler* pmodeler) :
m_pmodeler(pmodeler)
{
CastTo(m_pengine, m_pmodeler->GetEngine());
}
TRef<IObject> Apply(ObjectStack& stack)
{
ZString str = GetString((IObject*)stack.Pop());
bool b = GetBoolean((IObject*)stack.Pop());
TRef<Image> pimage = m_pmodeler->LoadImage(str, b);
ZAssert(pimage != NULL);
return (Value*)pimage;
}
TRef<IObject> Read(IBinaryReaderSite* psite, ObjectStack& stack)
{
#ifdef DREAMCAST
BinarySurfaceInfo bsi;
BinarySurfaceInfo* pbsi = &bsi; psite->CopyStructure(pbsi);
#else
BinarySurfaceInfo* pbsi; psite->GetStructure(pbsi);
#endif
PixelFormat* ppf =
m_pengine->GetPixelFormat(
pbsi->m_bitCount,
pbsi->m_redMask,
pbsi->m_greenMask,
pbsi->m_blueMask,
pbsi->m_alphaMask
);
BYTE* pdata = psite->GetPointer();
psite->MovePointer(pbsi->m_pitch * pbsi->m_size.Y());
TRef<Surface> psurface =
m_pengine->CreateSurface(
pbsi->m_size,
ppf,
NULL,
pbsi->m_pitch,
pdata,
psite->GetMemoryObject()
);
if (pbsi->m_bColorKey) {
psurface->SetColorKey(Color(0, 0, 0));
}
return (Value*)new ConstantImage(psurface, ZString());
}
};
//////////////////////////////////////////////////////////////////////////////
//
//
//
//////////////////////////////////////////////////////////////////////////////
class ImportFontFactory : public IFunction {
private:
TRef<Modeler> m_pmodeler;
TRef<PrivateEngine> m_pengine;
public:
ImportFontFactory(Modeler* pmodeler) :
m_pmodeler(pmodeler)
{
CastTo(m_pengine, m_pmodeler->GetEngine());
}
TRef<IObject> Apply(ObjectStack& stack)
{
ZUnimplemented();
return NULL;
}
TRef<IObject> Read(IBinaryReaderSite* psite, ObjectStack& stack)
{
return
new FontValue(
CreateEngineFont(psite)
);
}
};
//////////////////////////////////////////////////////////////////////////////
//
//
//
//////////////////////////////////////////////////////////////////////////////
class ImportImageLRFactory : public IFunction {
private:
TRef<Modeler> m_pmodeler;
TRef<PrivateEngine> m_pengine;
public:
ImportImageLRFactory(Modeler* pmodeler) :
m_pmodeler(pmodeler)
{
CastTo(m_pengine, m_pmodeler->GetEngine());
}
TRef<IObject> Apply(ObjectStack& stack)
{
ZString str = GetString((IObject*)stack.Pop());
bool b = GetBoolean((IObject*)stack.Pop());
TRef<Image> pimage = m_pmodeler->LoadImage(str, b);
const Bounds2& bounds = pimage->GetBounds();
return
(Value*)new TranslateImage(
pimage,
Point(
0,
-bounds.GetRect().YSize()
)
);
}
};
//////////////////////////////////////////////////////////////////////////////
//
//
//
//////////////////////////////////////////////////////////////////////////////
class ImportImage3DFactory : public IFunction {
private:
TRef<Modeler> m_pmodeler;
TRef<PrivateEngine> m_pengine;
public:
ImportImage3DFactory(Modeler* pmodeler) :
m_pmodeler(pmodeler)
{
CastTo(m_pengine, m_pmodeler->GetEngine());
}
TRef<IObject> Apply(ObjectStack& stack)
{
ZString str = GetString((IObject*)stack.Pop());
TRef<ColorValue> pcolor = ColorValue::Cast( (IObject*)stack.Pop());
bool b = GetBoolean((IObject*)stack.Pop());
TRef<Surface> psurface = m_pmodeler->LoadSurface(str, b);
return (Value*)CreateConstantImage3D(psurface, pcolor);
}
};
//////////////////////////////////////////////////////////////////////////////
// KGJV - Image3D - addition
// Syntax: 'Image3D(<Image>,<Color>)'
//
//////////////////////////////////////////////////////////////////////////////
class Image3DFactory : public IFunction {
private:
TRef<Modeler> m_pmodeler;
TRef<PrivateEngine> m_pengine;
public:
Image3DFactory(Modeler* pmodeler) :
m_pmodeler(pmodeler)
{
CastTo(m_pengine, m_pmodeler->GetEngine());
}
TRef<IObject> Apply(ObjectStack& stack)
{
TRef<Image> pimage = Image::Cast((Value*)(IObject*)stack.Pop());
TRef<ColorValue> pcolor = ColorValue::Cast( (IObject*)stack.Pop());
TRef<Surface> psurface = pimage->GetSurface();
return (Value*)CreateConstantImage3D(psurface, pcolor);
}
};
//////////////////////////////////////////////////////////////////////////////
//
//
//
//////////////////////////////////////////////////////////////////////////////
class BlendImageFactory : public IFunction {
private:
public:
TRef<IObject> Apply(ObjectStack& stack)
{
TRef<Image> pimage = Image::Cast((Value*)(IObject*)stack.Pop());
TRef<Number> pnumberBlend = Number::Cast( (IObject*)stack.Pop());
return
(Value*)CreateBlendImage(
pimage,
(BlendMode)(int)pnumberBlend->GetValue()
);
}
};
//////////////////////////////////////////////////////////////////////////////
//
//
//
//////////////////////////////////////////////////////////////////////////////
class TranslateImageFactory : public IFunction {
public:
TRef<IObject> Apply(ObjectStack& stack)
{
TRef<Image> pimage = Image::Cast((Value*)(IObject*)stack.Pop());
TRef<PointValue> ppoint = PointValue::Cast( (IObject*)stack.Pop());
return
(Value*)new TransformImage(
pimage,
new TranslateTransform2(ppoint)
);
}
};
//////////////////////////////////////////////////////////////////////////////
//
//
//
//////////////////////////////////////////////////////////////////////////////
class VisibleImageFactory : public IFunction {
public:
TRef<IObject> Apply(ObjectStack& stack)
{
TRef<Image> pimage = Image::Cast((Value*)(IObject*)stack.Pop());
TRef<Boolean> pbool; CastTo(pbool, (Value*)(IObject*)stack.Pop());
return (Value*)CreateVisibleImage(pimage, pbool);
}
};
//////////////////////////////////////////////////////////////////////////////
//
//
//
//////////////////////////////////////////////////////////////////////////////
class ScaleImageFactory : public IFunction {
public:
TRef<IObject> Apply(ObjectStack& stack)
{
TRef<Image> pimage = Image::Cast((Value*)(IObject*)stack.Pop());
TRef<PointValue> ppoint = PointValue::Cast( (IObject*)stack.Pop());
return
(Value*)new TransformImage(
pimage,
new ScaleTransform2(ppoint)
);
}
};
//////////////////////////////////////////////////////////////////////////////
//
//
//
//////////////////////////////////////////////////////////////////////////////
class RotateImageFactory : public IFunction {
public:
TRef<IObject> Apply(ObjectStack& stack)
{
TRef<Image> pimage = Image::Cast((Value*)(IObject*)stack.Pop());
TRef<Number> pangle = Number::Cast( (IObject*)stack.Pop());
return
(Value*)new TransformImage(
pimage,
new RotateTransform2(pangle)
);
}
};
//////////////////////////////////////////////////////////////////////////////
//
//
//
//////////////////////////////////////////////////////////////////////////////
class GeoImageFactory : public IFunction {
public:
TRef<IObject> Apply(ObjectStack& stack)
{
TRef<Geo> pgeo = Geo::Cast((Value*)(IObject*)stack.Pop());
TRef<RectValue> prect = RectValue::Cast( (IObject*)stack.Pop());
TRef<Camera> pcamera = Camera::Cast( (IObject*)stack.Pop());
TRef<Boolean> pbooleanZBuffer = Boolean::Cast( (IObject*)stack.Pop());
TRef<Viewport> pviewport = new Viewport(pcamera, prect);
return
(Value*)new GeoImage(
pgeo,
pviewport,
pbooleanZBuffer->GetValue()
);
}
};
//////////////////////////////////////////////////////////////////////////////
//
//
//
//////////////////////////////////////////////////////////////////////////////
class GeoImage2DFactory : public IFunction {
public:
TRef<IObject> Apply(ObjectStack& stack)
{
TRef<Geo> pgeo =Geo::Cast((Value*)(IObject*)stack.Pop());
return (Value*)CreateGeoImage2D(pgeo);
}
};
//////////////////////////////////////////////////////////////////////////////
//
//
//
//////////////////////////////////////////////////////////////////////////////
class ModifiableNumberFactory : public IFunction {
private:
public:
TRef<IObject> Apply(ObjectStack& stack)
{
float value = GetNumber((IObject*)stack.Pop());
return new ModifiableNumber(value);
}
};
//////////////////////////////////////////////////////////////////////////////
//
//
//
//////////////////////////////////////////////////////////////////////////////
class WrapNumberFactory : public IFunction {
private:
public:
TRef<IObject> Apply(ObjectStack& stack)
{
TRef<Number> pnumber = Number::Cast((IObject*)stack.Pop());
return new WrapNumber(pnumber);
}
};
//////////////////////////////////////////////////////////////////////////////
//
//
//
//////////////////////////////////////////////////////////////////////////////
typedef TRef<IObject> TRefIObject; //hack for VC5
template<class StaticType, class ValueType>
class TIFunctionBinary : public IFunction {
public:
TRefIObject Read(IBinaryReaderSite* psite, ObjectStack& stack)
{
#ifdef DREAMCAST
StaticType value;
StaticType* pvalue = &value; psite->CopyStructure(pvalue);
#else
StaticType* pvalue = (StaticType*)psite->GetPointer();
psite->MovePointer(sizeof(StaticType));
#endif
return new ValueType(*pvalue);
}
};
//////////////////////////////////////////////////////////////////////////////
//
//
//
//////////////////////////////////////////////////////////////////////////////
class RGBColorFactory : public TIFunctionBinary<Color, ColorValue > {
private:
public:
TRef<IObject> Apply(ObjectStack& stack)
{
float r = GetNumber((IObject*)stack.Pop());
float g = GetNumber((IObject*)stack.Pop());
float b = GetNumber((IObject*)stack.Pop());
return new ColorValue(Color(r, g, b));
}
};
//////////////////////////////////////////////////////////////////////////////
//
//
//
//////////////////////////////////////////////////////////////////////////////
class RGBAColorFactory : public TIFunctionBinary<Color, ColorValue > {
private:
public:
TRef<IObject> Apply(ObjectStack& stack)
{
float r = GetNumber((IObject*)stack.Pop());
float g = GetNumber((IObject*)stack.Pop());
float b = GetNumber((IObject*)stack.Pop());
float a = GetNumber((IObject*)stack.Pop());
return new ColorValue(Color(r, g, b, a));
}
};
//////////////////////////////////////////////////////////////////////////////
//
//
//
//////////////////////////////////////////////////////////////////////////////
class VectorFactory : public TIFunctionBinary<Vector, VectorValue > {
private:
public:
TRef<IObject> Apply(ObjectStack& stack)
{
float x = GetNumber((IObject*)stack.Pop());
float y = GetNumber((IObject*)stack.Pop());
float z = GetNumber((IObject*)stack.Pop());
return new VectorValue(Vector(x, y, z));
}
};
//////////////////////////////////////////////////////////////////////////////
//
//
//
//////////////////////////////////////////////////////////////////////////////
class PointFactory : public TIFunctionBinary<Point, PointValue > {
private:
public:
TRef<IObject> Apply(ObjectStack& stack)
{
float x = GetNumber((IObject*)stack.Pop());
float y = GetNumber((IObject*)stack.Pop());
return new PointValue(Point(x, y));
}
};
class PointV : public PointValue {
public:
PointV(Number* px, Number* py) :
PointValue(px, py)
{
}
Number* Get0() { return Number::Cast(GetChild(0)); }
Number* Get1() { return Number::Cast(GetChild(1)); }
void Evaluate()
{
GetValueInternal() =
Point(
Get0()->GetValue(),
Get1()->GetValue()
);
}
};
class PointVFactory : public TIFunctionBinary<Point, PointValue > {
public:
TRef<IObject> Apply(ObjectStack& stack)
{
Number* px; CastTo(px, (IObject*)stack.Pop());
Number* py; CastTo(py, (IObject*)stack.Pop());
return new PointV(px, py);
}
};
//////////////////////////////////////////////////////////////////////////////
//
//
//
//////////////////////////////////////////////////////////////////////////////
class RectFactory : public TIFunctionBinary<Rect, RectValue > {
private:
public:
TRef<IObject> Apply(ObjectStack& stack)
{
float xmin = GetNumber((IObject*)stack.Pop());
float ymin = GetNumber((IObject*)stack.Pop());
float xmax = GetNumber((IObject*)stack.Pop());
float ymax = GetNumber((IObject*)stack.Pop());
return new RectValue(Rect(xmin, ymin, xmax, ymax));
}
};
//////////////////////////////////////////////////////////////////////////////
//
//
//
//////////////////////////////////////////////////////////////////////////////
class MatrixTransformFactory : public TIFunctionBinary<Matrix, Transform> {
private:
public:
TRef<IObject> Apply(ObjectStack& stack)
{
float m00 = GetNumber((IObject*)stack.Pop());
float m01 = GetNumber((IObject*)stack.Pop());
float m02 = GetNumber((IObject*)stack.Pop());
float m03 = GetNumber((IObject*)stack.Pop());
float m10 = GetNumber((IObject*)stack.Pop());
float m11 = GetNumber((IObject*)stack.Pop());
float m12 = GetNumber((IObject*)stack.Pop());
float m13 = GetNumber((IObject*)stack.Pop());
float m20 = GetNumber((IObject*)stack.Pop());
float m21 = GetNumber((IObject*)stack.Pop());
float m22 = GetNumber((IObject*)stack.Pop());
float m23 = GetNumber((IObject*)stack.Pop());
float m30 = GetNumber((IObject*)stack.Pop());
float m31 = GetNumber((IObject*)stack.Pop());
float m32 = GetNumber((IObject*)stack.Pop());
float m33 = GetNumber((IObject*)stack.Pop());
return
new Transform(
Matrix(
m00, m01, m02, m03,
m10, m11, m12, m13,
m20, m21, m22, m23,
m30, m31, m32, m33
)
);
}
};
//////////////////////////////////////////////////////////////////////////////
//
//
//
//////////////////////////////////////////////////////////////////////////////
class MaterialFactory : public IFunction {
public:
TRef<IObject> Apply(ObjectStack& stack)
{
TRef<ColorValue> pcolorDiffuse = ColorValue::Cast((IObject*)stack.Pop());
TRef<ColorValue> pcolorSpecular = ColorValue::Cast((IObject*)stack.Pop());
TRef<ColorValue> pcolorEmissive = ColorValue::Cast((IObject*)stack.Pop());
TRef<Number> ppower = Number::Cast((IObject*)stack.Pop());
return
CreateMaterial(
pcolorDiffuse,
pcolorSpecular,
pcolorEmissive,
ppower
);
}
};
//////////////////////////////////////////////////////////////////////////////
//
//
//
//////////////////////////////////////////////////////////////////////////////
class TransformGeoFactory : public IFunction {
private:
public:
TRef<IObject> Apply(ObjectStack& stack)
{
TRef<Geo> pgeo = Geo::Cast((IObject*)stack.Pop());
TRef<Transform> ptrans = Transform::Cast((IObject*)stack.Pop());
return new TransformGeo(pgeo, ptrans);
}
};
//////////////////////////////////////////////////////////////////////////////
//
//
//
//////////////////////////////////////////////////////////////////////////////
class TextureGeoFactory : public IFunction {
private:
public:
TRef<IObject> Apply(ObjectStack& stack)
{
TRef<Geo> pgeo = Geo::Cast((IObject*)stack.Pop());
TRef<Image> pimage = Image::Cast((Value*)(IObject*)stack.Pop());
return new TextureGeo(pgeo, pimage);
}
};
//////////////////////////////////////////////////////////////////////////////
//
//
//
//////////////////////////////////////////////////////////////////////////////
class BlendGeoFactory : public IFunction {
private:
public:
TRef<IObject> Apply(ObjectStack& stack)
{
TRef<Geo> pgeo = Geo::Cast((IObject*)stack.Pop());
TRef<Number> pnumberBlend = Number::Cast((IObject*)stack.Pop());
return
CreateBlendGeo(
pgeo,
(BlendMode)(int)pnumberBlend->GetValue()
);
}
};
//////////////////////////////////////////////////////////////////////////////
//
//
//
//////////////////////////////////////////////////////////////////////////////
class MaterialGeoFactory : public IFunction {
private:
public:
TRef<IObject> Apply(ObjectStack& stack)
{
TRef<Geo> pgeo = Geo::Cast((IObject*)stack.Pop());
TRef<Material> pmaterial = Material::Cast((IObject*)stack.Pop());
return new MaterialGeo(pgeo, pmaterial);
}
};
//////////////////////////////////////////////////////////////////////////////
//
// Switch Value
//
//////////////////////////////////////////////////////////////////////////////
template<class StaticType>
class TSwitchValue : public TStaticValue<StaticType> {
protected:
//////////////////////////////////////////////////////////////////////////////
//
// Types
//
//////////////////////////////////////////////////////////////////////////////
typedef TStaticValue<StaticType> ValueType;
class Data {
public:
float m_number;
TRef<ValueType> m_pvalue;
};
typedef TList<Data, DefaultNoEquals> DataList;
//////////////////////////////////////////////////////////////////////////////
//
// Members
//
//////////////////////////////////////////////////////////////////////////////
DataList m_list;
TRef<ValueType> m_pdefault;
float m_number;
TStaticValue<StaticType>* GetWrappedValue() { return TStaticValue<StaticType>::Cast(GetChild(0)); }
public:
//////////////////////////////////////////////////////////////////////////////
//
// Methods
//
//////////////////////////////////////////////////////////////////////////////
TSwitchValue(ValueType* pdefault, Number* pnumber) :
TStaticValue<StaticType>(pdefault, pnumber),
m_pdefault(pdefault),
m_number(pnumber->GetValue())
{
}
Number* GetNumber() { return Number::Cast(GetChild(1)); }
//////////////////////////////////////////////////////////////////////////////
//
// SwitchImage Methods
//
//////////////////////////////////////////////////////////////////////////////
void AddValue(float number, ValueType* pvalue)
{
m_list.PushFront();
m_list.GetFront().m_number = number;
m_list.GetFront().m_pvalue = pvalue;
if (m_number == number) {
pvalue->Update();
SetChild(0, pvalue);
}
}
//////////////////////////////////////////////////////////////////////////////
//
// Value Methods
//
//////////////////////////////////////////////////////////////////////////////
void Evaluate()
{
float number = GetNumber()->GetValue();
if (m_number != number) {
m_number = number;
DataList::Iterator iter(m_list);
while (true) {
if (iter.End()) {
m_pdefault->Update();
SetChild(0, m_pdefault);
break;
}
const Data& data = iter.Value();
if (data.m_number == number) {
data.m_pvalue->Update();
SetChild(0, data.m_pvalue);
break;
}
iter.Next();
}
}
GetValueInternal() = GetWrappedValue()->GetValue();
}
};
//////////////////////////////////////////////////////////////////////////////
//
// Switch Value Factory
//
//////////////////////////////////////////////////////////////////////////////
template<class StaticType>
class TSwitchFactory : public IFunction {
private:
typedef TStaticValue<StaticType> ValueType;
typedef TSwitchValue<StaticType> SwitchType;
public:
TRef<IObject> Apply(ObjectStack& stack)
{
TRef<Number> pnumber; CastTo(pnumber, (IObject*)stack.Pop());
TRef<ValueType> pvalue; CastTo(pvalue, (Value*)(IObject*)stack.Pop());
TRef<IObjectList> plist; CastTo(plist, (IObject*)stack.Pop());
TRef<SwitchType> pswitch = new SwitchType(pvalue, pnumber);
IObjectPair* ppair; CastTo(ppair, plist->GetFirst());
while (ppair) {
TRef<Number> pnumber; CastTo(pnumber, ppair->GetFirst() );
TRef<ValueType> pimage; CastTo(pvalue, ppair->GetSecond());
pswitch->AddValue(
pnumber->GetValue(),
pvalue
);
CastTo(ppair, plist->GetNext());
}
return (Value*)pswitch;
}
};
//////////////////////////////////////////////////////////////////////////////
//
//
//
//////////////////////////////////////////////////////////////////////////////
class SwitchImageFactory : public IFunction {
private:
public:
TRef<IObject> Apply(ObjectStack& stack)
{
TRef<Number> pnumber; CastTo(pnumber, (IObject*)stack.Pop());
TRef<Image> pimage; CastTo(pimage, (Value*)(IObject*)stack.Pop());
TRef<IObjectList> plist; CastTo(plist, (IObject*)stack.Pop());
TRef<SwitchImage> pswitch = CreateSwitchImage(pnumber, pimage);
IObjectPair* ppair; CastTo(ppair, plist->GetFirst());
while (ppair) {
float number = GetNumber( ppair->GetFirst());
TRef<Image> pimage = Image::Cast((Value*)ppair->GetSecond());
pswitch->AddImage(number, pimage);
CastTo(ppair, plist->GetNext());
}
return (Value*)pswitch;
}
};
//////////////////////////////////////////////////////////////////////////////
//
//
//
//////////////////////////////////////////////////////////////////////////////
class GroupImageFactory : public IFunction {
private:
public:
TRef<IObject> Apply(ObjectStack& stack)
{
TRef<GroupImage> pgroup = new GroupImage();
TRef<IObjectList> plist; CastTo(plist, (IObject*)stack.Pop());
plist->GetFirst();
while (plist->GetCurrent() != NULL) {
pgroup->AddImage(Image::Cast((Value*)plist->GetCurrent()));
plist->GetNext();
}
return (Value*)pgroup;
}
};
//////////////////////////////////////////////////////////////////////////////
//
//
//
//////////////////////////////////////////////////////////////////////////////
class GroupGeoFactory : public IFunction {
private:
public:
TRef<IObject> Apply(ObjectStack& stack)
{
TRef<GroupGeo> pgroup = GroupGeo::Create();
TRef<IObjectList> plist; CastTo(plist, (IObject*)stack.Pop());
plist->GetFirst();
while (plist->GetCurrent() != NULL) {
pgroup->AddGeo(Geo::Cast(plist->GetCurrent()));
plist->GetNext();
}
return pgroup;
}
};
//////////////////////////////////////////////////////////////////////////////
//
//
//
//////////////////////////////////////////////////////////////////////////////
class MeshGeoFactory : public IFunction {
private:
public:
TRef<IObject> Apply(ObjectStack& stack)
{
TRef<IObjectList> plistVertices; CastTo(plistVertices, (IObject*)stack.Pop());
TRef<IObjectList> plistIndices; CastTo(plistIndices, (IObject*)stack.Pop() );
TVector<Vertex> vertices;
TVector<WORD> indices;
plistVertices->GetFirst();
while (plistVertices->GetCurrent() != NULL) {
float x = GetNumber(plistVertices->GetCurrent());
float y = GetNumber(plistVertices->GetNext());
float z = GetNumber(plistVertices->GetNext());
float nx = GetNumber(plistVertices->GetNext());
float ny = GetNumber(plistVertices->GetNext());
float nz = GetNumber(plistVertices->GetNext());
float tx = GetNumber(plistVertices->GetNext());
float ty = GetNumber(plistVertices->GetNext());
vertices.PushEnd(Vertex(x, y, z, nx, ny, nz, tx,ty));
plistVertices->GetNext();
}
plistIndices->GetFirst();
while (plistIndices->GetCurrent() != NULL) {
indices.PushEnd((WORD)GetNumber(plistIndices->GetCurrent()));
plistIndices->GetNext();
}
return Geo::CreateMesh(vertices, indices);
}
#ifdef DREAMCAST
#if 0
class MeshDataCopy : public IObject
{
public:
MeshDataCopy(Vertex* pvertex, DWORD countVertices, WORD* pindex, DWORD countIndices)
{
Vertex* pvertexCopy = (Vertex*)malloc(countVertices * sizeof(Vertex));
memcpy(pvertexCopy, pvertex, countVertices * sizeof(Vertex));
m_pvertex = new D3DVertex[countVertices];
for (int i = 0; i < countVertices; i++)
{
m_pvertex[i].SetPosition(pvertexCopy[i].GetPosition());
m_pvertex[i].SetTextureCoordinate(pvertexCopy[i].GetTextureCoordinate());
m_pvertex[i].SetNormal(pvertexCopy[i].GetNormal());
}
free(pvertexCopy);
m_pindex = (WORD*)malloc(countIndices * sizeof(WORD));
memcpy(m_pindex, pindex, countIndices * sizeof(WORD));
}
~MeshDataCopy()
{
delete m_pvertex;
free(m_pindex);
}
D3DVertex* m_pvertex;
WORD* m_pindex;
};
TRef<IObject> Read(IBinaryReaderSite* psite, ObjectStack& stack)
{
DWORD countVertices = psite->GetDWORD();
DWORD countIndices = psite->GetDWORD();
Vertex* pvertex = (Vertex*)psite->GetPointer();
psite->MovePointer(countVertices * sizeof(Vertex));
WORD* pindex = (WORD*)psite->GetPointer();
psite->MovePointer(countIndices * sizeof(WORD));
TRef<MeshDataCopy> pdata = new MeshDataCopy(pvertex, countVertices, pindex, countIndices);
return
Geo::CreateMesh(
pdata->m_pvertex,
countVertices,
pdata->m_pindex,
countIndices,
pdata
);
}
#endif
#if 1
class MeshDataCopy : public IObject
{
public:
MeshDataCopy(Vertex* pvertex, DWORD countVertices, WORD* pindex,
DWORD countIndices)
{
m_pvertex = (Vertex*)malloc(countVertices * sizeof(Vertex));
memcpy(m_pvertex, pvertex, countVertices * sizeof(Vertex));
m_pindex = (WORD*)malloc(countIndices * sizeof(WORD));
memcpy(m_pindex, pindex, countIndices * sizeof(WORD));
}
~MeshDataCopy()
{
free(m_pvertex);
free(m_pindex);
}
Vertex* m_pvertex;
WORD* m_pindex;
};
TRef<IObject> Read(IBinaryReaderSite* psite, ObjectStack& stack)
{
DWORD countVertices = psite->GetDWORD();
DWORD countIndices = psite->GetDWORD();
Vertex* pvertex = (Vertex*)psite->GetPointer();
psite->MovePointer(countVertices * sizeof(Vertex));
WORD* pindex = (WORD*)psite->GetPointer();
psite->MovePointer(countIndices * sizeof(WORD));
TRef<MeshDataCopy> pdata = new MeshDataCopy(pvertex, countVertices,
pindex, countIndices);
return
Geo::CreateMesh(
pdata->m_pvertex,
countVertices,
pdata->m_pindex,
countIndices,
pdata
);
}
#endif
#else
TRef<IObject> Read(IBinaryReaderSite* psite, ObjectStack& stack)
{
DWORD countVertices = psite->GetDWORD();
DWORD countIndices = psite->GetDWORD();
Vertex* pvertex = (Vertex*)psite->GetPointer();
psite->MovePointer(countVertices * sizeof(Vertex));
WORD* pindex = (WORD*)psite->GetPointer();
psite->MovePointer(countIndices * sizeof(WORD));
return
Geo::CreateMesh(
pvertex,
countVertices,
pindex,
countIndices,
psite->GetMemoryObject()
);
}
#endif
};
//////////////////////////////////////////////////////////////////////////////
//
//
//
//////////////////////////////////////////////////////////////////////////////
class LODGeoFactory : public IFunction {
private:
public:
TRef<IObject> Apply(ObjectStack& stack)
{
TRef<Geo> pgeo; CastTo(pgeo, (IObject*)stack.Pop());
TRef<IObjectList> plistLOD; CastTo(plistLOD, (IObject*)stack.Pop());
TRef<LODGeo> plodGeo = LODGeo::Create(pgeo);
IObjectPair* ppair; CastTo(ppair, plistLOD->GetFirst());
while (ppair) {
float pixels = GetNumber(ppair->GetFirst());
TRef<Geo> pgeoLOD = Geo::Cast(ppair->GetSecond());
plodGeo->AddGeo(pgeoLOD, pixels);
CastTo(ppair, plistLOD->GetNext());
}
return plodGeo;
}
};
//////////////////////////////////////////////////////////////////////////////
//
//
//
//////////////////////////////////////////////////////////////////////////////
class KeyFramedTranslateFactory : public IFunction {
private:
public:
TRef<IObject> Apply(ObjectStack& stack)
{
TRef<IObjectList> plist; CastTo(plist, (IObject*)stack.Pop());
TRef<Number> pframe; CastTo(pframe, (IObject*)stack.Pop());
TRef<KeyFramedTranslateTransform> ptrans = CreateKeyFramedTranslateTransform(pframe);
plist->GetFirst();
while (plist->GetCurrent() != NULL) {
float time = GetNumber(plist->GetCurrent());
float x = GetNumber(plist->GetNext());
float y = GetNumber(plist->GetNext());
float z = GetNumber(plist->GetNext());
ptrans->AddKey(time, Vector(x, y, z));
plist->GetNext();
}
return ptrans;
}
};
//////////////////////////////////////////////////////////////////////////////
//
//
//
//////////////////////////////////////////////////////////////////////////////
class ScaleFactory : public IFunction {
private:
public:
TRef<IObject> Apply(ObjectStack& stack)
{
TRef<Number> pscale = Number::Cast((IObject*)stack.Pop());
return new ScaleTransform(pscale->GetValue());
}
};
//////////////////////////////////////////////////////////////////////////////
//
//
//
//////////////////////////////////////////////////////////////////////////////
class TranslateFactory : public IFunction {
private:
public:
TRef<IObject> Apply(ObjectStack& stack)
{
TRef<VectorValue> pvector = VectorValue::Cast((IObject*)stack.Pop());
return new TranslateTransform(pvector->GetValue());
}
};
//////////////////////////////////////////////////////////////////////////////
//
//
//
//////////////////////////////////////////////////////////////////////////////
class RotateFactory : public IFunction {
private:
public:
TRef<IObject> Apply(ObjectStack& stack)
{
TRef<VectorValue> pvector = VectorValue::Cast((IObject*)stack.Pop());
TRef<Number> pangle = Number::Cast((IObject*)stack.Pop());
return
new RotateTransform(
pvector->GetValue(),
pangle->GetValue()
);
}
};
//////////////////////////////////////////////////////////////////////////////
//
//
//
//////////////////////////////////////////////////////////////////////////////
class KeyFramedScaleFactory : public IFunction {
private:
public:
TRef<IObject> Apply(ObjectStack& stack)
{
TRef<IObjectList> plist; CastTo(plist, (IObject*)stack.Pop());
TRef<Number> pframe; CastTo(pframe, (IObject*)stack.Pop());
TRef<KeyFramedScaleTransform> ptrans = CreateKeyFramedScaleTransform(pframe);
plist->GetFirst();
while (plist->GetCurrent() != NULL) {
float time = GetNumber(plist->GetCurrent());
float x = GetNumber(plist->GetNext());
float y = GetNumber(plist->GetNext());
float z = GetNumber(plist->GetNext());
ptrans->AddKey(time, Vector(x, y, z));
plist->GetNext();
}
return ptrans;
}
};
//////////////////////////////////////////////////////////////////////////////
//
//
//
//////////////////////////////////////////////////////////////////////////////
class KeyFramedRotateFactory : public IFunction {
private:
public:
TRef<IObject> Apply(ObjectStack& stack)
{
TRef<IObjectList> plist; CastTo(plist, (IObject*)stack.Pop());
TRef<Number> pframe; CastTo(pframe, (IObject*)stack.Pop());
TRef<KeyFramedRotateTransform> ptrans = CreateKeyFramedRotateTransform(pframe);
plist->GetFirst();
while (plist->GetCurrent() != NULL) {
float time = GetNumber(plist->GetCurrent());
float s = GetNumber(plist->GetNext());
float x = GetNumber(plist->GetNext());
float y = GetNumber(plist->GetNext());
float z = GetNumber(plist->GetNext());
ptrans->AddKey(time, Quaternion(s, x, y, z));
plist->GetNext();
}
return ptrans;
}
};
// Camera
// KGJV addition
class CameraFactory : public IFunction {
public:
TRef<IObject> Apply(ObjectStack& stack)
{
TRef<Number> znear = Number::Cast((IObject*)stack.Pop());
TRef<Number> zfar = Number::Cast((Value*)(IObject*)stack.Pop());
TRef<Number> fov = Number::Cast((Value*)(IObject*)stack.Pop());
TRef<VectorValue> pvector = VectorValue::Cast((IObject*)stack.Pop());
TRef<Camera> pcam = new Camera();
pcam->SetZClip(znear->GetValue(),zfar->GetValue());
pcam->SetFOV(RadiansFromDegrees(fov->GetValue()));
pcam->SetPosition(pvector->GetValue());
return pcam;
}
};
//////////////////////////////////////////////////////////////////////////////
//
//
//
//////////////////////////////////////////////////////////////////////////////
class Win32FontFactory : public IFunction {
private:
Engine* m_pengine;
public:
Win32FontFactory(Engine* pengine) :
m_pengine(pengine)
{
}
TRef<IObject> Apply(ObjectStack& stack)
{
TRef<StringValue> pstringName; CastTo(pstringName, (IObject*)stack.Pop());
TRef<Number> pnumberSize; CastTo(pnumberSize, (IObject*)stack.Pop());
TRef<Boolean> pboolBold; CastTo(pboolBold, (IObject*)stack.Pop());
TRef<Number> pnumberStretch; CastTo(pnumberStretch, (IObject*)stack.Pop());
return
new FontValue(
CreateEngineFont(
CreateFont(
(int)pnumberSize->GetValue(),
(int)pnumberStretch->GetValue(),0, 0,
pboolBold->GetValue() ? FW_BOLD : FW_DONTCARE,
FALSE, FALSE, FALSE, ANSI_CHARSET,
OUT_DEFAULT_PRECIS, CLIP_DEFAULT_PRECIS,
DEFAULT_QUALITY, DEFAULT_PITCH | FF_MODERN,
pstringName->GetValue()
)
)
);
}
};
//////////////////////////////////////////////////////////////////////////////
//
// Numbers
//
//////////////////////////////////////////////////////////////////////////////
class ModFactory : public IFunction {
public:
TRef<IObject> Apply(ObjectStack& stack)
{
TRef<Number> pnumber1; CastTo(pnumber1, (IObject*)stack.Pop());
TRef<Number> pnumber2; CastTo(pnumber2, (IObject*)stack.Pop());
return Mod(pnumber1, pnumber2);
}
};
class MinFactory : public IFunction {
public:
TRef<IObject> Apply(ObjectStack& stack)
{
TRef<Number> pnumber1; CastTo(pnumber1, (IObject*)stack.Pop());
TRef<Number> pnumber2; CastTo(pnumber2, (IObject*)stack.Pop());
return Min(pnumber1, pnumber2);
}
};
class MaxFactory : public IFunction {
public:
TRef<IObject> Apply(ObjectStack& stack)
{
TRef<Number> pnumber1; CastTo(pnumber1, (IObject*)stack.Pop());
TRef<Number> pnumber2; CastTo(pnumber2, (IObject*)stack.Pop());
return Max(pnumber1, pnumber2);
}
};
class AddFactory : public IFunction {
public:
TRef<IObject> Apply(ObjectStack& stack)
{
TRef<Number> pnumber1; CastTo(pnumber1, (IObject*)stack.Pop());
TRef<Number> pnumber2; CastTo(pnumber2, (IObject*)stack.Pop());
return Add(pnumber1, pnumber2);
}
};
class SubtractFactory : public IFunction {
public:
TRef<IObject> Apply(ObjectStack& stack)
{
TRef<Number> pnumber1; CastTo(pnumber1, (IObject*)stack.Pop());
TRef<Number> pnumber2; CastTo(pnumber2, (IObject*)stack.Pop());
return Subtract(pnumber1, pnumber2);
}
};
class MultiplyFactory : public IFunction {
public:
TRef<IObject> Apply(ObjectStack& stack)
{
TRef<Number> pnumber1; CastTo(pnumber1, (IObject*)stack.Pop());
TRef<Number> pnumber2; CastTo(pnumber2, (IObject*)stack.Pop());
return Multiply(pnumber1, pnumber2);
}
};
class DivideFactory : public IFunction {
public:
TRef<IObject> Apply(ObjectStack& stack)
{
TRef<Number> pnumber1; CastTo(pnumber1, (IObject*)stack.Pop());
TRef<Number> pnumber2; CastTo(pnumber2, (IObject*)stack.Pop());
return Divide(pnumber1, pnumber2);
}
};
//////////////////////////////////////////////////////////////////////////////
//
// NumberString
//
//////////////////////////////////////////////////////////////////////////////
class NumberString : public StringValue {
public:
NumberString(Number* pvalue) :
StringValue(pvalue)
{
}
Number* GetNumber() { return Number::Cast(GetChild(0)); }
void Evaluate()
{
GetValueInternal() = (int)(GetNumber()->GetValue() + 0.5);
}
ZString GetFunctionName() { return "NumberString"; }
};
class NumberStringFactory : public IFunction {
public:
TRef<IObject> Apply(ObjectStack& stack)
{
TRef<Number> pnumber; CastTo(pnumber, (IObject*)stack.Pop());
return new NumberString(pnumber);
}
};
//////////////////////////////////////////////////////////////////////////////
//
// RealNumberString
//
//////////////////////////////////////////////////////////////////////////////
class RealNumberString : public StringValue {
public:
RealNumberString(Number* pvalue) :
StringValue(pvalue)
{
}
Number* GetNumber() { return Number::Cast(GetChild(0)); }
void Evaluate()
{
char cbTemp[80];
sprintf(cbTemp, "%.2g", (double)GetNumber()->GetValue());
GetValueInternal() = cbTemp;
}
ZString GetFunctionName() { return "RealNumberString"; }
};
class RealNumberStringFactory : public IFunction {
public:
TRef<IObject> Apply(ObjectStack& stack)
{
TRef<Number> pnumber; CastTo(pnumber, (IObject*)stack.Pop());
return new RealNumberString(pnumber);
}
};
//////////////////////////////////////////////////////////////////////////////
//
// ConcatinatedString
//
//////////////////////////////////////////////////////////////////////////////
class ConcatinatedString : public StringValue {
public:
ConcatinatedString(StringValue* pvalue1, StringValue* pvalue2) :
StringValue(pvalue1, pvalue2)
{
}
void Evaluate()
{
GetValueInternal() = ((StringValue*)GetChild(0))->GetValue()
+ ((StringValue*)GetChild(1))->GetValue();
}
ZString GetFunctionName() { return "ConcatinatedString"; }
};
class ConcatinatedStringFactory : public IFunction {
public:
TRef<IObject> Apply(ObjectStack& stack)
{
TRef<StringValue> pstring1; CastTo(pstring1, (IObject*)stack.Pop());
TRef<StringValue> pstring2; CastTo(pstring2, (IObject*)stack.Pop());
return new ConcatinatedString(pstring1, pstring2);
}
};
//////////////////////////////////////////////////////////////////////////////
//
// Modeler
//
//////////////////////////////////////////////////////////////////////////////
class ModelerImpl : public Modeler
{
private:
TRef<Engine> m_pengine;
TRef<ModelerSite> m_psite;
PathString m_pathStr;
// BT - STEAM
FileHashTable m_fileHashTable;
TMap<ZString, TRef<INameSpace> > m_mapNameSpace;
public:
ModelerImpl(Engine* pengine) :
m_pengine(pengine),
m_pathStr(".")
{
m_psite = new ModelerSiteImpl();
InitializeNameSpace();
}
void SetSite(ModelerSite* psite)
{
m_psite = psite;
}
void SetArtPath(const PathString& pathStr)
{
m_pathStr = pathStr;
}
ZString GetArtPath()
{
return m_pathStr;
}
void Terminate()
{
m_mapNameSpace.SetEmpty();
m_pengine = NULL;
m_psite = NULL;
}
void InitializeNameSpace()
{
INameSpace* pns = CreateNameSpace("model");
//
// Types
//
pns->AddType("Number" , new TBaseMDLType<float >("float" , ZString()));
pns->AddType("Boolean" , new TBaseMDLType<bool >("bool" , "b" ));
pns->AddType("Color" , new TBaseMDLType<Color >("Color" , "color" ));
pns->AddType("Point" , new TBaseMDLType<Point >("Point" , "point" ));
pns->AddType("Vector" , new TBaseMDLType<Vector >("Vector" , "vec" ));
pns->AddType("Rect" , new TBaseMDLType<Rect >("Rect" , "rect" ));
pns->AddType("Orientation", new TBaseMDLType<Orientation>("Orientation", "orient" ));
pns->AddType("String" , CreateStringMDLType() );
pns->AddType("Image" , CreateIObjectMDLType("Image", "image") );
pns->AddType("Geo" , CreateIObjectMDLType("Geo" , "Geo" ) );
//
// built in values
//
TRef<Number> ptime = new ModifiableNumber(0);
pns->AddMember("emptyGeo", Geo::GetEmpty() );
pns->AddMember("emptyImage", (Value*)Image::GetEmpty() );
pns->AddMember("transparentImage", (Value*)CreateTransparentImage());
pns->AddMember("emptyString", new StringValue(ZString()) );
pns->AddMember("identityTransform", GetIdentityTransform() );
pns->AddMember("time", ptime );
pns->AddMember("white", new ColorValue(Color::White() ) );
pns->AddMember("black", new ColorValue(Color::Black() ) );
pns->AddMember("red", new ColorValue(Color::Red() ) );
pns->AddMember("green", new ColorValue(Color::Green() ) );
pns->AddMember("blue", new ColorValue(Color::Blue() ) );
pns->AddMember("yellow", new ColorValue(Color::Yellow()) );
pns->AddMember("cyan", new ColorValue(Color::Cyan() ) );
pns->AddMember("pi", new Number(pi) );
pns->AddMember("defaultFont",
new FontValue(
CreateEngineFont(
CreateFont(
11,
0, 0, 0,
FW_DONTCARE, FALSE, FALSE, FALSE, ANSI_CHARSET,
OUT_DEFAULT_PRECIS, CLIP_DEFAULT_PRECIS,
DEFAULT_QUALITY, DEFAULT_PITCH | FF_MODERN,
"tahoma"
)
)
)
);
//
// Switches
//
pns->AddMember("SwitchString", new TSwitchFactory<ZString>());
pns->AddMember("SwitchPoint", new TSwitchFactory<Point>()); // #361
//
// Data type constructors
//
pns->AddMember("ModifiableNumber", new ModifiableNumberFactory());
pns->AddMember("WrapNumber", new WrapNumberFactory());
pns->AddMember("Color", new RGBColorFactory());
pns->AddMember("ColorA", new RGBAColorFactory());
pns->AddMember("Vector", new VectorFactory());
pns->AddMember("Point", new PointFactory());
pns->AddMember("Rect", new RectFactory());
pns->AddMember("Material", new MaterialFactory());
pns->AddMember("PointV", new PointVFactory());
//
// Numbers
//
pns->AddMember("Min", new MinFactory());
pns->AddMember("Max", new MaxFactory());
pns->AddMember("Mod", new ModFactory());
pns->AddMember("Add", new AddFactory());
pns->AddMember("Subtract", new SubtractFactory());
pns->AddMember("Multiply", new MultiplyFactory());
pns->AddMember("Divide", new DivideFactory());
//
// Strings
//
pns->AddMember("NumberString", new NumberStringFactory());
pns->AddMember("RealNumberString", new RealNumberStringFactory());
pns->AddMember("ConcatinatedString", new ConcatinatedStringFactory());
//
// Images
//
pns->AddMember("ImportImage", new ImportImageFactory(this));
pns->AddMember("ImportImageFromFile",new ImportImageFromFileFactory(this)); // KGJV 32B
pns->AddMember("ImportImage3D", new ImportImage3DFactory(this));
pns->AddMember("Image3D", new Image3DFactory(this)); // KGJV - added
pns->AddMember("ImportImageLR", new ImportImageLRFactory(this));
pns->AddMember("FrameImage", CreateFrameImageFactory());
pns->AddMember("GaugeImage", new GaugeImageFactory());
pns->AddMember("GaugeImageRect", new GaugeImageRectFactory());
pns->AddMember("GroupImage", new GroupImageFactory());
pns->AddMember("SwitchImage", new SwitchImageFactory());
pns->AddMember("GeoImage", new GeoImageFactory());
pns->AddMember("GeoImage2D", new GeoImage2DFactory());
pns->AddMember("ClipImage", new ClipImageFactory());
pns->AddMember("PickImage", new PickImageFactory());
pns->AddMember("UndetectableImage", new UndetectableImageFactory());
pns->AddMember("ColorImage", new ColorImageFactory());
pns->AddMember("ExtentImage", new ExtentImageFactory());
// !!! pns->AddMember("EmptyImage", new EmptyImageFactory());
pns->AddMember("StringImage", new StringImageFactory());
pns->AddMember("MDLFileImage", new MDLFileImageFactory(this));
pns->AddMember("TextFileImage", new TextFileImageFactory());
pns->AddMember("JustifyLeft", new Number((float)JustifyLeft().GetWord() ));
pns->AddMember("JustifyRight", new Number((float)JustifyRight().GetWord() ));
pns->AddMember("JustifyTop", new Number((float)JustifyTop().GetWord() ));
pns->AddMember("JustifyBottom", new Number((float)JustifyBottom().GetWord() ));
pns->AddMember("JustifyXCenter", new Number((float)JustifyXCenter().GetWord()));
pns->AddMember("JustifyYCenter", new Number((float)JustifyYCenter().GetWord()));
pns->AddMember("JustifyCenter", new Number((float)JustifyCenter().GetWord() ));
pns->AddMember("JustifyImage", new JustifyImageFactory());
pns->AddMember("VisibleImage", new VisibleImageFactory());
pns->AddMember("TranslateImage", new TranslateImageFactory());
pns->AddMember("ScaleImage", new ScaleImageFactory());
pns->AddMember("RotateImage", new RotateImageFactory());
pns->AddMember("BlendImage", new BlendImageFactory());
//
// Image Attributes
//
pns->AddMember("ImageSize", new ImageSizeFactory());
//
// Point Attributes
//
pns->AddMember("PointY", new PointYFactory());
pns->AddMember("PointX", new PointXFactory());
//
// Geos
//
pns->AddMember("ImportXFile", new ImportXFileFactory(this));
pns->AddMember("ImportMDL", new ImportMDLFactory(this));
pns->AddMember("MeshGeo", new MeshGeoFactory());
pns->AddMember("LODGeo", new LODGeoFactory());
pns->AddMember("GroupGeo", new GroupGeoFactory());
pns->AddMember("TransformGeo", new TransformGeoFactory());
pns->AddMember("MaterialGeo", new MaterialGeoFactory());
pns->AddMember("TextureGeo", new TextureGeoFactory());
pns->AddMember("Matrix", new MatrixTransformFactory());
pns->AddMember("BlendGeo", new BlendGeoFactory());
pns->AddMember("BlendModeSource", new Number(BlendModeSource ));
pns->AddMember("BlendModeAdd", new Number(BlendModeAdd ));
pns->AddMember("BlendModeSourceAlpha", new Number(BlendModeSourceAlpha));
//
// Transforms
//
pns->AddMember("KeyFramedTranslate", new KeyFramedTranslateFactory());
pns->AddMember("KeyFramedScale", new KeyFramedScaleFactory());
pns->AddMember("KeyFramedRotate", new KeyFramedRotateFactory());
pns->AddMember("Scale", new ScaleFactory());
pns->AddMember("Translate", new TranslateFactory());
pns->AddMember("Rotate", new RotateFactory());
// Camera (KGJV)
// Camera(zclip near,zclip far,FOV in degrees,position_vector)
pns->AddMember("Camera", new CameraFactory());
//
// Fonts
//
pns->AddMember("Win32Font", new Win32FontFactory(m_pengine));
pns->AddMember("ImportFont", new ImportFontFactory(this));
//
// Panes
//
pns->AddMember("AnimatedImagePane", new AnimatedImagePaneFactory());
pns->AddMember("AnimatedImagePaneRect", new AnimatedImagePaneRectFactory());
pns->AddMember("FrameImageButtonPane", new FrameImageButtonPaneFactory(this, ptime));
pns->AddMember("PaneImage", new PaneImageFactory(this));
}
Engine* GetEngine()
{
return m_pengine;
}
TRef<ZFile> GetFile(const PathString& pathStr, const ZString& strExtensionArg, bool bError)
{
ZString strExtension = pathStr.GetExtension();
ZString strToTryOpenFromMods; // turkey 8/13 #294 will use subfolders in /mods/ based on styleHud setting
ZString strToTryOpen;// yp Your_Persona October 7 2006 : TextureFolder Patch
ZString strToTryOpenFromDev;// KGJV - 'dev' subfolder
ZString strToTryOpenFromSteamDLC; // BT - STEAM
ZString strToOpen;
TRef<ZFile> pfile = NULL;
if (!strExtension.IsEmpty()) {
if (!strExtensionArg.IsEmpty()) // KGJV 32B - ignore empty strExtensionArg
if (strExtension.ToLower() != strExtensionArg.ToLower()) { // KGJV 32B - ignore case
return NULL;
}
strToOpen = m_pathStr + pathStr;
strToTryOpenFromDev = m_pathStr + "dev/" + pathStr;
strToTryOpen = m_pathStr + "Textures/" + pathStr;
strToTryOpenFromSteamDLC = ZString(m_pathStr + "SteamDLC/") + ZString(pathStr);
} else {
strToOpen = ZString(m_pathStr + pathStr) + ("." + strExtensionArg);
strToTryOpenFromDev = ZString(m_pathStr + "dev/" + pathStr) + ("." + strExtensionArg);
strToTryOpen = ZString(m_pathStr + "Textures/" + pathStr) + ("." + strExtensionArg);
strToTryOpenFromSteamDLC = ZString(m_pathStr + "SteamDLC/") + ZString(pathStr) + ("." + strExtensionArg);
}
/*DWORD dwFileSize;
void * pPackFile;
pPackFile = CDX9PackFile::LoadFile( &strPackFile[0], &dwFileSize );
if( ( pPackFile != NULL ) && ( dwFileSize > 0 ) )
{
pfile = new ZPackFile( strPackFile, pPackFile, dwFileSize );
}*/
// BT - STEAM
if (pfile == NULL &&
(strToTryOpenFromSteamDLC.Right(17) != "newgamescreen.mdl")) //newgamescreen needs to be ACSS-protected, so don't open it from mods
{
pfile = new ZFile(strToTryOpenFromSteamDLC, OF_READ | OF_SHARE_DENY_WRITE);
if (!pfile->IsValid())
pfile = NULL;
#ifdef STEAMSECURE
// When building release mode, then enforce the artwork checksums on any MDL that is loaded by the engine.
else if(m_fileHashTable.DoesFileHaveHash(strToTryOpenFromSteamDLC) == true)
pfile = NULL;
#endif
}
// yp Your_Persona October 7 2006 : TextureFolder Patch
if( ( pfile == NULL ) &&
( strToTryOpen.Right(7) == "bmp.mdl" ) ) // if its a texture, try loading from the strToTryOpen
{
pfile = new ZFile(strToTryOpen, OF_READ | OF_SHARE_DENY_WRITE);
// mmf modified Y_P's logic
if(!pfile->IsValid())
{
pfile = NULL;
}
}
if(!pfile) // if we dont have a file here, then load regularly.
{
// mmf #if this out for release. I left the strtoTryOpenFromDev code in above
// pkk - Use same conditional compilation like on registry keys
#ifdef _ALLEGIANCE_PROD_
pfile = new ZFile(strToOpen, OF_READ | OF_SHARE_DENY_WRITE);
#else
// KGJV try dev folder 1st
pfile = new ZFile(strToTryOpenFromDev, OF_READ | OF_SHARE_DENY_WRITE);
if (!pfile->IsValid()) {
pfile = new ZFile(strToOpen, OF_READ | OF_SHARE_DENY_WRITE);
} else {
if (g_bMDLLog) {
ZDebugOutput("'dev' file found for " + pathStr + "\n");
}
}
#endif
// mmf added debugf but will still have it call assert
if (!pfile->IsValid()) {
ZDebugOutput("Could not open the artwork file "+ strToOpen + "\n");
// this may fail/crash if strToOpen is fubar, but we are about to ZRAssert anyway
}
else
{
#ifdef STEAMSECURE
// BT - STEAM - Do the security checksum on the loaded file here. Steam DRM wrapper will ensure that the Allegiance exe is not
// tampered with, so basic checksums are all that is required.
if(m_fileHashTable.IsHashCorrect(strToOpen, pfile->GetSha1Hash()) == false)
{
// Cause the calls downward to fail out.
pfile = new ZFile("failsauce.nope");
}
#endif
}
}
//Imago 11/09/09 - Provide a helpful message box for this common error
if (bError && !pfile->IsValid() && m_psite) {
PostMessageA(GetActiveWindow(), WM_SYSCOMMAND, SC_MINIMIZE,0);
MessageBoxA(GetDesktopWindow(), "Artwork file failed to validate: " + strToOpen + ", please reverify your installation using the Steam app.", "Allegiance: Fatal modeler error", MB_ICONERROR);
}
ZRetailAssert(!(bError && !pfile->IsValid() && m_psite));
return pfile->IsValid() ? pfile : NULL;
}
TRef<ZFile> LoadFile(const PathString& pathStr, const ZString& strExtensionArg, bool bError)
{
return GetFile(pathStr, strExtensionArg, bError);
}
TRef<Surface> LoadSurface(const ZString& str, bool bColorKey, bool bError)
{
TRef<ConstantImage> pimage; CastTo(pimage, LoadImage(str, bColorKey, bError));
if (pimage) {
return pimage->GetSurface();
}
return NULL;
}
TRef<Image> LoadImage(const ZString& str, bool bColorKey, bool bError)
{
ZAssert(str.ToLower() == str);
ZAssert(str.Right(3) == "bmp");
//
// Is the image already loaded?
//
TRef<INameSpace> pns = GetCachedNameSpace(str);
if (pns) {
TRef<ConstantImage> pimage; CastTo(pimage, (Value*)pns->FindMember(str));
if (pimage) {
TRef<Surface> psurface = pimage->GetSurface();
// HACK: Need to uncomment and track down the bug that's
// triggering this when a weapon fires, but this hack should
// keep the debug client testable.
//ZAssert(bColorKey == psurface->HasColorKey());
return pimage;
}
return NULL;
}
//
// Try to load it
//
pns = GetNameSpace(str, bError);
if (pns) {
TRef<ConstantImage> pimage; CastTo(pimage, (Value*)pns->FindMember(str));
if (pimage) {
TRef<Surface> psurface = pimage->GetSurface();
psurface->SetName(str);
if (bColorKey) {
psurface->SetColorKey(Color(0, 0, 0));
}
return pimage;
}
}
return NULL;
}
HBITMAP LoadBitmap(const PathString& pathStrArg, bool bError)
{
PathString pathStr = m_pathStr + pathStrArg;
ZString strExtension = pathStr.GetExtension();
if (strExtension == "bmp" || strExtension.IsEmpty()) {
if (strExtension.IsEmpty()) {
pathStr += ".bmp";
}
return
(HBITMAP)::LoadImageA(
NULL,
pathStr,
IMAGE_BITMAP,
0,
0,
LR_LOADFROMFILE | LR_CREATEDIBSECTION
);
}
return NULL;
}
TRef<Geo> LoadGeo(const ZString& str, bool bError)
{
ZAssert(str.ToLower() == str);
TRef<INameSpace> pns = GetNameSpace(str, bError);
if (pns) {
TRef<Geo> pgeo; CastTo(pgeo, (Value*)pns->FindMember("object"));
return pgeo;
}
return NULL;
}
TRef<Geo> LoadXFile(
const PathString& pathStr,
Number* pnumberFrame,
bool& bAnimation,
bool bError
) {
TRef<ZFile> pfile = GetFile(pathStr, "x", bError);
if (pfile) {
return ::ImportXFile(this, pfile, pnumberFrame, bAnimation);
}
return NULL;
}
INameSpace* CreateNameSpace(const ZString& str)
{
TRef<INameSpace> pns = ::CreateNameSpace(str);
m_mapNameSpace.Set(str, pns);
return pns;
}
INameSpace* CreateNameSpace(const ZString& str, INameSpace* pnsParent)
{
TRef<INameSpace> pns = ::CreateNameSpace(str, pnsParent);
m_mapNameSpace.Set(str, pns);
return pns;
}
INameSpace* GetCachedNameSpace(const ZString& str)
{
TRef<INameSpace> pns;
if (m_mapNameSpace.Find(str, pns)) {
return pns;
}
return NULL;
}
INameSpace* GetNameSpace(const ZString& str, bool bError)
{
TRef<INameSpace> pns = GetCachedNameSpace(str);
if (pns) {
return pns;
}
TRef<ZFile> pfile = GetFile(str, "mdl", bError);
if (pfile != NULL) {
if (*(DWORD*)pfile->GetPointer(false, false) == MDLMagic) {
if (g_bMDLLog) {
ZDebugOutput("Reading Binary MDL file '" + str + "'\n");
}
pns = CreateBinaryNameSpace(str, this, pfile);
} else {
if (g_bMDLLog) {
ZDebugOutput("Reading Text MDL file '" + str + "'\n");
}
pns = ::CreateNameSpace(str, this, pfile);
}
m_mapNameSpace.Set(str, pns);
return pns;
}
return NULL;
}
void UnloadNameSpace(const ZString& str)
{
m_mapNameSpace.Remove(str);
}
void UnloadNameSpace(INameSpace* pns)
{
m_mapNameSpace.Remove(TRef<INameSpace>(pns));
}
};
//////////////////////////////////////////////////////////////////////////////
//
// Constructor
//
//////////////////////////////////////////////////////////////////////////////
TRef<Modeler> Modeler::Create(Engine* pengine)
{
return new ModelerImpl(pengine);
}
| [
"[email protected]"
] | |
c5008886bd636feef06cf73e3ac391586cfe0ea9 | d0c44dd3da2ef8c0ff835982a437946cbf4d2940 | /cmake-build-debug/programs_tiling/function13967/function13967_schedule_46/function13967_schedule_46_wrapper.cpp | 5e280c04be7f7fb04a3bfe6feb60f619b4f99f4e | [] | no_license | IsraMekki/tiramisu_code_generator | 8b3f1d63cff62ba9f5242c019058d5a3119184a3 | 5a259d8e244af452e5301126683fa4320c2047a3 | refs/heads/master | 2020-04-29T17:27:57.987172 | 2019-04-23T16:50:32 | 2019-04-23T16:50:32 | 176,297,755 | 1 | 2 | null | null | null | null | UTF-8 | C++ | false | false | 1,350 | cpp | #include "Halide.h"
#include "function13967_schedule_46_wrapper.h"
#include "tiramisu/utils.h"
#include <cstdlib>
#include <iostream>
#include <time.h>
#include <fstream>
#include <chrono>
#define MAX_RAND 200
int main(int, char **){
Halide::Buffer<int32_t> buf00(128);
Halide::Buffer<int32_t> buf01(64, 128, 64);
Halide::Buffer<int32_t> buf02(64);
Halide::Buffer<int32_t> buf03(128, 64, 128);
Halide::Buffer<int32_t> buf04(128, 64);
Halide::Buffer<int32_t> buf05(64, 128);
Halide::Buffer<int32_t> buf06(64, 128);
Halide::Buffer<int32_t> buf0(128, 64, 128, 64);
init_buffer(buf0, (int32_t)0);
auto t1 = std::chrono::high_resolution_clock::now();
function13967_schedule_46(buf00.raw_buffer(), buf01.raw_buffer(), buf02.raw_buffer(), buf03.raw_buffer(), buf04.raw_buffer(), buf05.raw_buffer(), buf06.raw_buffer(), buf0.raw_buffer());
auto t2 = std::chrono::high_resolution_clock::now();
std::chrono::duration<double> diff = t2 - t1;
std::ofstream exec_times_file;
exec_times_file.open("../data/programs/function13967/function13967_schedule_46/exec_times.txt", std::ios_base::app);
if (exec_times_file.is_open()){
exec_times_file << diff.count() * 1000000 << "us" <<std::endl;
exec_times_file.close();
}
return 0;
} | [
"[email protected]"
] | |
f160a4dbf50207fa7914f391b57d7c816ae964d0 | 2e9beab91dc28f31cb0debb085de5b51109e5484 | /FrontendServer.h | 723bca49fc506b8655b7c216ec46a4a152312aa5 | [] | no_license | shifangyan/- | 22d5b31131ef34dd7437c13d8b53e8c429395cff | 805a74b3b4b30cb1449c2420d0ceffd8098dbf7d | refs/heads/master | 2020-12-06T17:04:47.959231 | 2020-01-08T08:19:56 | 2020-01-08T08:19:56 | 232,514,095 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 681 | h | #ifndef FRONTENDSERVER_H
#define FRONTENDSERVER_H
#include "WebsocketServer.h"
#include "muduo/net/EventLoop.h"
#include "muduo/net/InetAddress.h"
#include "muduo/net/EventLoop.h"
class Configuration;
class AlgorithmServerCommunication;
class FrontendServer
{
public:
FrontendServer(muduo::net::EventLoop* loop, Configuration* config, AlgorithmServerCommunication* algo);
void send(const std::string& sendStr);
private:
void FrontendCallback(const muduo::net::TcpConnectionPtr& conn, std::string& payloadData);
muduo::net::WebsocketServer server_;
Configuration* config_;
AlgorithmServerCommunication* algo_;
muduo::net::EventLoop* loop_;
};
#endif // !FRONTENDSERVER_H
| [
"[email protected]"
] | |
ba9a7a390d51cfdd80a63c3d841e6993096674b1 | 3950a02ce6fc15e95c31f6fe89b2f237a58b0430 | /UVa Online Judge/652/solution.cpp | 56e8d172da4bcdb38a6bbf329391a2e31ac579a0 | [] | no_license | pedrohdjs/Advanced-Algorithms-and-Applications---SCC0218 | 36544f1701df9bb3f3499a33952071a4a5879dc0 | e9649546bc698a35cbda602c217193acbf54e069 | refs/heads/master | 2023-03-03T16:51:00.412464 | 2021-02-09T19:09:32 | 2021-02-09T19:09:32 | 291,547,193 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 8,427 | cpp | #include <iostream>
#include <string>
#include <vector>
#include <queue>
#include <map>
using namespace std;
const char FINAL_STATE_POSITIONS[9] = {'1','2','3','4','5','6','7','8','x'};
const char POSSIBLE_MOVES[4] = {'d','l','u','r' };
map<char,pair<int,int>> FINAL_STATE_POSITIONS_MANHATTAN_COORDINATES = { {'1',pair<int,int>(0,0)},
{'2',pair<int,int>(0,1)},
{'3',pair<int,int>(0,2)},
{'4',pair<int,int>(1,0)},
{'5',pair<int,int>(1,1)},
{'6',pair<int,int>(1,2)},
{'7',pair<int,int>(2,0)},
{'8',pair<int,int>(2,1)},
{'x',pair<int,int>(2,2)} };
class State {
public:
State(vector<char> positions,int xPosition, char movementBefore, int depth){
this->positions = positions;
this->xPosition = xPosition;
this->movementBefore = movementBefore;
this->depth = depth;
}
State(){
this->xPosition = -1;
}
int getDepth(){
return this->depth;
}
char getMovementBefore(){
return this->movementBefore;
}
bool isValidState(){
return (this->xPosition != -1);
}
bool isFinalState(){
for(int i = 0; i<9; i++){
if (this->positions[i] != FINAL_STATE_POSITIONS[i])
return false;
}
return true;
}
State getNextState(char move){
vector<char> newPositions = vector<char>(this->positions);
int newXPosition = this->xPosition;
switch (move){
case ('r'):
if (this->xPosition == 2 || this->xPosition == 5 || this->xPosition == 8)
return State();//Invalid state returned
newXPosition = this->xPosition + 1;
break;
case ('l'):
if (this->xPosition == 0 || this->xPosition == 3 || this->xPosition == 6)
return State();//Invalid state returned
newXPosition = this->xPosition - 1;
break;
case ('u'):
if (this->xPosition == 0 || this->xPosition == 1 || this->xPosition == 2)
return State();//Invalid state returned
newXPosition = this->xPosition - 3;
break;
case ('d'):
if (this->xPosition == 6 || this->xPosition == 7 || this->xPosition == 8)
return State();//Invalid state returned
newXPosition = this->xPosition + 3;
break;
default:
return State();//Invalid state returned
break;
}
//Swap the old and new X positions;
newPositions[xPosition] = newPositions[newXPosition];
newPositions[newXPosition] = 'x';
return State(newPositions,newXPosition,move,this->depth+1);
}
vector<State> getAllNextStates(){
vector<State> nextStates;
for (char move : POSSIBLE_MOVES){
State nextState = this->getNextState(move);
if (nextState.isValidState()){
nextStates.push_back(nextState);
}
}
return nextStates;
}
string toString(){
string s = "";
for(int i = 0; i<9; i++)
s += this->positions[i];
return s;
}
//Heuristic function using manhattan distance between the current position and the goal position
int distanceToFinalState(){
int distance = 0;
for(int i = 0; i<9; i++){
if (this->positions[i] != 'x'){
distance += abs(FINAL_STATE_POSITIONS_MANHATTAN_COORDINATES[this->positions[i]].first - i/3)
+ abs(FINAL_STATE_POSITIONS_MANHATTAN_COORDINATES[this->positions[i]].second - i%3);
}
}
return distance;
}
bool isSolvable(){
return (this->numInversions()%2 == 0);
}
int numInversions(){
int inversions = 0;
for(int i = 0; i<9;i++){
if (positions[i] == 'x') continue;
for(int j = i+1; j<9; j++){
if(positions[j] < positions[i])
inversions++;
}
}
return inversions;
}
private:
vector<char> positions;
int xPosition;
char movementBefore;
int depth;
};
class CompareState {
public:
CompareState(){
}
bool operator()(State & s1, State & s2) {
return s1.distanceToFinalState() + s1.getDepth() > s2.distanceToFinalState() + s2.getDepth();
}
};
class EightPuzzleProblem{
public:
EightPuzzleProblem(State initialState){
this->initialState = initialState;
this->finalState = State();
this->previousState[initialState.toString()] = State();
}
void solve(){
if (!this->isSolvable()) return;
priority_queue<State,vector<State>,CompareState> states{CompareState()};
states.push(this->initialState);
while(!states.empty()){
State currentState = states.top();
states.pop();
if (currentState.isFinalState()){
this->finalState = currentState;
return;
}
if (visited[currentState.toString()])
continue;//Skip the current iteration since this state was already processed
visited[currentState.toString()] = true;
vector<State> nextStates = currentState.getAllNextStates();
for (State s : nextStates){
if(!found[s.toString()]){
states.push(s);
previousState[s.toString()] = currentState;
found[s.toString()] = true;
}
}
}
}
void showAnswer(){
if (!this->finalState.isValidState()){
cout << "unsolvable" << endl;//No solution found
}
else{
string s = "";
State currentState = this->finalState;
while (currentState.getMovementBefore() != 'x'){
s = currentState.getMovementBefore() + s;
currentState = previousState[currentState.toString()];
}
cout << s << endl;
}
}
private:
bool isSolvable(){
return this->initialState.isSolvable();
}
State initialState;
State finalState;
map<string,bool> visited;
map<string,bool> found;
map<string,State> previousState;
};
int main(int argc, char* argv[]){
int numTests;
cin >> numTests;
for (int i = 0; i<numTests;i++){
int xPosition;
vector<char> positions;
for (int j = 0; j<9;j++){
char value;
cin >> value;
if (value == '0')
value = 'x';
positions.push_back(value);
if(value == 'x'){
xPosition = j;
}
}
State initialState = State(positions,xPosition,'x',0);
EightPuzzleProblem p = EightPuzzleProblem(initialState);
p.solve();
p.showAnswer();
if(i != numTests -1 )
cout << endl;
}
return 0;
} | [
"[email protected]"
] | |
c2869de5d199450cbb127115a4b412dbb37d6ef4 | 2ae0b8d95d439ccfd55ea7933ad4a2994ad0f6c5 | /src/plugins/intel_cpu/tests/functional/shared_tests_instances/low_precision_transformations/output_layers.cpp | 6035a6437826641284f7df3885cbc836394ab47a | [
"Apache-2.0"
] | permissive | openvinotoolkit/openvino | 38ea745a247887a4e14580dbc9fc68005e2149f9 | e4bed7a31c9f00d8afbfcabee3f64f55496ae56a | refs/heads/master | 2023-08-18T03:47:44.572979 | 2023-08-17T21:24:59 | 2023-08-17T21:24:59 | 153,097,643 | 3,953 | 1,492 | Apache-2.0 | 2023-09-14T21:42:24 | 2018-10-15T10:54:40 | C++ | UTF-8 | C++ | false | false | 1,126 | cpp | // Copyright (C) 2018-2023 Intel Corporation
// SPDX-License-Identifier: Apache-2.0
//
#include <vector>
#include "low_precision_transformations/output_layers.hpp"
#include "common_test_utils/test_constants.hpp"
using namespace LayerTestsDefinitions;
using namespace ngraph::pass::low_precision;
namespace {
const std::vector<InferenceEngine::Precision> netPrecisions = {
InferenceEngine::Precision::FP32,
InferenceEngine::Precision::FP16
};
const std::vector<LayerTransformation::Params> trasformationParamValues = {
LayerTestsUtils::LayerTransformationParamsFactory::createParams(),
// LayerTestsUtils::LayerTransformationParamsFactory::createParamsI8I8(),
// LayerTestsUtils::LayerTransformationParamsFactory::createParamsU8I8()
};
INSTANTIATE_TEST_SUITE_P(smoke_LPT, OutputLayers,
::testing::Combine(
::testing::ValuesIn(netPrecisions),
::testing::Values(InferenceEngine::SizeVector({ 1, 3, 16, 16 })),
::testing::Values(ov::test::utils::DEVICE_CPU),
::testing::ValuesIn(trasformationParamValues)),
OutputLayers::getTestCaseName);
} // namespace
| [
"[email protected]"
] | |
c5c9330f70c1b769c32710e22c0a9615ace225eb | a1105c33b21c7fe0d8e5967b4b97e919d9e23ca8 | /数据结构教程-源程序/第5章/exam5-5.cpp | 62b86f8d25c682783d023da3478a8a39e1aef816 | [] | no_license | billgoo/Learning-About-Data-Structure | 3c2b57951b325f07d827fe326c088f9e2d11d0f8 | d67076a6563823a98d46b469cbfb2015a1d0f331 | refs/heads/master | 2021-01-01T18:49:47.429034 | 2017-07-26T15:52:38 | 2017-07-26T15:52:38 | 98,440,005 | 12 | 0 | null | null | null | null | GB18030 | C++ | false | false | 1,827 | cpp | #include <stdio.h>
#define MaxSize 100
#define M 8
#define N 8
int mg[M+2][N+2]=
{
{1,1,1,1,1,1,1,1,1,1},
{1,0,0,1,0,0,0,1,0,1},
{1,0,0,1,0,0,0,1,0,1},
{1,0,0,0,0,1,1,0,0,1},
{1,0,1,1,1,0,0,0,0,1},
{1,0,0,0,1,0,0,0,0,1},
{1,0,1,0,0,0,1,0,0,1},
{1,0,1,1,1,0,1,1,0,1},
{1,1,0,0,0,0,0,0,0,1},
{1,1,1,1,1,1,1,1,1,1}
};
typedef struct
{
int i; //当前方块的行号
int j; //当前方块的列号
} Box;
typedef struct
{
Box data[MaxSize];
int length; //路径长度
} PathType; //定义路径类型
int count=0; //存放迷宫路径的条数
void mgpath(int xi,int yi,int xe,int ye,PathType path)
//求解路径为:(xi,yi)->(xe,ye)
{
int di,k,i,j;
if (xi==xe && yi==ye) //找到了出口,输出路径
{
path.data[path.length].i = xi;
path.data[path.length].j = yi;
path.length++;
printf("迷宫路径%d如下:\n",++count);
for (k=0;k<path.length;k++)
{
printf("\t(%d,%d)",path.data[k].i,path.data[k].j);
if ((k+1)%5==0) //每输出每5个方块后换一行
printf("\n");
}
printf("\n");
}
else //(xi,yi)不是出口
{
if (mg[xi][yi]==0) //(xi,yi)是一个可走方块
{
di=0;
while (di<4) //找(xi,yi)的一个相邻方块(i,j)
{
path.data[path.length].i = xi;
path.data[path.length].j = yi;
path.length++;
switch(di)
{
case 0:i=xi-1; j=yi; break;
case 1:i=xi; j=yi+1; break;
case 2:i=xi+1; j=yi; break;
case 3:i=xi; j=yi-1; break;
}
mg[xi][yi]=-1; //避免重复找路径
mgpath(i,j,xe,ye,path);
mg[xi][yi]=0; //恢复(xi,yi)为可走
path.length--; //回退一个方块
di++;
}
}
}
}
void main()
{
PathType path;
path.length=0; //初始化路径长度
mgpath(1,1,M,N,path);
}
| [
"[email protected]"
] | |
b7449a51f2cb5e00d5d9416318ca82a5fa9a3983 | 948a5466d434b1640abd14a1f8420846c61e01c9 | /our-workspace/adding-sensors/adding-sensors.ino | d05b982574a2467e9294a19edd4af8f5ba774ced | [] | no_license | IoTClassroom/sigfox-workshop-hei-2018-proust-toulemonde | 986c2c3626acc6ea6275eeb1a3fd0fbc8dcf7e1f | ce43f4bc82cdf20a4d5559535fa81c609b0e9dd0 | refs/heads/master | 2021-04-30T15:48:57.246121 | 2018-02-12T15:45:22 | 2018-02-12T15:45:22 | 121,250,374 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 606 | ino | /*
* Author: Louis Moreau: https://github.com/luisomoreau
* Date: 2017/03/03
* Description:
* Read analog values from a sensor and display it on a console
*/
// the setup function runs once when you press reset or power the board
void setup() {
Serial.begin(9600);
}
// the loop function runs over and over again forever
void loop() {
int sensorValue = analogRead(A0);
Serial.print("light: ");
Serial.println(sensorValue);
float percentage = map(sensorValue, 0, 1023, 0, 100);
Serial.print("light percentage: ");
Serial.print(percentage);
Serial.println(" % ");
delay(1000);
}
| [
"[email protected]"
] | |
3a4fe6af4447b2f3317c84e181a73d13520156a8 | 1c8e5a1fc7f9dfee4969194c1bd77918eea73095 | /Source/AllProjects/CommUtils/CIDComm/CIDComm_LocalPortFactory.cpp | 4cd44814994b87cb69d4faab3ea6677af0dcd9c4 | [] | no_license | naushad-rahman/CIDLib | bcb579a6f9517d23d25ad17a152cc99b7508330e | 577c343d33d01e0f064d76dfc0b3433d1686f488 | refs/heads/master | 2020-04-28T01:08:35.084154 | 2019-03-10T02:03:20 | 2019-03-10T02:03:20 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 4,638 | cpp | //
// FILE NAME: CIDComm_LocalPortFactory.cpp
//
// AUTHOR: Dean Roddey
//
// CREATED: 09/12/2005
//
// COPYRIGHT: $_CIDLib_CopyRight_$
//
// $_CIDLib_CopyRight2_$
//
// DESCRIPTION:
//
// This file implements the simple port factory derivative that supports
// local ports.
//
// CAVEATS/GOTCHAS:
//
// LOG:
//
// $_CIDLib_Log_$
//
// ---------------------------------------------------------------------------
// Facility specific includes
// ---------------------------------------------------------------------------
#include "CIDComm_.hpp"
// ---------------------------------------------------------------------------
// Magic RTTI macros
// ---------------------------------------------------------------------------
RTTIDecls(TLocalComPortFactory,TComPortFactory)
// ---------------------------------------------------------------------------
// CLASS: TLocalComPortFactory
// PREFIX: pfact
// ---------------------------------------------------------------------------
// ---------------------------------------------------------------------------
// TLocalComPortFactory: Constructors and Destructor
// ---------------------------------------------------------------------------
// Tell our parent these ports are configuraable
TLocalComPortFactory::TLocalComPortFactory() :
TComPortFactory
(
TFacCIDComm::strLocalFactoryId
, TFacCIDComm::strLocalPortPrefix
, kCIDLib::True
)
{
}
TLocalComPortFactory::~TLocalComPortFactory()
{
}
// ---------------------------------------------------------------------------
// TLocalComPortFactory: Public, virtual methods
// ---------------------------------------------------------------------------
//
// We put all the ports we support into the passed collection. We don't
// clear it first since the facility class is building up a list from all
// the installed factories.
//
tCIDLib::TBoolean
TLocalComPortFactory::bQueryPorts( tCIDLib::TStrCollect& colToFill
, const tCIDLib::TBoolean bAvailOnly) const
{
// <TBD> Is there an efficient way to support the bAvailOnly flag?
//
// Ask the kernel comm support for any ports in the first 64 possible
// com slots.
//
const tCIDLib::TCard4 c4ToCheck = 128;
tCIDLib::TBoolean abFlags[c4ToCheck];
const tCIDLib::TCard4 c4Count = TKrnlCommPort::c4EnumPorts(abFlags, c4ToCheck);
TString strName;
for (tCIDLib::TCard4 c4Index = 0; c4Index < c4ToCheck; c4Index++)
{
if (abFlags[c4Index])
{
strName = TFacCIDComm::strLocalPortPrefix;
strName.AppendFormatted(c4Index + 1);
colToFill.objAdd(strName);
}
}
// Return true if we got any
return (c4Count != 0);
}
// We can accept any config since we are doing real local ports
tCIDLib::TBoolean
TLocalComPortFactory::bTestCfg(const TCommPortCfg&, TString&) const
{
return kCIDLib::True;
}
// Parse the path and see if looks synatically correct
tCIDLib::TBoolean
TLocalComPortFactory::bValidatePath(const TString& strPath) const
{
tCIDLib::TCard4 c4Dummy;
return bValidate(strPath, c4Dummy);
}
TCommPortBase* TLocalComPortFactory::pcommMakeNew(const TString& strPath)
{
//
// Get the local comm port number out of the path and use that to create
// a new local comm port.
//
tCIDLib::TCard4 c4PortNum;
if (!bValidate(strPath, c4PortNum))
{
facCIDComm().ThrowErr
(
CID_FILE
, CID_LINE
, kCommErrs::errcFac_BadPortName
, tCIDLib::ESeverities::Failed
, tCIDLib::EErrClasses::Format
, strPath
);
}
return new TCommPort(strPath, c4PortNum);
}
// ---------------------------------------------------------------------------
// TLocalComPortFactory: Private, non-virtual methods
// ---------------------------------------------------------------------------
//
// The name will be like /Local/COMXX, so we need to get that number
// out and set that on the underlying local com port class.
//
tCIDLib::TBoolean
TLocalComPortFactory::bValidate(const TString& strPath
, tCIDLib::TCard4& c4PortNum) const
{
// If it doesn't start with our prefix, then not ours
if (!strPath.bStartsWithI(TFacCIDComm::strLocalPortPrefix))
return kCIDLib::False;
tCIDLib::TBoolean bOk;
c4PortNum = TRawStr::c4AsBinary
(
strPath.pszBufferAt(TFacCIDComm::strLocalPortPrefix.c4Length())
, bOk
, tCIDLib::ERadices::Dec
);
return bOk;
}
| [
"[email protected]"
] | |
366a2c6e6c682ec4676e6207a263e16353687059 | 55564a1293978d769b5a7891dc91851647c0e3a5 | /Problems/Coffee/Coffee.cpp | b2ccbef012fa561e038021cfb5406fb7140eabbb | [] | no_license | Md-Sabbir-Ahmed/AtCoder | 57dd912dfc57113e96b14471f3ca7126f975eef4 | 3b096018b30bd3b08f510ac6c42f82723729c078 | refs/heads/master | 2022-11-20T10:01:07.498254 | 2020-07-24T15:48:26 | 2020-07-24T15:48:26 | 262,530,486 | 1 | 1 | null | null | null | null | UTF-8 | C++ | false | false | 277 | cpp | #include<bits/stdc++.h>
using namespace std;
int main()
{
ios_base::sync_with_stdio(false);
cin.tie(NULL);
string S;
cin>>S;
if((S[2]==S[3])&& (S[4]==S[5]))
{
cout<<"Yes"<<"\n";
}
else{
cout<<"No"<<"\n";
}
return 0;
}
| [
"[email protected]"
] | |
d67c46c6e8f382e842d9a51cc052cfa696b189c7 | c45ed46065d8b78dac0dd7df1c95b944f34d1033 | /TC-SRM-574-div1-450/skydec.cpp | af52c839deb1726eb89546f88312d330129ba41f | [] | no_license | yzq986/cntt2016-hw1 | ed65a6b7ad3dfe86a4ff01df05b8fc4b7329685e | 12e799467888a0b3c99ae117cce84e8842d92337 | refs/heads/master | 2021-01-17T11:27:32.270012 | 2017-01-26T03:23:22 | 2017-01-26T03:23:22 | 84,036,200 | 0 | 0 | null | 2017-03-06T06:04:12 | 2017-03-06T06:04:12 | null | UTF-8 | C++ | false | false | 1,347 | cpp | #include<bits/stdc++.h>
#define rep(i,j,k) for(int i=(int)j;i<=(int)k;i++)
#define per(i,j,k) for(int i=(int)j;i>=(int)k;i--)
using namespace std;
typedef long long LL;
const int N=21;
int n;bool vis[N];
int a[N],m;
LL f[1<<18][19];
int sum[N];
LL Main(){
int S=0;
rep(i,1,m)S|=(1<<(a[i]-1));
f[S][a[m]]=1;
//显然每次选的2个点的中间只要都没被选就一定满足
//所以采用状压dp,记录哪些点被选了
rep(V,0,(1<<n)-1){
//求前缀和,方便求是否全部被选
rep(i,1,n)sum[i]=sum[i-1]+((V&(1<<(i-1)))>0);
rep(i,1,n)if(f[V][i]){
rep(j,1,n)if(!(V&(1<<(j-1)))){
int d1=min(i,j);
int d2=max(i,j);
//只要区间[d1+1,d2-1]和区间[d2+1,d1-1]没有被选的数就行
if(sum[d2-1]-sum[d1]==0)continue;
if(sum[n]-sum[d2]+sum[d1-1]==0)continue;
f[V|(1<<(j-1))][j]+=f[V][i];
}
}
}
//返回答案
LL ans=0;
rep(i,1,n)if((abs(i-a[1])!=1)&&(abs(i-a[1])!=n-1)){
ans+=f[(1<<n)-1][i];
}
return ans;
}
class PolygonTraversal{
public:
LL count(int n, vector<int> points){
//预处理
::n=n;
::m=points.size();
rep(i,1,points.size())a[i]=points[i-1];
return Main();
}
}gt;
| [
"SkyDec"
] | SkyDec |
28f77846232e663e40c174deabb801728c9729b1 | b11a84d4f5603cf222419eb9a7bf0aece7939645 | /CannonsApplication/CannonsApplication/edobjreader.h | 8fea06bfeac14c631729e69543eda4ac54d9bcf6 | [] | no_license | YvensFaos/CG_MSC_Discipline | 2615a279cd740498a79445fb667eb94629125083 | f1c9676b799e52465aac015f65061c0f235fd091 | refs/heads/master | 2021-05-27T17:07:57.671221 | 2014-12-16T13:44:28 | 2014-12-16T13:44:28 | 17,761,687 | 1 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 265 | h | #ifndef __ED_OBJ_READER__
#define __ED_OBJ_READER__
#include "edgeom.h"
class EDObjReader
{
public:
EDPoint* vertexesArray;
int vertexesSize;
EDTriangle* triangles;
int trianglesSize;
EDObjReader(char* path, char* filename);
~EDObjReader(void);
};
#endif | [
"[email protected]"
] | |
45d79baf9ecb70dc7813c392bbbcc00b1d988d48 | a5537887db2e5b1566c4453fa979b91b75d72bac | /assignment2019cpp-shimmieblum/Part4/TestTreeD.cpp | d32239938a7c026dbe60e42dedbedc5875f98ede | [] | no_license | shimmieblum/University-cwrk-Cpp | 2c4e6bc3972b7f3d86a59392abe760cfa6fdbd9a | a17e5cb86db922fbd714783e28209e1f3c082d5f | refs/heads/main | 2023-04-01T01:00:27.901746 | 2021-04-07T15:02:54 | 2021-04-07T15:02:54 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 4,004 | cpp | #include "treenode.h"
#include "tree.h"
#include <algorithm>
#include <iostream>
#include <sstream>
#include <vector>
using std::cout;
using std::endl;
using std::ostringstream;
using std::vector;
int main() {
int retval = 0;
{
BinarySearchTree<int> tree;
if (tree.begin() == tree.end()) {
cout << "1) Pass: the begin() and end() of an empty tree are the same\n";
} else {
++retval;
cout << "1) Fail: the begin() and end() of an empty tree are not the same\n";
}
}
{
BinarySearchTree<int> tree;
vector<int> putIn{5,1,2,6};
for (const int & e : putIn) {
tree.insert(e);
}
std::sort(putIn.begin(), putIn.end());
vector<int> was;
for (auto & e : tree) {
was.push_back(e);
}
if (was == putIn) {
cout << "2) Pass: added 5,1,2,6 to a tree, looped over it, and got 1,2,5,6\n";
} else {
++retval;
cout << "2) Fail: added 5,1,2,6 to a tree, looped over it, and got";
for (int & e : was) {
cout << " " << e;
}
cout << endl;
}
}
{
BinarySearchTree<int> tree;
vector<int> putIn{1,2,3};
for (const int & e : putIn) {
tree.insert(e);
}
if (tree.maxDepth() == 2) {
cout << "3) Pass: After inserting 1,2,3, max tree depth is 2: is balanced\n";
} else {
++retval;
cout << "3) Fail: After inserting 1,2,3, max tree depth is " << tree.maxDepth() << ": is unbalanced, should be 2\n";
}
}
{
BinarySearchTree<int> tree;
vector<int> putIn{1,2,3,4,5};
for (const int & e : putIn) {
tree.insert(e);
}
if (tree.maxDepth() == 3) {
cout << "4) Pass: After inserting 1,2,3,4,5, max tree depth is 3: is balanced\n";
} else {
++retval;
cout << "4) Fail: After inserting 1,2,3,4,5, max tree depth is " << tree.maxDepth() << ": is unbalanced, should be 3\n";
}
}
{
BinarySearchTree<int> tree;
vector<int> putIn{5,4,3,2,1};
for (const int & e : putIn) {
tree.insert(e);
}
if (tree.maxDepth() == 3) {
cout << "5) Pass: After inserting 5,4,3,2,1, max tree depth is 3: is balanced\n";
} else {
++retval;
cout << "5) Fail: After inserting 5,4,3,2,1, max tree depth is " << tree.maxDepth() << ": is unbalanced, should be 3\n";
}
}
{
BinarySearchTree<int> tree;
vector<int> putIn{1,3,2};
for (const int & e : putIn) {
tree.insert(e);
}
if (tree.maxDepth() == 2) {
cout << "6) Pass: After inserting 1,3,2, max tree depth is 2: is balanced\n";
} else {
++retval;
cout << "6) Fail: After inserting 1,3,2, max tree depth is " << tree.maxDepth() << ": is unbalanced, should be 2\n";
}
}
{
BinarySearchTree<int> tree;
vector<int> putIn{3,1,2};
for (const int & e : putIn) {
tree.insert(e);
}
if (tree.maxDepth() == 2) {
cout << "7) Pass: After inserting 3,1,2, max tree depth is 2: is balanced\n";
} else {
++retval;
cout << "7) Fail: After inserting 3,1,2, max tree depth is " << tree.maxDepth() << ": is unbalanced, should be 2\n";
}
}
return retval;
}
| [
"[email protected]"
] | |
1e258a4fb876b422c6cdb17919dd3bce9497a6e4 | 2141255f828800c1c74caecfed4d8e93690fe220 | /tree.h | 819f0650ed2bf079a156dc35fa67cf62b7c0ffe2 | [] | no_license | PVLam/tree | be49a626db6546f2ca625b6e82bad09911b89f59 | 1d3910f46d2ed365d3ab7a7798f7a328eeffc885 | refs/heads/master | 2020-03-30T16:43:10.665937 | 2018-10-09T15:01:11 | 2018-10-09T15:01:11 | 151,423,197 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 1,277 | h | #include "node.h"
#include "queue.h"
#ifndef tree_h
#define tree_h
template <class T>
class Tree
{
private:
Node<T> *root;
void InRaThuTuTruoc(Node<T> *root) const
{
if (root != 0)
{
InRaThuTuTruoc(root->l);
cout<<root->value<<"; ";
InRaThuTuTruoc(root->r);
}
};
public:
Tree()
{
root = 0;
};
void AddChild(T v)
{
Node<T> *n = new Node<T>;
n->value = v;
n->l = 0;
n->r = 0;
if (root == 0)
root = n;
else
{
Queue<Node<T> *> q;
Node<T> *p = root;
q.EnQueue(p);
while (!q.IsEmpty())
{
Node<T> *t = q.DeQueue();
if (t->l == 0)
{
t->l = n;
break;
}
else if (t->r == 0)
{
t->r = n;
break;
}
else
{
q.EnQueue(t->l);
q.EnQueue(t->r);
}
}
}
};
void PreOrder() const
{
InRaThuTuTruoc(root);
};
};
#endif
| [
"[email protected]"
] | |
5854199f3c38a92312c1306e620763b50a0d088e | 98d3e03ede2d84e527cfc84a798c74f3408267bc | /DS_Assignment_2/DS_Assignment_2/MyStackObject.h | ff9d0701ee603c7ea81209b55fb9429593de1a16 | [] | no_license | Williamson-Matt-NSCC/DS_Assigment2 | bafc940c65a307587cb5fda69c70d40b2d7e33da | ad2b1bb3e9fd6fcc1675ebaf4904b9a6f4b86a6f | refs/heads/master | 2021-06-12T22:29:30.274031 | 2017-02-28T20:57:35 | 2017-02-28T20:57:35 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 302 | h | #ifndef MY_STACK_OBJECT_H
#define MY_STACK_OBJECT_H
#include <string>
using namespace std;
class MyStackObject
{
public:
MyStackObject();
~MyStackObject(void);
void add(string coordVal);
void getTop();
void pop();
void seek();
void goBackToLastIntersection();
};
#endif // !MY_STACK_OBJECT | [
"[email protected]"
] | |
2d80815a2d3bf15abd996c2c16f68aa18e49486e | 93cdf00e1dc718851d96fe9bbc51d972b72c26bd | /src/SystemStats/StandardStat.h | 1c637394bb1be2ed52e7b37aa52c1d52702bcedb | [] | no_license | ptryfon/loxim-stats | 74e3310b46c7d61d01cc2ace9fee05a1287faf5b | d1048f3b348052186a962b9ab03596684024b7a9 | refs/heads/master | 2016-08-04T14:39:13.645024 | 2010-03-11T22:48:12 | 2010-03-11T22:48:12 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 3,299 | h | /**
* StandardStat.h
* @author: Pawel Tryfon (pt248444)
*
* The purpose of this file is to provide generic tool for gathering standard statistic data
* such as minimum, maximum, average and standard deviation of something.
*/
#ifndef STANDARD_STAT_H
#define STANDARD_STAT_H
#include <time.h>
#include <sys/time.h>
#include <Errors/ErrorConsole.h>
namespace SystemStatsLib {
/**
* StandardStat is a class gathering standard statistic data
* such as minimum, maximum, average and standard deviation of something.
*/
template <class T> class StandardStat {
private:
T sum;
T val_min;
T val_max;
unsigned long n;
T square_sum;
time_t start_time;
bool valid;
public:
StandardStat(): sum(0), val_min(0), val_max(0), n(0), square_sum(0),
start_time(time(NULL)), valid(false) {}
virtual void reset()
{
sum = 0;
val_max = 0;
val_min = 0;
n = 0;
square_sum = 0;
start_time = time(NULL);
valid = false;
}
void add(const T val)
{
debug_print(Errors::ErrorConsole::get_instance(Errors::EC_STATS), "StandardStat.add\n");
if (valid) {
sum += val;
val_min = std::min(val_min, val);
val_max = std::max(val_max, val);
square_sum += val * val;
}
else {
sum = val;
val_min = val;
val_max = val;
square_sum = val * val;
valid = true;
}
n++;
}
T get_min() const { return val_min; }
T get_max() const { return val_max; }
double get_avg() const { return (n != 0 ? (1.0 * sum)/n : 0); }
double get_stddev() const
{
double avg = get_avg();
return (n != 0 ? (1.0 * sum)/n - avg * avg : 0);
}
double get_avg_in_time() const
{
return 1.0 * sum/difftime(time(NULL), start_time);
}
};
template <class T> class StandardStatContainer {
private:
StandardStat<T> global_stdstat;
public:
StandardStatContainer(): global_stdstat(StandardStat<T>()) {}
virtual ~StandardStatContainer() {}
virtual void reset() { global_stdstat.reset(); }
virtual void add(const T val) { global_stdstat.add(val); }
T get_max() const { return global_stdstat.get_max(); }
T get_min() const { return global_stdstat.get_min(); }
double get_avg() const { return global_stdstat.get_avg(); }
double get_stddev() const { return global_stdstat.get_stddev(); }
double get_avg_in_time() const { return global_stdstat.get_stddev(); }
};
template <class T> class StandardStatOnePeriodContainer: public StandardStatContainer<T> {
private:
StandardStat<T> local_stdstat;
public:
StandardStatOnePeriodContainer(): StandardStatContainer<T>(),
local_stdstat() {}
virtual void reset()
{
StandardStatContainer<T>::reset();
local_stdstat.reset();
}
void local_reset() { local_stdstat.reset(); }
virtual void add(const T val)
{
StandardStatContainer<T>::add(val);
local_stdstat.add(val);
}
T get_local_max() const { return local_stdstat.get_max(); }
T get_local_min() const { return local_stdstat.get_min(); }
double get_local_avg() const { return local_stdstat.get_avg(); }
double get_local_stddev() const { return local_stdstat.get_stddev(); }
double get_local_avg_in_time() const { return local_stdstat.get_stddev(); }
};
}
#endif //STANDARD_STAT_H
| [
"[email protected]"
] | |
dcd81d011c4b74788f7e87a94dff678f738b51cc | d37a1d5e50105d82427e8bf3642ba6f3e56e06b8 | /DVR/HaohanITPlayer/public/Common/SysUtils/SonicStatus.cpp | a97a60381de2cb22f1bdc9d859837b34f97fcf1b | [] | no_license | 080278/dvrmd-filter | 176f4406dbb437fb5e67159b6cdce8c0f48fe0ca | b9461f3bf4a07b4c16e337e9c1d5683193498227 | refs/heads/master | 2016-09-10T21:14:44.669128 | 2011-10-17T09:18:09 | 2011-10-17T09:18:09 | 32,274,136 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 3,218 | cpp | //-----------------------------------------------------------------------------
// SonicStatus.cpp
// Copyright (c) 2001 - 2004, Haohanit. All rights reserved.
//-----------------------------------------------------------------------------
//SR FS: Reviewed [JAW 20040912]
//SR FS: Reviewed [wwt 20040914]
#include "SonicStatus.h"
#include "SonicException.h"
#include "SonicThread.h"
#include "time_utils.h"
#include "UnicodeUtilities.h"
#include "CDebugLogFile.h"
#include "DVDErrors.h"
SonicStatus::SonicStatus()
: m_message(),
m_position(0),
m_duration(0),
m_displayCounter(true),
m_cancelDisabled(false),
m_isCancelling(false)
{
}
SonicStatus::~SonicStatus()
{
}
bool SonicStatus::GetDisplayCounter() const
{
return m_displayCounter;
}
UInt64 SonicStatus::GetDuration() const
{
return m_duration;
}
const SonicMessage & SonicStatus::GetMessage() const
{
return m_message;
}
UInt64 SonicStatus::GetPosition() const
{
return m_position;
}
bool SonicStatus::IsCancelDisabled()
{
return m_cancelDisabled;
}
void SonicStatus::IsCancelDisabled(bool isDisabled)
{
m_cancelDisabled = isDisabled;
}
bool SonicStatus::IsCancelling()
{
return m_isCancelling;
}
void SonicStatus::IsCancelling(bool isCancel)
{
m_isCancelling = isCancel;
}
void SonicStatus::Reset()
{
m_message = SonicMessage();
m_position = 0;
m_duration = 0;
m_displayCounter = true;
m_cancelDisabled = false;
m_isCancelling = false;
Update();
}
void SonicStatus::Rundown(UInt64 milliseconds)
{
if (m_position < m_duration)
if (milliseconds == 0)
SetPosition(m_duration);
else
{
UInt64 steps = // number of steps
std::max(
(milliseconds + 50) / 100, // ~100 milliseconds per step
static_cast<UInt64>(1)); // at least one step
UInt64 size = // size of step
std::max(
(m_duration - m_position) / steps,
static_cast<UInt64>(1));
while (m_position < m_duration)
{
SetPosition(m_position + size);
SonicThread::Sleep(100);
}
}
}
void SonicStatus::SetDisplayCounter(bool displayCounter)
{
m_displayCounter = displayCounter;
}
void SonicStatus::SetDuration(UInt64 duration)
{
m_position = 0;
if (m_duration != duration)
{
m_duration = duration;
Update();
}
}
void SonicStatus::SetMessage(const SonicText & text)
{
if (m_message.GetNumber() != text.GetNumber())
{
m_message = text;
Update();
#ifdef _DEBUG
CDebugLogFile::Log(unicode::to_string(m_message.GetText()).c_str());
#endif
}
}
void SonicStatus::SetPosition(UInt64 position)
{
position = std::min(position, m_duration);
if (m_position != position)
{
m_position = position;
Update();
}
}
void SonicStatus::ThrowIfCancelling()
{
if (m_isCancelling) throw SonicException(DVDError::userCancel);
}
void SonicStatus::Update()
{
try
{
UpdateNotify();
}
catch (std::exception & x)
{
if (SonicException(&x).GetNumber() == DVDError::userCancel.GetNumber())
if (!IsCancelDisabled())
m_isCancelling = true;
else
return;
throw;
}
}
void SonicStatus::UpdateNotify()
{
}
| [
"[email protected]@27769579-7047-b306-4d6f-d36f87483bb3"
] | [email protected]@27769579-7047-b306-4d6f-d36f87483bb3 |
a1ce4b2211772a86cb9dbe66a3cd5a026a557a99 | ea4e3ac0966fe7b69f42eaa5a32980caa2248957 | /download/unzip/IONetworkingFamily/IONetworkingFamily-14/IONetworkMedium.cpp | 9a6305d54cb54347fc665eb17c992d477cd28a76 | [] | no_license | hyl946/opensource_apple | 36b49deda8b2f241437ed45113d624ad45aa6d5f | e0f41fa0d9d535d57bfe56a264b4b27b8f93d86a | refs/heads/master | 2023-02-26T16:27:25.343636 | 2020-03-29T08:50:45 | 2020-03-29T08:50:45 | 249,169,732 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 11,918 | cpp | /*
* Copyright (c) 1998-2000 Apple Computer, Inc. All rights reserved.
*
* @APPLE_LICENSE_HEADER_START@
*
* Copyright (c) 1999-2003 Apple Computer, Inc. All Rights Reserved.
*
* This file contains Original Code and/or Modifications of Original Code
* as defined in and that are subject to the Apple Public Source License
* Version 2.0 (the 'License'). You may not use this file except in
* compliance with the License. Please obtain a copy of the License at
* http://www.opensource.apple.com/apsl/ and read it before using this
* file.
*
* The Original Code and all software distributed under the License are
* distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
* EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
* INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
* Please see the License for the specific language governing rights and
* limitations under the License.
*
* @APPLE_LICENSE_HEADER_END@
*/
/*
* Copyright (c) 1999 Apple Computer, Inc. All rights reserved.
*
* IONetworkMedium.cpp
*
* HISTORY
*
*/
#include <IOKit/assert.h>
#include <IOKit/IOLib.h>
#include <libkern/c++/OSObject.h>
#include <libkern/c++/OSNumber.h>
#include <libkern/c++/OSCollectionIterator.h>
#include <libkern/c++/OSDictionary.h>
#include <libkern/c++/OSSerialize.h>
#include <IOKit/network/IONetworkMedium.h>
//---------------------------------------------------------------------------
// OSMetaClass macros.
#define super OSObject
OSDefineMetaClassAndStructors( IONetworkMedium, OSObject )
OSMetaClassDefineReservedUnused( IONetworkMedium, 0);
OSMetaClassDefineReservedUnused( IONetworkMedium, 1);
OSMetaClassDefineReservedUnused( IONetworkMedium, 2);
OSMetaClassDefineReservedUnused( IONetworkMedium, 3);
//---------------------------------------------------------------------------
// Initialize an IONetworkMedium instance.
//
// type: The medium type, the fields are encoded with bits defined in
// IONetworkMedium.h.
//
// speed: The maximum (or the only) link speed supported over this medium
// in units of bits per second.
//
// flags: An optional flag for the medium object.
// See IONetworkMedium.h for defined flags.
//
// index: An optional 32-bit index assigned by the caller. Drivers can use
// this to store an index or a pointer to a media table inside the
// driver, or it may map to a driver defined media type.
//
// name: An name to assign to this medium object. If 0, then a name
// will be created based on the medium type given using nameForType().
//
// Returns true on success, false otherwise.
bool IONetworkMedium::init(IOMediumType type,
UInt64 speed,
UInt32 flags,
UInt32 index,
const char * name)
{
if ( super::init() == false )
return false;
_type = type;
_flags = flags;
_speed = speed;
_index = index;
if (name)
_name = OSSymbol::withCString(name);
else
_name = IONetworkMedium::nameForType(type);
if (!_name)
return false;
return true;
}
//---------------------------------------------------------------------------
// Factory method which performs allocation and initialization
// of an IONetworkMedium instance.
//
// Returns an IONetworkMedium instance on success, or 0 otherwise.
IONetworkMedium * IONetworkMedium::medium(IOMediumType type,
UInt64 speed,
UInt32 flags,
UInt32 index,
const char * name)
{
IONetworkMedium * medium = new IONetworkMedium;
if (medium && !medium->init(type, speed, flags, index, name))
{
medium->release();
medium = 0;
}
return medium;
}
//---------------------------------------------------------------------------
// Free the IONetworkMedium instance.
void IONetworkMedium::free()
{
if (_name)
{
_name->release();
_name = 0;
}
super::free();
}
//---------------------------------------------------------------------------
// Return the assigned medium type.
IOMediumType IONetworkMedium::getType() const
{
return _type;
}
//---------------------------------------------------------------------------
// Return the medium flags.
UInt32 IONetworkMedium::getFlags() const
{
return _flags;
}
//---------------------------------------------------------------------------
// Return the maximum medium speed.
UInt64 IONetworkMedium::getSpeed() const
{
return _speed;
}
//---------------------------------------------------------------------------
// Return the assigned index.
UInt32 IONetworkMedium::getIndex() const
{
return _index;
}
//---------------------------------------------------------------------------
// Return the name for this instance.
const OSSymbol * IONetworkMedium::getName() const
{
return _name;
}
//---------------------------------------------------------------------------
// Given a medium type, create an unique OSymbol name for the medium.
// The caller is responsible for releasing the OSSymbol object returned.
//
// type: A medium type. See IONetworkMedium.h for type encoding.
//
// Returns an OSSymbol created based on the type provided.
const OSSymbol * IONetworkMedium::nameForType(IOMediumType type)
{
char buffer[10];
sprintf(buffer, "%08lx", type);
// Caller must remember to free the OSSymbol!
//
return OSSymbol::withCString(buffer);
}
//---------------------------------------------------------------------------
// Test for equality between two IONetworkMedium objects.
// Two IONetworkMedium objects are considered equal if
// they have similar properties assigned to them during initialization.
//
// medium: An IONetworkMedium to test against the IONetworkMedium
// object being called.
//
// Returns true if equal, false otherwise.
bool IONetworkMedium::isEqualTo(const IONetworkMedium * medium) const
{
return ( (medium->_name == _name) &&
(medium->_type == _type) &&
(medium->_flags == _flags) &&
(medium->_speed == _speed) &&
(medium->_index == _index) );
}
//---------------------------------------------------------------------------
// Test for equality between a IONetworkMedium object and an OSObject.
// The OSObject is considered equal to the IONetworkMedium object if the
// OSObject is an IONetworkMedium, and they have similar properties assigned
// to them during initialization.
//
// obj: An OSObject to test against the IONetworkMedium object being called.
//
// Returns true if equal, false otherwise.
bool IONetworkMedium::isEqualTo(const OSMetaClassBase * obj) const
{
IONetworkMedium * medium;
if ((medium = OSDynamicCast(IONetworkMedium, obj)))
return isEqualTo(medium);
else
return false;
}
//---------------------------------------------------------------------------
// Create an OSData containing an IOMediumDescriptor structure (not copied),
// and ask the OSData to serialize.
//
// s: An OSSerialize object to handle the serialization.
//
// Returns true on success, false otherwise.
static bool addNumberToDict(OSDictionary * dict,
const char * key,
UInt32 val,
UInt32 bits = 32)
{
OSNumber * num = OSNumber::withNumber(val, bits);
bool ret;
if ( num == 0 ) return false;
ret = dict->setObject( key, num );
num->release();
return ret;
}
bool IONetworkMedium::serialize(OSSerialize * s) const
{
bool ret;
OSDictionary * dict;
dict = OSDictionary::withCapacity(4);
if ( dict == 0 ) return false;
addNumberToDict(dict, kIOMediumType, getType());
addNumberToDict(dict, kIOMediumSpeed, getSpeed(), 64);
addNumberToDict(dict, kIOMediumIndex, getIndex());
addNumberToDict(dict, kIOMediumFlags, getFlags());
ret = dict->serialize(s);
dict->release();
return ret;
}
//---------------------------------------------------------------------------
// A helper function to add an IONetworkMedium object to a given dictionary.
// The name of the medium is used as the key for the new dictionary entry.
//
// dict: An OSDictionary object where the medium object should be added to.
// medium: The IONetworkMedium object to add to the dictionary.
//
// Returns true on success, false otherwise.
bool IONetworkMedium::addMedium(OSDictionary * dict,
const IONetworkMedium * medium)
{
// Arguments type checking.
//
if (!OSDynamicCast(OSDictionary, dict) ||
!OSDynamicCast(IONetworkMedium, medium))
return false;
return dict->setObject(medium->getName(), medium);
}
//---------------------------------------------------------------------------
// A helper function to remove an entry in a dictionary with a key that
// matches the name of the IONetworkMedium object provided.
//
// dict: An OSDictionary object where the medium object should be removed
// from.
// medium: The name of this medium object is used as the removal key.
void IONetworkMedium::removeMedium(OSDictionary * dict,
const IONetworkMedium * medium)
{
// Arguments type checking.
//
if (!OSDynamicCast(OSDictionary, dict) ||
!OSDynamicCast(IONetworkMedium, medium))
return;
dict->removeObject(medium->getName());
}
//---------------------------------------------------------------------------
// Iterate through a dictionary and return an IONetworkMedium entry that
// satisfies the matching criteria. Returns 0 if there is no match.
IONetworkMedium * IONetworkMedium::getMediumWithType(
const OSDictionary * dict,
IOMediumType type,
IOMediumType mask)
{
OSCollectionIterator * iter;
OSSymbol * key;
IONetworkMedium * medium;
IONetworkMedium * match = 0;
if (!dict) return 0;
// Shouldn't withCollection take an (const OSDictionary *) argument?
iter = OSCollectionIterator::withCollection((OSDictionary *) dict);
if (!iter)
return 0;
while ( (key = (OSSymbol *) iter->getNextObject()) )
{
medium = OSDynamicCast(IONetworkMedium, dict->getObject(key));
if (medium == 0) continue;
if ( ( (medium->getType() ^ type) & ~mask) == 0 )
{
match = medium;
break;
}
}
iter->release();
return match;
}
IONetworkMedium * IONetworkMedium::getMediumWithIndex(
const OSDictionary * dict,
UInt32 index,
UInt32 mask)
{
OSCollectionIterator * iter;
OSSymbol * key;
IONetworkMedium * medium;
IONetworkMedium * match = 0;
if (!dict) return 0;
// Shouldn't withCollection take an (const OSDictionary *) argument?
iter = OSCollectionIterator::withCollection((OSDictionary *) dict);
if (!iter)
return 0;
while ( (key = (OSSymbol *) iter->getNextObject()) )
{
medium = OSDynamicCast(IONetworkMedium, dict->getObject(key));
if (medium == 0) continue;
if ( ( (medium->getIndex() ^ index) & ~mask) == 0 )
{
match = medium;
break;
}
}
iter->release();
return match;
}
| [
"[email protected]"
] | |
2db4e6a8afa092a4ab64d0a9d21c1e6f4c146378 | c291f81e729d070421443a1553892db4a4edd58b | /src/iModMiddleware/iModDaemon/imodutile.cpp | 6b725e76c5bf80a7407a0f6b6564fc9606af811d | [] | no_license | lyh458/InteractionModels_DemoCode | 2ed94d96b4453953a2dbcdf8f53b2983f25d6510 | ef46a10245a1e2c002c489b48baca4487ce447a0 | refs/heads/master | 2020-07-15T19:57:58.678927 | 2017-10-20T16:38:56 | 2017-10-20T16:38:56 | 205,638,579 | 1 | 0 | null | 2019-09-01T06:30:33 | 2019-09-01T06:30:32 | null | UTF-8 | C++ | false | false | 1,884 | cpp | #include "imodutile.h"
#include <QtCore/QFile>
#include <QtCore/QSettings>
#include <QtCore/QTextStream>
#include <QtCore/QDate>
#include <QtCore/QDebug>
#include <QtCore/QTimer>
iModUtile::iModUtile(QObject *parent) : QObject(parent)
{
if(getenv("IMOD_ROOT"))
{
settingsfile = new QSettings( QString::fromStdString(getenv("IMOD_ROOT")) + "CPP/src/configuration.ini", QSettings::IniFormat, 0);
logfile = new QFile(settingsfile->value("iModMiddleware/LoggerFilepath").toString());
updatetimer = new QTimer(this);
connect(updatetimer, &QTimer::timeout, this, &iModUtile::slotUpdateSettingsFile);
updatetimer->setInterval(1000);
}
else
qDebug() << "Cant find enviroment variable IMOD_ROOT";
}
iModUtile::~iModUtile()
{
delete settingsfile;
delete logfile;
}
void iModUtile::writeLog(QString message)
{
logfile->open(QIODevice::Append);
if(logfile->isOpen())
{
QTextStream out(logfile);
message = "[" + QDate::currentDate().toString("dd.MM.yyyy") + " " + QTime::currentTime().toString("HH:mm:ss") + "] " + message + "\n";
out << message;
logfile->close();
}
else
{
qDebug() << "Logfile not open";
}
}
QVariant iModUtile::readSetting(QString path)
{
if(!updatetimer->isActive())
updatetimer->start();
return settingsfile->value(path, QVariant::Invalid);
}
QStringList iModUtile::getAllKeys(QString category)
{
QStringList keys = settingsfile->allKeys();
if(category == "")
return keys;
QStringList filterkeys;
foreach(QString s, keys)
{
if(s.startsWith(category + "/"))
filterkeys.append(s.split("/")[1]);
}
return filterkeys;
}
void iModUtile::slotUpdateSettingsFile()
{
// Imports changes made by other processes (in addition to writing the changes from this QSettings)
settingsfile->sync();
}
| [
"[email protected]"
] | |
4a61f800efe30e3e25b832670d6deba1ead64e7d | ee2c9b47da2d0bf6a514310a43f8639177bc0700 | /include/inviwo/core/io/serialization/serializebase.h | ac66de07357a5b5f8a0a9614b7f6f53b6552a6de | [
"BSD-2-Clause"
] | permissive | Ojaswi/inviwo | 2c1a5a050ad95e205118ef31c3dc18b040b77040 | bf4f144e3e4793ee11f308ab5f74ffd917e78389 | refs/heads/master | 2020-04-10T17:14:55.618976 | 2015-11-27T08:59:43 | 2015-11-27T09:00:42 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 8,933 | h | /*********************************************************************************
*
* Inviwo - Interactive Visualization Workshop
*
* Copyright (c) 2012-2015 Inviwo Foundation
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright notice, this
* list of conditions and the following disclaimer.
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
* ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
* (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
* LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
* ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*
*********************************************************************************/
#ifndef IVW_SERIALIZE_BASE_H
#define IVW_SERIALIZE_BASE_H
#pragma warning(push)
#pragma warning(disable: 4263)
#include <inviwo/core/io/serialization/ticpp.h>
#pragma warning(pop)
#include <inviwo/core/common/inviwocoredefine.h>
#include <inviwo/core/io/serialization/serializeconstants.h>
#include <inviwo/core/io/serialization/serializationexception.h>
#include <inviwo/core/util/factory.h>
#include <map>
#ifdef WIN32
#define WIN32_LEAN_AND_MEAN
#include <windows.h>
#endif
// include glm
#include <inviwo/core/util/glm.h>
namespace inviwo {
template <typename T>
struct ElementIdentifier {
virtual ~ElementIdentifier() = default;
virtual void setKey(TxElement*) = 0;
virtual bool operator()(const T* elem) const = 0;
};
template <typename T>
struct StandardIdentifier : public ElementIdentifier<T> {
typedef std::string (T::*funcPtr)() const;
StandardIdentifier(std::string key = "identifier", funcPtr ptr = &T::getIdentifier)
: ptr_(ptr), key_(key) {}
virtual void setKey(TxElement* node) { identifier_ = node->GetAttributeOrDefault(key_, ""); }
virtual bool operator()(const T* elem) const { return identifier_ == (*elem.*ptr_)(); }
private:
funcPtr ptr_;
std::string key_;
std::string identifier_;
};
class Serializable;
class IVW_CORE_API SerializeBase {
public:
/**
* \brief Base class for Serializer and Deserializer.
*
* This class consists of features that are common to both serializer
* and de-serializer. Some of them are reference data manager,
* (ticpp::Node) node switch and factory registration.
*
* @param allowReference disables or enables reference management schemes.
*/
SerializeBase(bool allowReference=true);
/**
* \brief Base class for Serializer and Deserializer.
*
* This class consists of features that are common to both serializer
* and de-serializer. Some of them are reference data manager,
* (ticpp::Node) node switch and factory registration.
*
* @param s object of similar type.
* @param allowReference disables or enables reference management schemes.
*/
SerializeBase(SerializeBase& s, bool allowReference=true);
/**
* \brief Base class for Serializer and Deserializer.
*
* This class consists of features that are common to both serializer
* and de-serializer. Some of them are reference data manager,
* (ticpp::Node) node switch and factory registration.
*
* @param fileName full path to xml file (for reading or writing).
* @param allowReference disables or enables reference management schemes.
*/
SerializeBase(std::string fileName, bool allowReference=true);
/**
* \brief Base class for Serializer and Deserializer.
*
* This class consists of features that are common to both serializer
* and de-serializer. Some of them are reference data manager,
* (ticpp::Node) node switch and factory registration.
*
* @param stream containing all xml data (for reading).
* @param path A path that will be used to decode the location of data during deserialization.
* @param allowReference disables or enables reference management schemes.
*/
SerializeBase(std::istream& stream, const std::string& path, bool allowReference=true);
/**
* \brief Destructor
*/
virtual ~SerializeBase();
/**
* \brief gets the xml file name.
*/
virtual const std::string& getFileName();
/**
* \brief Checks whether the given type is a primitive type.
*
* return true if type is one of following type:
* bool, char, signed int, unsigned int, float, double, long double, std::string
*
* @param type can be one of bool, char, signed int, unsigned int, float, double, long double, std::string
* @return true or false
*/
bool isPrimitiveType(const std::type_info& type) const;
/**
* \brief Registers all factories from all modules.
*/
virtual void registerFactories(void);
/**
* \brief For allocating objects such as processors, properties.. using registered factories.
*
* @param className is used by registered factories to allocate the required object.
* @return T* nullptr if allocation fails or className does not exist in any factories.
*/
template <typename T>
T* getRegisteredType(const std::string& className);
/**
* \brief For allocating objects that do not belong to any registered factories.
*
* @return T* Pointer to object of type T.
*/
template <typename T>
T* getNonRegisteredType();
class IVW_CORE_API NodeSwitch {
public:
/**
* \brief NodeSwitch helps track parent node during recursive/nested function calls.
*
* @param serializer reference to serializer or deserializer
* @param node //Parent (Ticpp Node) element.
*/
NodeSwitch(SerializeBase& serializer, TxElement* node, bool retrieveChild = true);
/**
* \brief NodeSwitch helps track parent node during recursive/nested function calls.
*
* @param serializer reference to serializer or deserializer
* @param key the child to switch to.
*/
NodeSwitch(SerializeBase& serializer, const std::string& key, bool retrieveChild = true);
/**
* \brief Destructor
*/
~NodeSwitch();
private:
SerializeBase& serializer_; //reference to serializer or deserializer
TxElement* storedNode_; //Parent (Ticpp Node) element.
bool storedRetrieveChild_;
};
struct IVW_CORE_API ReferenceData {
TxElement* node_; //Ticpp Node element.
bool isPointer_; //Used to differentiate pointer and object.
};
typedef std::pair<const void*, SerializeBase::ReferenceData> RefDataPair;
typedef std::multimap<const void*,ReferenceData> RefMap;
typedef std::vector<SerializeBase::ReferenceData> RefDataList;
class IVW_CORE_API ReferenceDataContainer {
public:
ReferenceDataContainer();
~ReferenceDataContainer();
size_t insert(const void* data, TxElement* node, bool isPointer=true);
size_t find(const void* data);
void* find(const std::string& key, const std::string& reference_or_id);
TxElement* nodeCopy(const void* data);
void setReferenceAttributes();
private:
RefMap referenceMap_;
int referenceCount_;
};
static std::string nodeToString(const TxElement& node);
protected:
friend class NodeSwitch;
std::vector<FactoryBase*> registeredFactories_;
std::string fileName_;
TxDocument doc_;
TxElement* rootElement_;
bool allowRef_;
bool retrieveChild_;
ReferenceDataContainer refDataContainer_;
};
template <typename T>
T* SerializeBase::getRegisteredType(const std::string& className) {
for (auto base : registeredFactories_) {
if (auto factory = dynamic_cast<Factory<T>*>(base)) {
if (auto data = factory->create(className)) return data.release();
}
}
return nullptr;
}
template <typename T>
T* SerializeBase::getNonRegisteredType() {
return util::defaultConstructType<T>();
}
} //namespace
#endif | [
"[email protected]"
] | |
3eb33a23d955f35bff664caa589b3a5b6bc94e35 | 4d3a846cb4151b86d0cc5aa9c6018cf5133941ee | /src/csp/exec.h | c122e0ada110ab7e01ad075de720fde6e3456be5 | [
"MIT"
] | permissive | skimmilk/cppchannel | 74aa3f43afb6e7de126b0b26f4910dd0411cc04d | f36be67feeda1e9b920c414e443af55998d0a23d | refs/heads/master | 2021-01-20T10:37:41.624906 | 2015-01-30T01:29:24 | 2015-01-30T01:29:24 | 18,801,007 | 1 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 4,030 | h | /*
* exec.h
*
* Created on: Sep 26, 2014
* Author: skim
*/
#ifndef EXEC_H_
#define EXEC_H_
#include <atomic>
#include <stdio.h>
#include <csp/pipe.h>
#include <sys/wait.h>
namespace csp{
// Reads FILE into message_stream
void read_file_to(FILE* fp, message_stream<csp::string>* writeto)
{
size_t len = 0;
ssize_t amt;
char* line = NULL;
while ((amt = getline(&line, &len, fp)) != -1)
{
if (!amt) continue;
if (line[amt - 1] == '\n')
amt--;
writeto->write(csp::string (line, amt));
}
if (line)
free(line);
}
// Reads from message_stream into FILE
void write_file_from(FILE* fp, message_stream<csp::string>* readfrom)
{
csp::string in;
while (readfrom->read(in))
{
in.push_back('\n');
if (fwrite(&in[0], 1, in.size(), fp) < in.size())
// Error
return;
}
}
// All open file descriptors need to be closed in the child process
void close_files()
{
// Close all that isn't STDIN or STDOUT
int maxfd=sysconf(_SC_OPEN_MAX);
for(int fd=3; fd<maxfd; fd++)
close(fd);
}
// Closes all open file descriptors and fires command
// Returns error
int fire_and_forget(const char* cmd, const char* flags, FILE** fp, pid_t& pid)
{
int pipes[2];
if (pipe(pipes))
return 1;
pid = fork();
if (pid == -1)
return 2;
// Child
if (!pid)
{
if (*flags == 'r')
{
close(pipes[0]);
if (pipes[1] != STDOUT_FILENO)
{
dup2(pipes[1], STDOUT_FILENO);
close(pipes[1]);
}
}
else
{
close(pipes[1]);
if (pipes[0] != STDIN_FILENO)
{
dup2(pipes[0], STDIN_FILENO);
close(pipes[0]);
}
}
close_files();
execl("/bin/sh", "/bin/sh", "-c", cmd, NULL);
perror("Could not run command");
}
// Parent
if (*flags == 'r')
{
*fp = fdopen(pipes[0], flags);
close(pipes[1]);
}
else
{
*fp = fdopen(pipes[1], flags);
close(pipes[0]);
}
return 0;
}
// Run a program and read its output
CSP_DECL(exec_r, csp::nothing, csp::string,
const char*, std::atomic<int>*)
(const char* cmd, std::atomic<int>* error)
{
// Open command for reading
FILE* fp;
pid_t pid;
if ((*error = fire_and_forget(cmd, "r", &fp, pid)) || !fp)
return;
read_file_to(fp, this->csp_output);
if (pclose(fp))
*error = 2;
waitpid(pid, NULL, 0);
}
// Run a program and write to its input
CSP_DECL(exec_w, csp::string, csp::nothing,
const char*, std::atomic<int>*)
(const char* cmd, std::atomic<int>* error)
{
// Open command for writing
FILE* fp;
pid_t pid;
if ((*error = fire_and_forget(cmd, "w", &fp, pid)) || !fp)
return;
write_file_from(fp, this->csp_input);
if (pclose(fp))
*error = 2;
waitpid(pid, NULL, 0);
}
// http://dzone.com/snippets/simple-popen2-implementation
// Bi-directional popen
int bipopen(const char *command, int *infp, int *outfp, pid_t& pid)
{
int p_stdin[2], p_stdout[2];
if (pipe(p_stdin) || pipe(p_stdout))
return 1;
pid = fork();
if (pid == -1)
return 2;
else if (pid == 0)
{
close(p_stdin[STDOUT_FILENO]);
dup2(p_stdin[STDIN_FILENO], STDIN_FILENO);
close(p_stdout[STDIN_FILENO]);
dup2(p_stdout[STDOUT_FILENO], STDOUT_FILENO);
close_files();
execl("/bin/sh", "/bin/sh", "-c", command, NULL);
exit(1);
}
close(p_stdin[STDIN_FILENO]);
close(p_stdout[STDOUT_FILENO]);
*infp = p_stdin[STDOUT_FILENO];
*outfp = p_stdout[STDIN_FILENO];
return 0;
}
void _bg_read(int fd, message_stream<csp::string>* stream)
{
FILE* fp = fdopen(fd, "r");
read_file_to(fp, stream);
pclose(fp);
}
// Run a program and read from and write to it
// cat(something) | exec_rw("grep stuff") | print();
CSP_DECL(exec_rw, csp::string, csp::string,
const char*, std::atomic<int>*)
(const char* cmd, std::atomic<int>* error)
{
int infd, outfd;
pid_t pid;
if ((*error = bipopen(cmd, &infd, &outfd, pid)))
return;
FILE* infp = fdopen(infd, "w");
if (!infp)
{
*error = 3;
close(infd);
close(outfd);
return;
}
auto thread = std::thread(_bg_read, outfd, csp_output);
write_file_from(infp, csp_input);
pclose(infp);
thread.join();
waitpid(pid, NULL, 0);
}
} /* namespace csp */
#endif /* EXEC_H_ */
| [
"[email protected]"
] | |
832305c135faf8c1f1b46cc472a1ae70fc5c0d21 | e679ae4684fcd9fe765491242016dd2f4ca279cd | /BWT/src/arithmetic_practice/arithmetic.cc | 0b0c180e274c426ea182670023aa1ec1f1b30488 | [] | no_license | TechBridgeWorld/BrailleWritingTutor | 23add5dac20238d6899a0da3ff63480576fb29f9 | 72d3c2d97105009587203c5ba6403861f3f22c81 | refs/heads/master | 2016-09-05T19:07:20.291296 | 2015-06-10T18:51:32 | 2015-06-10T18:51:32 | 12,303,955 | 1 | 1 | null | 2015-06-10T18:51:33 | 2013-08-22T18:01:10 | C++ | UTF-8 | C++ | false | false | 9,881 | cc | /* arithmetic.cc
* Madeleine Clute (mclute@andrew / [email protected])
* June 2013
*/
#include "arithmetic.h"
#include "Dots.h"
#include <math.h>
#define CORR_THRES 50 // for now
int math_mode;
static time_t last_pressed_time = time(0);
Arithmetic::Arithmetic(IOEventParser& my_iep,
const std::string& path_to_mapping_file, SoundsUtil* my_su, bool f) :
IBTApp(my_iep, path_to_mapping_file), su(my_su), iep(my_iep), math_s("./resources/Voice/math_sounds/", my_iep),
target_sequence('\0'), current_sequence('\0'), nomirror(f), dots1('\0'), dots2('\0'), choose_mode(1), choose_difficulty(0), difficulty_level(1),
digit_position(0), num_digits(0), number_sign(1), num_correct(0), last_button(0)
{
printf("starting practice\n");
su->saySound(math_s, "instructions_1");
su->saySound(math_s, "press_select");
srand(time(0)); // initializing the random seed
Fact_new();
}
Arithmetic::~Arithmetic()
{
delete su;
}
void Arithmetic::processEvent(IOEvent& e)
{
//std::cout << "processEvent" << std::endl;
if( e.type == IOEvent::BUTTON_DOWN && e.button == 0 && choose_mode == 0){
return;
}
else if (IOEvent::BUTTON_DOWN && e.button == 0 && choose_mode == 0){
sayArithmeticQuestion(false);
}
if (e.type == IOEvent::BUTTON_DOWN && choose_mode == 1) {
/* need to interpret it as mode switching */
if (e.button == 4) {
math_mode = ADDITION;
choose_mode = 0;
choose_difficulty = 1;
su->saySound(math_s, "sl_1");
Fact_new();
}
else if (e.button == 5) {
math_mode = SUBTRACTION;
choose_mode = 0;
choose_difficulty = 1;
su->saySound(math_s, "sl_2");
Fact_new();
}
else if (e.button == 6) {
math_mode = MULTIPLICATION;
choose_mode = 0;
su->saySound(math_s, "sl_3");
printf("saying three\n");
choose_difficulty = 1;
Fact_new();
}
else {
printf("malformed input, please select buttons 1, 2, or 3\n");
}
}
/* turn it off and "restart" the activity */
else if (e.type == IOEvent::BUTTON_DOWN && choose_difficulty == 1) {
if (e.button == 4){
difficulty_level = 1;
su->saySound(math_s, "sl_1");
}
else if (e.button == 5){
su->saySound(math_s, "sl_2");
difficulty_level = 2;
}
else if (e.button == 6){
difficulty_level = 3;
su->saySound(math_s, "sl_3");
}
printf("difficulty chosen\n");
choose_difficulty = 0;
su->saySound(math_s, "instructions_2");
Fact_new();
}
else if( e.type == IOEvent::STYLUS_DOWN ||
e.type == IOEvent::BUTTON_DOWN &&
((time(0) - last_pressed_time) >= 1))
{
last_pressed_time = time(0);
AP_attempt(getDot(e));
}
else if(time(0) == last_pressed_time && e.button == last_button){ // most likely a jammed button
return;
}
}
/* this fact new is split into 2 purposes. It's primary purpose is to
* generate new arithmetic facts, but it also serves as managing the control
* flow for entering in the mode and difficulty
*/
void Arithmetic::Fact_new()
{
clearArray(num1_array);
clearArray(response_array);
clearArray(num2_array);
/* this is the default behavior of fact_new */
if (!choose_mode && !choose_difficulty) {
printf("called fact new\n");
//generate a random number between 0 to 9
int result = -1; // ensures too small to start
int num1, num2;
int max = pow(10, difficulty_level); //# of digits allowed prop to diff
while(result >= max || result < 0){
num1 = (int) rand() % max;
num2 = (int) rand() % max;
if (math_mode == ADDITION) {
result = num1 + num2;
}
else if (math_mode == SUBTRACTION) {
result = num1 - num2;
}
else if (math_mode == MULTIPLICATION) {
result = num1 * num2;
}
}
current_sequence = '\0';
dots1 = convertToDotSequence(IBTApp::getCurrentCharset(), num1);
dots2 = convertToDotSequence(IBTApp::getCurrentCharset(), num2);
std::cout<<"question is "<<num1 << " and " << num2 <<std::endl;
std::cout<<"desired result is:"<<result<<std::endl;
printf("%d\n",result);
/* populate the digit array with the digits from the result and nums */
getDigits(result, response_array);
getDigits(num1, num1_array);
getDigits(num2, num2_array);
num_digits = (result == 0) ? (1) : ((int) log10(result) + 1);
sayArithmeticQuestion(false); // don't say answer yet
}
/* this is not default behavior and is to allow the user to select modes */
else if (choose_mode) {
su->saySound(math_s, "maths_instructions");
printf("please enter math mode:\n \
press button 1 for addition, \n \
press button 2 for subtraction, \n \
press button 3 for multiplication\n");
}
else if (choose_difficulty) {
su->saySound(math_s, "select_level");
printf("please select difficulty level 1-3 \n \
difficulty will increment every %d correct answers\n", CORR_THRES);
}
}
void Arithmetic::clearArray(int *a)
{
int i;
for (i = 0; i < MAX_DIGITS; i++){
a[i] = -1;
}
}
void Arithmetic::getDigits(int num, int *digit_array)
{
int digit, i;
int len = (num == 0) ? (1) : ((int) log10(num) + 1); // local use
printf("num digits %d", len);
for (i = 0; i < len; i++) {
digit = num % 10;
num /= 10;
digit_array[MAX_DIGITS - i - 1] = digit;
printf(" digit %d", digit);
}
printf("\n");
}
void Arithmetic::sayArithmeticQuestion(bool say_answer)
{
std::cout << "sayArithmeticQuestion" << std::endl;
static const Charset& charset = IBTApp::getCurrentCharset();
if (!say_answer) {
su->saySound(math_s, "please_write_the_number_that_is_equal_to");
}
/* sandwich the sounds together */
say_multidigit(num1_array); // say first number
if (math_mode == ADDITION) {
su->saySound(math_s, "plus");
}
else if (math_mode == SUBTRACTION) {
su->saySound(math_s, "minus");
}
else if (math_mode == MULTIPLICATION) {
su->saySound(math_s, "into");
}
else if (math_mode == DIVISION) {
su->saySound(math_s, "divided_by");
}
say_multidigit(num2_array); // say second number
if (say_answer){
su->saySound(math_s, "equals");
say_multidigit(response_array);
}
}
/* Splits the number into digits and says it by digit */
/* need to have global arrays that are passed by reference to
* the get digit function */
void Arithmetic::say_multidigit(int *a)
{
int i, n;
bool multidigit = false; // to know to say 0 if it on its own
char buf[50]; //
for (i = 0; i < MAX_DIGITS; i++){
if (a[i] != -1 && (a[i] != 0 || !multidigit)){ /* checking for how to say #'s */
switch (MAX_DIGITS - i) {
case 1:
sprintf(buf,"sl_%d", a[i]);
su->saySound(math_s, buf);
break;
case 2:
multidigit = true;
if (a[i] == 1) {
/* then special case */
n = 10 + a[i+1]; // get next digit
sprintf(buf, "sl_%d", n);
su->saySound(math_s, buf);
return;
}
else{
multidigit = true;
sprintf(buf,"sl_10_%d",a[i]);
su->saySound(math_s, buf);
}
break;
case 3:
sprintf(buf,"sl_%d", a[i]);
su->saySound(math_s, buf);
su->saySound(math_s, "hundred");
break;
case 4:
sprintf(buf,"sl_%d", a[i]);
su->saySound(math_s, buf);
su->saySound(math_s, "thousand");
default:
break;
}
}
}
}
void Arithmetic::AP_attempt(unsigned char dot)
{
su->sayNumber(getStudentVoice(), dot, nomirror);
int strt = MAX_DIGITS - num_digits; // where to start in array
i = 0;
current_target = response_array[strt + digit_position];
//check to see if they should be entering the braille number indicator
if (!number_sign){
target_sequence = convertToDotSequence(IBTApp::getCurrentCharset(),
current_target);
}
else {
target_sequence = MATH_FLAG;
}
//Check if user hit the right dot (ie, the dot exists in the target sequence)
if( my_dot_mask(dot) & target_sequence )
{
current_sequence = current_sequence | my_dot_mask(dot); //add the dot to the current on-going sequence
//are we done?
if( current_sequence == target_sequence )
{
printf("SHOULD BE DONE\n");
if ((digit_position >= num_digits - 1) && !number_sign){ //hanve reached the end of the #
printf("digits %d num digits %d\n", digit_position, num_digits);
digit_position = 0; // reset it
su->saySound(getTeacherVoice(), "tada"); // plays a nice sound
num_correct++;
sayArithmeticQuestion(true);
number_sign = 1; // set it back for next time
if (num_correct == CORR_THRES){
if (difficulty_level < 3){
difficulty_level++;
num_correct = 0; // reset
}
}
Fact_new();
}
else {
if (number_sign == 0){
digit_position++;
current_sequence = 0;
su->saySound(math_s, "good_next"); //asks for next digit
}
else{
current_sequence = 0;
number_sign = 0; // don't need it anymore
su->saySound(math_s, "good");
}
}
return;
}
}
else
{
su->saySound(getTeacherVoice(), "no");
current_sequence = 0; // so they can't just hit all 6 buttons and have it register as right
}
}
//++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
EnglishArithmeticPractice::EnglishArithmeticPractice(IOEventParser& my_iep) :
Arithmetic(my_iep, "./language_mapping_files/number_mapping.txt",
new EnglishSoundsUtil, false)
{
} | [
"[email protected]"
] | |
33fb09a0067abe559e824d7e74913c331d414b67 | eb2f8b3271e8ef9c9b092fcaeff3ff8307f7af86 | /Grade 10-12/2018 autumn/NOIP/NOIP2018提高组Day2程序包/answers/GD-0089/game/game.cpp | c7c6226f6f74f5cd9d9fa06af8e8a4c4865ac93f | [] | 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 | 910 | cpp | #include<bits/stdc++.h>
using namespace std;
int c[10][10],n,m;long long ans;
bool ok(int x,int y)
{
int xx=0,xy=0,yx=0,yy=0;
for (int i=0;i<n+m;i++)
{
int cx=(x>>i)&1,cy=(y>>i)&1;
if (cx>cy) {swap(x,y);break;}
if (cx<cy) break;
}
for (int i=0;i<n+m;i++)
{
int cx=(x>>i)&1,cy=(y>>i)&1;
if (cx==1) xy++;else xx++;
if (cy==1) yy++;else yx++;
if (c[xx][xy]<c[yx][yy]) return false;
if (c[xx][xy]>c[yx][yy]) return true;
}
return true;
}
bool check()
{
for (int i=0;i<1<<(n+m);i++)
{
for (int j=0;j<1<<(n+m);j++)
{
if (!ok(i,j)) return false;
}
}
return true;
}
int dfs(int x)
{
int ans=0;
if (x==n)
{
return check();
}
for (int i=0;i<(1<<(m));i++)
{
for (int j=0;j<m;j++)
c[x][j]=(i>>j)&1;
ans+=dfs(x+1);
}
return ans;
}
int main()
{
freopen("game.in","r",stdin);
freopen("game.out","w",stdout);
cin>>n>>m;
cout<<dfs(0)<<endl;
return 0;
}
| [
"[email protected]"
] | |
33800fc23c81c8e0b40fa57a01c19824607b7bce | ad562e2fb009310f6d2e848f895ae3da040eef69 | /Sources/Widgets/MVD/TableToTreeProxyModel.cpp | 0f24991958e28f332b5af77bb106d64ef87923a6 | [
"Apache-2.0"
] | permissive | ExplosiveBattery/JWCKnife | db5dbfa24528c0775dfa02910deafa41cb195992 | dddacf7776505e6aa47a7752bc08944ac4fc573a | refs/heads/master | 2021-07-11T19:58:19.447254 | 2018-10-30T11:10:48 | 2018-10-30T11:10:48 | 132,707,418 | 5 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 5,190 | cpp | #include "TableToTreeProxyModel.h"
//现在的问题就是第一层的内容不会被加上第二层的内容
TableToTreeProxyModel::TableToTreeProxyModel(QObject *parent)
: QAbstractProxyModel(parent)
{
}
TableToTreeProxyModel::~TableToTreeProxyModel() {
delete m_sqlQuery;
}
bool TableToTreeProxyModel::init(QString username) {
m_sqlQuery =new QSqlQuery(static_cast<QSqlTableModel*>(sourceModel())->database());
QString filter = static_cast<QSqlTableModel*>(sourceModel())->filter();
SQLErrorDetect(m_sqlQuery, "select Attribute from PlanCourses where " +filter+" group by Attribute;", "获取方案课程属性失败 in TableToTreeProxyModel::TableToTreeProxyModel(QObject *parent)");
while( m_sqlQuery->next() )
m_vData.append(m_sqlQuery->value(0).toString());
int i1=0;
for( auto data : m_vData ) {
SQLErrorDetect(m_sqlQuery, "select count(*) from PlanCourses where Attribute='"+data+"' and Username='"+username+"';", "获取方案课程指定属性的记录数量失败 in TableToTreeProxyModel::TableToTreeProxyModel(QObject *parent)");
m_sqlQuery->next();
m_vRowCount.append(m_sqlQuery->value(0).toInt());
m_vIndex.append(createIndex(i1++,0));
}
return !m_vData.isEmpty();
}
//QAbstractProxyModel 虚函数
//下面这个函数应该返回sourceModel中的ModelINdex
QModelIndex TableToTreeProxyModel::mapToSource(const QModelIndex &proxy_index) const {
if (!proxy_index.isValid()) return QModelIndex();
if( m_vIndex.contains(proxy_index) ) {
int index =proxy_index.row(), row=0;
for(int i1=0; i1<index ; ++i1) row+=m_vRowCount[i1];
return sourceModel()->index(row,1);
}else {
int index = m_vIndex.indexOf(*static_cast<QModelIndex*>(proxy_index.internalPointer()));
int row =proxy_index.row();
for(int i1=0; i1<index ; ++i1) row+=m_vRowCount[i1];
return sourceModel()->index(row, proxy_index.column()+2);
}
}
QModelIndex TableToTreeProxyModel::mapFromSource(const QModelIndex &source_index) const {
if (!source_index.isValid()) return QModelIndex();
int index =m_vData.indexOf(sourceModel()->data(source_index.sibling(source_index.row(),1)).toString());
if( source_index.column()==0 ) {
return QModelIndex();
}else if( source_index.column()==1 ) {
return createIndex(index,0);
}else {
int row =source_index.row();
for(int i1=0; i1<index ; ++i1) row-=m_vRowCount[i1];
return createIndex(row, source_index.column()-2, const_cast<QModelIndex*>(&m_vIndex[index]));
}
}
//QAbstractItemModel 虚函数
/*
* parent是一个临时变量,所以要根据parent找出index
*/
QModelIndex TableToTreeProxyModel::index(int row,int column,const QModelIndex &parent ) const {
if( !parent.isValid() ) {
if(row<m_vIndex.size()&&column==0) return m_vIndex[row];
else return QModelIndex();
}
int index =m_vIndex.indexOf(parent);
return createIndex(row, column, const_cast<QModelIndex*>(&m_vIndex[index]));
}
QModelIndex TableToTreeProxyModel::parent(const QModelIndex &proxy_child) const{
if( proxy_child.internalId()==0 ) return QModelIndex();
else return *static_cast<QModelIndex*>(proxy_child.internalPointer());
}
int TableToTreeProxyModel::rowCount(const QModelIndex &proxy_parent) const{
if( !proxy_parent.isValid() ) return m_vData.size();
else return m_vRowCount[m_vIndex.indexOf(proxy_parent)];
}
/* columnCount只能是一个数
* 子项与父项是一个column
* if( !proxy_parent.isValid() ) return 1;
* else return 4;
* 上述代码就相当于仅仅return 1;
*/
int TableToTreeProxyModel::columnCount(const QModelIndex &proxy_parent) const{
return 4;
}
bool TableToTreeProxyModel::hasChildren(const QModelIndex &parent) const {
return m_vIndex.contains(parent)||!parent.isValid();
}
Qt::ItemFlags TableToTreeProxyModel::flags(const QModelIndex &index) const {
if(m_vIndex.contains(index)||!index.isValid()) return Qt::ItemIsSelectable|Qt::ItemIsEnabled;
else return Qt::ItemIsSelectable|Qt::ItemIsEnabled|Qt::ItemNeverHasChildren;
}
QVariant TableToTreeProxyModel::data(const QModelIndex &proxy_index, int role) const{
if(proxy_index.column()==0 && proxy_index.parent().isValid() && role==Qt::DisplayRole)
return sourceModel()->data(mapToSource(proxy_index),role).toString()=="1"?QVariant("[已修]"):"";
return sourceModel()->data(mapToSource(proxy_index),role);
}
QVariant TableToTreeProxyModel::headerData(int section, Qt::Orientation orientation, int role) const {
if (orientation == Qt::Horizontal && role == Qt::DisplayRole)
switch (section) {
case 0:
return "修读情况";
case 1:
return "课程号";
case 2:
return "课程名";
case 3:
return "学分";
default:
break;
}
return QVariant();
}
void TableToTreeProxyModel::clear() {
m_vData.clear();
m_vIndex.clear();
m_vRowCount.clear();
}
| [
"[email protected]"
] | |
2af13da183e595f132b5ad785b5a802aac5052ed | 3ad968797a01a4e4b9a87e2200eeb3fb47bf269a | /Atl Internals 2e src/Chapter 05/MathDll/stdafx.cpp | de3abcf1866631fb72c082625bd91ee7c7c076c6 | [] | no_license | LittleDrogon/MFC-Examples | 403641a1ae9b90e67fe242da3af6d9285698f10b | 1d8b5d19033409cd89da3aba3ec1695802c89a7a | refs/heads/main | 2023-03-20T22:53:02.590825 | 2020-12-31T09:56:37 | 2020-12-31T09:56:37 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 198 | cpp | // stdafx.cpp : source file that includes just the standard includes
// MathDll.pch will be the pre-compiled header
// stdafx.obj will contain the pre-compiled type information
#include "stdafx.h"
| [
"[email protected]"
] | |
41596235c956efd1174f7a142ff779e2753f23ef | 0b03fede82f753478b03ded55d348f9708e56401 | /sunlightcoin4/src/pubkey.cpp | 1ceb340c42bdd54daa4493250cb2930f0a41989b | [
"MIT"
] | permissive | RollingBack/sunlightcoin | e146d953827632e5226309c5da20eb77269774e6 | 3f02a11a428016fb836090dd6db633b5efbd2bbb | refs/heads/master | 2023-04-30T06:02:05.350145 | 2021-05-15T12:31:17 | 2021-05-15T12:31:17 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 3,904 | cpp | // Copyright (c) 2009-2014 The Sunlightcoin Core developers
// Distributed under the MIT software license, see the accompanying
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
#include "pubkey.h"
#include "eccryptoverify.h"
#ifdef USE_SECP256K1
#include <secp256k1.h>
#else
#include "ecwrapper.h"
#endif
bool CPubKey::Verify(const uint256 &hash, const std::vector<unsigned char>& vchSig) const {
if (!IsValid())
return false;
#ifdef USE_SECP256K1
if (secp256k1_ecdsa_verify((const unsigned char*)&hash, &vchSig[0], vchSig.size(), begin(), size()) != 1)
return false;
#else
CECKey key;
if (!key.SetPubKey(begin(), size()))
return false;
if (!key.Verify(hash, vchSig))
return false;
#endif
return true;
}
bool CPubKey::RecoverCompact(const uint256 &hash, const std::vector<unsigned char>& vchSig) {
if (vchSig.size() != 65)
return false;
int recid = (vchSig[0] - 27) & 3;
bool fComp = ((vchSig[0] - 27) & 4) != 0;
#ifdef USE_SECP256K1
int pubkeylen = 65;
if (!secp256k1_ecdsa_recover_compact((const unsigned char*)&hash, &vchSig[1], (unsigned char*)begin(), &pubkeylen, fComp, recid))
return false;
assert((int)size() == pubkeylen);
#else
CECKey key;
if (!key.Recover(hash, &vchSig[1], recid))
return false;
std::vector<unsigned char> pubkey;
key.GetPubKey(pubkey, fComp);
Set(pubkey.begin(), pubkey.end());
#endif
return true;
}
bool CPubKey::IsFullyValid() const {
if (!IsValid())
return false;
#ifdef USE_SECP256K1
if (!secp256k1_ecdsa_pubkey_verify(begin(), size()))
return false;
#else
CECKey key;
if (!key.SetPubKey(begin(), size()))
return false;
#endif
return true;
}
bool CPubKey::Decompress() {
if (!IsValid())
return false;
#ifdef USE_SECP256K1
int clen = size();
int ret = secp256k1_ecdsa_pubkey_decompress((unsigned char*)begin(), &clen);
assert(ret);
assert(clen == (int)size());
#else
CECKey key;
if (!key.SetPubKey(begin(), size()))
return false;
std::vector<unsigned char> pubkey;
key.GetPubKey(pubkey, false);
Set(pubkey.begin(), pubkey.end());
#endif
return true;
}
bool CPubKey::Derive(CPubKey& pubkeyChild, unsigned char ccChild[32], unsigned int nChild, const unsigned char cc[32]) const {
assert(IsValid());
assert((nChild >> 31) == 0);
assert(begin() + 33 == end());
unsigned char out[64];
BIP32Hash(cc, nChild, *begin(), begin()+1, out);
memcpy(ccChild, out+32, 32);
#ifdef USE_SECP256K1
pubkeyChild = *this;
bool ret = secp256k1_ecdsa_pubkey_tweak_add((unsigned char*)pubkeyChild.begin(), pubkeyChild.size(), out);
#else
CECKey key;
bool ret = key.SetPubKey(begin(), size());
ret &= key.TweakPublic(out);
std::vector<unsigned char> pubkey;
key.GetPubKey(pubkey, true);
pubkeyChild.Set(pubkey.begin(), pubkey.end());
#endif
return ret;
}
void CExtPubKey::Encode(unsigned char code[74]) const {
code[0] = nDepth;
memcpy(code+1, vchFingerprint, 4);
code[5] = (nChild >> 24) & 0xFF; code[6] = (nChild >> 16) & 0xFF;
code[7] = (nChild >> 8) & 0xFF; code[8] = (nChild >> 0) & 0xFF;
memcpy(code+9, vchChainCode, 32);
assert(pubkey.size() == 33);
memcpy(code+41, pubkey.begin(), 33);
}
void CExtPubKey::Decode(const unsigned char code[74]) {
nDepth = code[0];
memcpy(vchFingerprint, code+1, 4);
nChild = (code[5] << 24) | (code[6] << 16) | (code[7] << 8) | code[8];
memcpy(vchChainCode, code+9, 32);
pubkey.Set(code+41, code+74);
}
bool CExtPubKey::Derive(CExtPubKey &out, unsigned int nChild) const {
out.nDepth = nDepth + 1;
CKeyID id = pubkey.GetID();
memcpy(&out.vchFingerprint[0], &id, 4);
out.nChild = nChild;
return pubkey.Derive(out.pubkey, out.vchChainCode, nChild, vchChainCode);
}
| [
"[email protected]"
] | |
6e2d0d9089dea97315b7c3d885d1d8539807a1c9 | 09e5cfe06e437989a2ccf2aeecb9c73eb998a36c | /modules/cctbx_project/iotbx/mtz/dataset_bpl.cpp | edd8eab3eec625c1954b3f0923024b97caf8be43 | [
"BSD-3-Clause-LBNL",
"BSD-3-Clause"
] | permissive | jorgediazjr/dials-dev20191018 | b81b19653624cee39207b7cefb8dfcb2e99b79eb | 77d66c719b5746f37af51ad593e2941ed6fbba17 | refs/heads/master | 2020-08-21T02:48:54.719532 | 2020-01-25T01:41:37 | 2020-01-25T01:41:37 | 216,089,955 | 0 | 1 | BSD-3-Clause | 2020-01-25T01:41:39 | 2019-10-18T19:03:17 | Python | UTF-8 | C++ | false | false | 1,676 | cpp | #include <cctbx/boost_python/flex_fwd.h>
#include <boost/python/class.hpp>
#include <boost/python/args.hpp>
#include <boost/python/return_arg.hpp>
#include <iotbx/mtz/batch.h>
#include <iotbx/mtz/column.h>
#include <scitbx/array_family/boost_python/shared_wrapper.h>
namespace iotbx { namespace mtz {
namespace {
struct dataset_wrappers
{
typedef dataset w_t;
static void
wrap()
{
using namespace boost::python;
class_<w_t>("dataset", no_init)
.def(init<crystal const&, int>((
arg("mtz_crystal"), arg("i_dataset"))))
.def("mtz_crystal", &w_t::mtz_crystal)
.def("i_dataset", &w_t::i_dataset)
.def("mtz_object", &w_t::mtz_object)
.def("id", &w_t::id)
.def("set_id", &w_t::set_id, (arg("id")), return_self<>())
.def("name", &w_t::name)
.def("set_name", &w_t::set_name, (arg("new_name")), return_self<>())
.def("wavelength", &w_t::wavelength)
.def("set_wavelength", &w_t::set_wavelength, (arg("new_wavelength")),
return_self<>())
.def("n_batches", &w_t::n_batches)
.def("batches", &w_t::batches)
.def("add_batch", &w_t::add_batch)
.def("n_columns", &w_t::n_columns)
.def("columns", &w_t::columns)
.def("add_column", &w_t::add_column, (
arg("label"), arg("type")))
;
{
scitbx::af::boost_python::shared_wrapper<w_t>::wrap(
"shared_dataset");
}
}
};
void
wrap_all()
{
dataset_wrappers::wrap();
}
} // namespace <anonymous>
namespace boost_python {
void
wrap_dataset() { wrap_all(); }
}}} // namespace iotbx::mtz::boost_python
| [
"[email protected]"
] | |
fba030fc4c0d07e61f1ef9827050b4555f68576a | 4e71065fa9f81d3ada64a4807fdf288be0fefd33 | /weex_core/Source/include/JavaScriptCore/assembler/ARMv7Assembler.h | f15a1b705914c1511f7eff0bd5476171347774dd | [
"Apache-2.0",
"MIT",
"BSD-3-Clause"
] | permissive | acton393/incubator-weex | c2d9fc7f80eed5d95b054ab6f1af42f8ef9cd47a | c7dd6c76fe726a4413b08d3c895c91d521d01755 | refs/heads/master | 2021-03-24T12:15:30.348499 | 2019-01-07T03:19:18 | 2019-01-07T03:19:18 | 83,516,877 | 2 | 2 | Apache-2.0 | 2018-04-02T09:19:33 | 2017-03-01T05:48:09 | JavaScript | UTF-8 | C++ | false | false | 107,355 | h | /**
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
* KIND, either express or implied. See the License for the
* specific language governing permissions and limitations
* under the License.
*/
#pragma once
#if ENABLE(ASSEMBLER) && CPU(ARM_THUMB2)
#include "AssemblerBuffer.h"
#include "AssemblerCommon.h"
#include <limits.h>
#include <wtf/Assertions.h>
#include <wtf/Vector.h>
#include <stdint.h>
namespace JSC {
namespace ARMRegisters {
#define FOR_EACH_CPU_REGISTER(V) \
FOR_EACH_CPU_GPREGISTER(V) \
FOR_EACH_CPU_SPECIAL_REGISTER(V) \
FOR_EACH_CPU_FPREGISTER(V)
// The following are defined as pairs of the following value:
// 1. type of the storage needed to save the register value by the JIT probe.
// 2. name of the register.
#define FOR_EACH_CPU_GPREGISTER(V) \
V(void*, r0) \
V(void*, r1) \
V(void*, r2) \
V(void*, r3) \
V(void*, r4) \
V(void*, r5) \
V(void*, r6) \
V(void*, r7) \
V(void*, r8) \
V(void*, r9) \
V(void*, r10) \
V(void*, r11) \
V(void*, ip) \
V(void*, sp) \
V(void*, lr) \
V(void*, pc)
#define FOR_EACH_CPU_SPECIAL_REGISTER(V) \
V(void*, apsr) \
V(void*, fpscr) \
#define FOR_EACH_CPU_FPREGISTER(V) \
V(double, d0) \
V(double, d1) \
V(double, d2) \
V(double, d3) \
V(double, d4) \
V(double, d5) \
V(double, d6) \
V(double, d7) \
V(double, d8) \
V(double, d9) \
V(double, d10) \
V(double, d11) \
V(double, d12) \
V(double, d13) \
V(double, d14) \
V(double, d15) \
V(double, d16) \
V(double, d17) \
V(double, d18) \
V(double, d19) \
V(double, d20) \
V(double, d21) \
V(double, d22) \
V(double, d23) \
V(double, d24) \
V(double, d25) \
V(double, d26) \
V(double, d27) \
V(double, d28) \
V(double, d29) \
V(double, d30) \
V(double, d31)
typedef enum {
#define DECLARE_REGISTER(_type, _regName) _regName,
FOR_EACH_CPU_GPREGISTER(DECLARE_REGISTER)
#undef DECLARE_REGISTER
fp = r7, // frame pointer
sb = r9, // static base
sl = r10, // stack limit
r12 = ip,
r13 = sp,
r14 = lr,
r15 = pc
} RegisterID;
typedef enum {
s0,
s1,
s2,
s3,
s4,
s5,
s6,
s7,
s8,
s9,
s10,
s11,
s12,
s13,
s14,
s15,
s16,
s17,
s18,
s19,
s20,
s21,
s22,
s23,
s24,
s25,
s26,
s27,
s28,
s29,
s30,
s31,
} FPSingleRegisterID;
typedef enum {
#define DECLARE_REGISTER(_type, _regName) _regName,
FOR_EACH_CPU_FPREGISTER(DECLARE_REGISTER)
#undef DECLARE_REGISTER
} FPDoubleRegisterID;
typedef enum {
q0,
q1,
q2,
q3,
q4,
q5,
q6,
q7,
q8,
q9,
q10,
q11,
q12,
q13,
q14,
q15,
q16,
q17,
q18,
q19,
q20,
q21,
q22,
q23,
q24,
q25,
q26,
q27,
q28,
q29,
q30,
q31,
} FPQuadRegisterID;
inline FPSingleRegisterID asSingle(FPDoubleRegisterID reg)
{
ASSERT(reg < d16);
return (FPSingleRegisterID)(reg << 1);
}
inline FPDoubleRegisterID asDouble(FPSingleRegisterID reg)
{
ASSERT(!(reg & 1));
return (FPDoubleRegisterID)(reg >> 1);
}
} // namespace ARMRegisters
class ARMv7Assembler;
class ARMThumbImmediate {
friend class ARMv7Assembler;
typedef uint8_t ThumbImmediateType;
static const ThumbImmediateType TypeInvalid = 0;
static const ThumbImmediateType TypeEncoded = 1;
static const ThumbImmediateType TypeUInt16 = 2;
typedef union {
int16_t asInt;
struct {
unsigned imm8 : 8;
unsigned imm3 : 3;
unsigned i : 1;
unsigned imm4 : 4;
};
// If this is an encoded immediate, then it may describe a shift, or a pattern.
struct {
unsigned shiftValue7 : 7;
unsigned shiftAmount : 5;
};
struct {
unsigned immediate : 8;
unsigned pattern : 4;
};
} ThumbImmediateValue;
// byte0 contains least significant bit; not using an array to make client code endian agnostic.
typedef union {
int32_t asInt;
struct {
uint8_t byte0;
uint8_t byte1;
uint8_t byte2;
uint8_t byte3;
};
} PatternBytes;
ALWAYS_INLINE static void countLeadingZerosPartial(uint32_t& value, int32_t& zeros, const int N)
{
if (value & ~((1 << N) - 1)) /* check for any of the top N bits (of 2N bits) are set */
value >>= N; /* if any were set, lose the bottom N */
else /* if none of the top N bits are set, */
zeros += N; /* then we have identified N leading zeros */
}
static int32_t countLeadingZeros(uint32_t value)
{
if (!value)
return 32;
int32_t zeros = 0;
countLeadingZerosPartial(value, zeros, 16);
countLeadingZerosPartial(value, zeros, 8);
countLeadingZerosPartial(value, zeros, 4);
countLeadingZerosPartial(value, zeros, 2);
countLeadingZerosPartial(value, zeros, 1);
return zeros;
}
ARMThumbImmediate()
: m_type(TypeInvalid)
{
m_value.asInt = 0;
}
ARMThumbImmediate(ThumbImmediateType type, ThumbImmediateValue value)
: m_type(type)
, m_value(value)
{
}
ARMThumbImmediate(ThumbImmediateType type, uint16_t value)
: m_type(TypeUInt16)
{
// Make sure this constructor is only reached with type TypeUInt16;
// this extra parameter makes the code a little clearer by making it
// explicit at call sites which type is being constructed
ASSERT_UNUSED(type, type == TypeUInt16);
m_value.asInt = value;
}
public:
static ARMThumbImmediate makeEncodedImm(uint32_t value)
{
ThumbImmediateValue encoding;
encoding.asInt = 0;
// okay, these are easy.
if (value < 256) {
encoding.immediate = value;
encoding.pattern = 0;
return ARMThumbImmediate(TypeEncoded, encoding);
}
int32_t leadingZeros = countLeadingZeros(value);
// if there were 24 or more leading zeros, then we'd have hit the (value < 256) case.
ASSERT(leadingZeros < 24);
// Given a number with bit fields Z:B:C, where count(Z)+count(B)+count(C) == 32,
// Z are the bits known zero, B is the 8-bit immediate, C are the bits to check for
// zero. count(B) == 8, so the count of bits to be checked is 24 - count(Z).
int32_t rightShiftAmount = 24 - leadingZeros;
if (value == ((value >> rightShiftAmount) << rightShiftAmount)) {
// Shift the value down to the low byte position. The assign to
// shiftValue7 drops the implicit top bit.
encoding.shiftValue7 = value >> rightShiftAmount;
// The endoded shift amount is the magnitude of a right rotate.
encoding.shiftAmount = 8 + leadingZeros;
return ARMThumbImmediate(TypeEncoded, encoding);
}
PatternBytes bytes;
bytes.asInt = value;
if ((bytes.byte0 == bytes.byte1) && (bytes.byte0 == bytes.byte2) && (bytes.byte0 == bytes.byte3)) {
encoding.immediate = bytes.byte0;
encoding.pattern = 3;
return ARMThumbImmediate(TypeEncoded, encoding);
}
if ((bytes.byte0 == bytes.byte2) && !(bytes.byte1 | bytes.byte3)) {
encoding.immediate = bytes.byte0;
encoding.pattern = 1;
return ARMThumbImmediate(TypeEncoded, encoding);
}
if ((bytes.byte1 == bytes.byte3) && !(bytes.byte0 | bytes.byte2)) {
encoding.immediate = bytes.byte1;
encoding.pattern = 2;
return ARMThumbImmediate(TypeEncoded, encoding);
}
return ARMThumbImmediate();
}
static ARMThumbImmediate makeUInt12(int32_t value)
{
return (!(value & 0xfffff000))
? ARMThumbImmediate(TypeUInt16, (uint16_t)value)
: ARMThumbImmediate();
}
static ARMThumbImmediate makeUInt12OrEncodedImm(int32_t value)
{
// If this is not a 12-bit unsigned it, try making an encoded immediate.
return (!(value & 0xfffff000))
? ARMThumbImmediate(TypeUInt16, (uint16_t)value)
: makeEncodedImm(value);
}
// The 'make' methods, above, return a !isValid() value if the argument
// cannot be represented as the requested type. This methods is called
// 'get' since the argument can always be represented.
static ARMThumbImmediate makeUInt16(uint16_t value)
{
return ARMThumbImmediate(TypeUInt16, value);
}
bool isValid()
{
return m_type != TypeInvalid;
}
uint16_t asUInt16() const { return m_value.asInt; }
// These methods rely on the format of encoded byte values.
bool isUInt3() { return !(m_value.asInt & 0xfff8); }
bool isUInt4() { return !(m_value.asInt & 0xfff0); }
bool isUInt5() { return !(m_value.asInt & 0xffe0); }
bool isUInt6() { return !(m_value.asInt & 0xffc0); }
bool isUInt7() { return !(m_value.asInt & 0xff80); }
bool isUInt8() { return !(m_value.asInt & 0xff00); }
bool isUInt9() { return (m_type == TypeUInt16) && !(m_value.asInt & 0xfe00); }
bool isUInt10() { return (m_type == TypeUInt16) && !(m_value.asInt & 0xfc00); }
bool isUInt12() { return (m_type == TypeUInt16) && !(m_value.asInt & 0xf000); }
bool isUInt16() { return m_type == TypeUInt16; }
uint8_t getUInt3() { ASSERT(isUInt3()); return m_value.asInt; }
uint8_t getUInt4() { ASSERT(isUInt4()); return m_value.asInt; }
uint8_t getUInt5() { ASSERT(isUInt5()); return m_value.asInt; }
uint8_t getUInt6() { ASSERT(isUInt6()); return m_value.asInt; }
uint8_t getUInt7() { ASSERT(isUInt7()); return m_value.asInt; }
uint8_t getUInt8() { ASSERT(isUInt8()); return m_value.asInt; }
uint16_t getUInt9() { ASSERT(isUInt9()); return m_value.asInt; }
uint16_t getUInt10() { ASSERT(isUInt10()); return m_value.asInt; }
uint16_t getUInt12() { ASSERT(isUInt12()); return m_value.asInt; }
uint16_t getUInt16() { ASSERT(isUInt16()); return m_value.asInt; }
bool isEncodedImm() { return m_type == TypeEncoded; }
private:
ThumbImmediateType m_type;
ThumbImmediateValue m_value;
};
typedef enum {
SRType_LSL,
SRType_LSR,
SRType_ASR,
SRType_ROR,
SRType_RRX = SRType_ROR
} ARMShiftType;
class ShiftTypeAndAmount {
friend class ARMv7Assembler;
public:
ShiftTypeAndAmount()
{
m_u.type = (ARMShiftType)0;
m_u.amount = 0;
}
ShiftTypeAndAmount(ARMShiftType type, unsigned amount)
{
m_u.type = type;
m_u.amount = amount & 31;
}
unsigned lo4() { return m_u.lo4; }
unsigned hi4() { return m_u.hi4; }
private:
union {
struct {
unsigned lo4 : 4;
unsigned hi4 : 4;
};
struct {
unsigned type : 2;
unsigned amount : 6;
};
} m_u;
};
class ARMv7Assembler {
public:
typedef ARMRegisters::RegisterID RegisterID;
typedef ARMRegisters::FPSingleRegisterID FPSingleRegisterID;
typedef ARMRegisters::FPDoubleRegisterID FPDoubleRegisterID;
typedef ARMRegisters::FPQuadRegisterID FPQuadRegisterID;
typedef FPDoubleRegisterID FPRegisterID;
static constexpr RegisterID firstRegister() { return ARMRegisters::r0; }
static constexpr RegisterID lastRegister() { return ARMRegisters::r13; }
static constexpr FPRegisterID firstFPRegister() { return ARMRegisters::d0; }
static constexpr FPRegisterID lastFPRegister() { return ARMRegisters::d31; }
// (HS, LO, HI, LS) -> (AE, B, A, BE)
// (VS, VC) -> (O, NO)
typedef enum {
ConditionEQ, // Zero / Equal.
ConditionNE, // Non-zero / Not equal.
ConditionHS, ConditionCS = ConditionHS, // Unsigned higher or same.
ConditionLO, ConditionCC = ConditionLO, // Unsigned lower.
ConditionMI, // Negative.
ConditionPL, // Positive or zero.
ConditionVS, // Overflowed.
ConditionVC, // Not overflowed.
ConditionHI, // Unsigned higher.
ConditionLS, // Unsigned lower or same.
ConditionGE, // Signed greater than or equal.
ConditionLT, // Signed less than.
ConditionGT, // Signed greater than.
ConditionLE, // Signed less than or equal.
ConditionAL, // Unconditional / Always execute.
ConditionInvalid
} Condition;
#define JUMP_ENUM_WITH_SIZE(index, value) (((value) << 3) | (index))
#define JUMP_ENUM_SIZE(jump) ((jump) >> 3)
enum JumpType { JumpFixed = JUMP_ENUM_WITH_SIZE(0, 0),
JumpNoCondition = JUMP_ENUM_WITH_SIZE(1, 5 * sizeof(uint16_t)),
JumpCondition = JUMP_ENUM_WITH_SIZE(2, 6 * sizeof(uint16_t)),
JumpNoConditionFixedSize = JUMP_ENUM_WITH_SIZE(3, 5 * sizeof(uint16_t)),
JumpConditionFixedSize = JUMP_ENUM_WITH_SIZE(4, 6 * sizeof(uint16_t))
};
enum JumpLinkType {
LinkInvalid = JUMP_ENUM_WITH_SIZE(0, 0),
LinkJumpT1 = JUMP_ENUM_WITH_SIZE(1, sizeof(uint16_t)),
LinkJumpT2 = JUMP_ENUM_WITH_SIZE(2, sizeof(uint16_t)),
LinkJumpT3 = JUMP_ENUM_WITH_SIZE(3, 2 * sizeof(uint16_t)),
LinkJumpT4 = JUMP_ENUM_WITH_SIZE(4, 2 * sizeof(uint16_t)),
LinkConditionalJumpT4 = JUMP_ENUM_WITH_SIZE(5, 3 * sizeof(uint16_t)),
LinkBX = JUMP_ENUM_WITH_SIZE(6, 5 * sizeof(uint16_t)),
LinkConditionalBX = JUMP_ENUM_WITH_SIZE(7, 6 * sizeof(uint16_t))
};
class LinkRecord {
public:
LinkRecord(intptr_t from, intptr_t to, JumpType type, Condition condition)
{
data.realTypes.m_from = from;
data.realTypes.m_to = to;
data.realTypes.m_type = type;
data.realTypes.m_linkType = LinkInvalid;
data.realTypes.m_condition = condition;
}
void operator=(const LinkRecord& other)
{
data.copyTypes.content[0] = other.data.copyTypes.content[0];
data.copyTypes.content[1] = other.data.copyTypes.content[1];
data.copyTypes.content[2] = other.data.copyTypes.content[2];
}
intptr_t from() const { return data.realTypes.m_from; }
void setFrom(intptr_t from) { data.realTypes.m_from = from; }
intptr_t to() const { return data.realTypes.m_to; }
JumpType type() const { return data.realTypes.m_type; }
JumpLinkType linkType() const { return data.realTypes.m_linkType; }
void setLinkType(JumpLinkType linkType) { ASSERT(data.realTypes.m_linkType == LinkInvalid); data.realTypes.m_linkType = linkType; }
Condition condition() const { return data.realTypes.m_condition; }
private:
union {
struct RealTypes {
intptr_t m_from : 31;
intptr_t m_to : 31;
JumpType m_type : 8;
JumpLinkType m_linkType : 8;
Condition m_condition : 16;
} realTypes;
struct CopyTypes {
uint32_t content[3];
} copyTypes;
COMPILE_ASSERT(sizeof(RealTypes) == sizeof(CopyTypes), LinkRecordCopyStructSizeEqualsRealStruct);
} data;
};
ARMv7Assembler()
: m_indexOfLastWatchpoint(INT_MIN)
, m_indexOfTailOfLastWatchpoint(INT_MIN)
{
}
AssemblerBuffer& buffer() { return m_formatter.m_buffer; }
private:
// ARMv7, Appx-A.6.3
static bool BadReg(RegisterID reg)
{
return (reg == ARMRegisters::sp) || (reg == ARMRegisters::pc);
}
uint32_t singleRegisterMask(FPSingleRegisterID rdNum, int highBitsShift, int lowBitShift)
{
uint32_t rdMask = (rdNum >> 1) << highBitsShift;
if (rdNum & 1)
rdMask |= 1 << lowBitShift;
return rdMask;
}
uint32_t doubleRegisterMask(FPDoubleRegisterID rdNum, int highBitShift, int lowBitsShift)
{
uint32_t rdMask = (rdNum & 0xf) << lowBitsShift;
if (rdNum & 16)
rdMask |= 1 << highBitShift;
return rdMask;
}
typedef enum {
OP_ADD_reg_T1 = 0x1800,
OP_SUB_reg_T1 = 0x1A00,
OP_ADD_imm_T1 = 0x1C00,
OP_SUB_imm_T1 = 0x1E00,
OP_MOV_imm_T1 = 0x2000,
OP_CMP_imm_T1 = 0x2800,
OP_ADD_imm_T2 = 0x3000,
OP_SUB_imm_T2 = 0x3800,
OP_AND_reg_T1 = 0x4000,
OP_EOR_reg_T1 = 0x4040,
OP_TST_reg_T1 = 0x4200,
OP_RSB_imm_T1 = 0x4240,
OP_CMP_reg_T1 = 0x4280,
OP_ORR_reg_T1 = 0x4300,
OP_MVN_reg_T1 = 0x43C0,
OP_ADD_reg_T2 = 0x4400,
OP_MOV_reg_T1 = 0x4600,
OP_BLX = 0x4700,
OP_BX = 0x4700,
OP_STR_reg_T1 = 0x5000,
OP_STRH_reg_T1 = 0x5200,
OP_STRB_reg_T1 = 0x5400,
OP_LDRSB_reg_T1 = 0x5600,
OP_LDR_reg_T1 = 0x5800,
OP_LDRH_reg_T1 = 0x5A00,
OP_LDRB_reg_T1 = 0x5C00,
OP_LDRSH_reg_T1 = 0x5E00,
OP_STR_imm_T1 = 0x6000,
OP_LDR_imm_T1 = 0x6800,
OP_STRB_imm_T1 = 0x7000,
OP_LDRB_imm_T1 = 0x7800,
OP_STRH_imm_T1 = 0x8000,
OP_LDRH_imm_T1 = 0x8800,
OP_STR_imm_T2 = 0x9000,
OP_LDR_imm_T2 = 0x9800,
OP_ADD_SP_imm_T1 = 0xA800,
OP_ADD_SP_imm_T2 = 0xB000,
OP_SUB_SP_imm_T1 = 0xB080,
OP_PUSH_T1 = 0xB400,
OP_POP_T1 = 0xBC00,
OP_BKPT = 0xBE00,
OP_IT = 0xBF00,
OP_NOP_T1 = 0xBF00,
} OpcodeID;
typedef enum {
OP_B_T1 = 0xD000,
OP_B_T2 = 0xE000,
OP_POP_T2 = 0xE8BD,
OP_PUSH_T2 = 0xE92D,
OP_AND_reg_T2 = 0xEA00,
OP_TST_reg_T2 = 0xEA10,
OP_ORR_reg_T2 = 0xEA40,
OP_ORR_S_reg_T2 = 0xEA50,
OP_ASR_imm_T1 = 0xEA4F,
OP_LSL_imm_T1 = 0xEA4F,
OP_LSR_imm_T1 = 0xEA4F,
OP_ROR_imm_T1 = 0xEA4F,
OP_MVN_reg_T2 = 0xEA6F,
OP_EOR_reg_T2 = 0xEA80,
OP_ADD_reg_T3 = 0xEB00,
OP_ADD_S_reg_T3 = 0xEB10,
OP_SUB_reg_T2 = 0xEBA0,
OP_SUB_S_reg_T2 = 0xEBB0,
OP_CMP_reg_T2 = 0xEBB0,
OP_VMOV_CtoD = 0xEC00,
OP_VMOV_DtoC = 0xEC10,
OP_FSTS = 0xED00,
OP_VSTR = 0xED00,
OP_FLDS = 0xED10,
OP_VLDR = 0xED10,
OP_VMOV_CtoS = 0xEE00,
OP_VMOV_StoC = 0xEE10,
OP_VMUL_T2 = 0xEE20,
OP_VADD_T2 = 0xEE30,
OP_VSUB_T2 = 0xEE30,
OP_VDIV = 0xEE80,
OP_VABS_T2 = 0xEEB0,
OP_VCMP = 0xEEB0,
OP_VCVT_FPIVFP = 0xEEB0,
OP_VMOV_T2 = 0xEEB0,
OP_VMOV_IMM_T2 = 0xEEB0,
OP_VMRS = 0xEEB0,
OP_VNEG_T2 = 0xEEB0,
OP_VSQRT_T1 = 0xEEB0,
OP_VCVTSD_T1 = 0xEEB0,
OP_VCVTDS_T1 = 0xEEB0,
OP_B_T3a = 0xF000,
OP_B_T4a = 0xF000,
OP_AND_imm_T1 = 0xF000,
OP_TST_imm = 0xF010,
OP_ORR_imm_T1 = 0xF040,
OP_MOV_imm_T2 = 0xF040,
OP_MVN_imm = 0xF060,
OP_EOR_imm_T1 = 0xF080,
OP_ADD_imm_T3 = 0xF100,
OP_ADD_S_imm_T3 = 0xF110,
OP_CMN_imm = 0xF110,
OP_ADC_imm = 0xF140,
OP_SUB_imm_T3 = 0xF1A0,
OP_SUB_S_imm_T3 = 0xF1B0,
OP_CMP_imm_T2 = 0xF1B0,
OP_RSB_imm_T2 = 0xF1C0,
OP_RSB_S_imm_T2 = 0xF1D0,
OP_ADD_imm_T4 = 0xF200,
OP_MOV_imm_T3 = 0xF240,
OP_SUB_imm_T4 = 0xF2A0,
OP_MOVT = 0xF2C0,
OP_UBFX_T1 = 0xF3C0,
OP_NOP_T2a = 0xF3AF,
OP_DMB_T1a = 0xF3BF,
OP_STRB_imm_T3 = 0xF800,
OP_STRB_reg_T2 = 0xF800,
OP_LDRB_imm_T3 = 0xF810,
OP_LDRB_reg_T2 = 0xF810,
OP_STRH_imm_T3 = 0xF820,
OP_STRH_reg_T2 = 0xF820,
OP_LDRH_reg_T2 = 0xF830,
OP_LDRH_imm_T3 = 0xF830,
OP_STR_imm_T4 = 0xF840,
OP_STR_reg_T2 = 0xF840,
OP_LDR_imm_T4 = 0xF850,
OP_LDR_reg_T2 = 0xF850,
OP_STRB_imm_T2 = 0xF880,
OP_LDRB_imm_T2 = 0xF890,
OP_STRH_imm_T2 = 0xF8A0,
OP_LDRH_imm_T2 = 0xF8B0,
OP_STR_imm_T3 = 0xF8C0,
OP_LDR_imm_T3 = 0xF8D0,
OP_LDRSB_reg_T2 = 0xF910,
OP_LDRSH_reg_T2 = 0xF930,
OP_LDREXD_T1 = 0xE8D0,
OP_STREXD_T1 = 0xE8C0,
OP_LSL_reg_T2 = 0xFA00,
OP_LSR_reg_T2 = 0xFA20,
OP_ASR_reg_T2 = 0xFA40,
OP_ROR_reg_T2 = 0xFA60,
OP_CLZ = 0xFAB0,
OP_SMULL_T1 = 0xFB80,
#if HAVE(ARM_IDIV_INSTRUCTIONS)
OP_SDIV_T1 = 0xFB90,
OP_UDIV_T1 = 0xFBB0,
#endif
} OpcodeID1;
typedef enum {
OP_VADD_T2b = 0x0A00,
OP_VDIVb = 0x0A00,
OP_FLDSb = 0x0A00,
OP_VLDRb = 0x0A00,
OP_VMOV_IMM_T2b = 0x0A00,
OP_VMOV_T2b = 0x0A40,
OP_VMUL_T2b = 0x0A00,
OP_FSTSb = 0x0A00,
OP_VSTRb = 0x0A00,
OP_VMOV_StoCb = 0x0A10,
OP_VMOV_CtoSb = 0x0A10,
OP_VMOV_DtoCb = 0x0A10,
OP_VMOV_CtoDb = 0x0A10,
OP_VMRSb = 0x0A10,
OP_VABS_T2b = 0x0A40,
OP_VCMPb = 0x0A40,
OP_VCVT_FPIVFPb = 0x0A40,
OP_VNEG_T2b = 0x0A40,
OP_VSUB_T2b = 0x0A40,
OP_VSQRT_T1b = 0x0A40,
OP_VCVTSD_T1b = 0x0A40,
OP_VCVTDS_T1b = 0x0A40,
OP_NOP_T2b = 0x8000,
OP_DMB_SY_T1b = 0x8F5F,
OP_DMB_ISHST_T1b = 0x8F5A,
OP_B_T3b = 0x8000,
OP_B_T4b = 0x9000,
OP_LDREXD_T1b = 0x007F,
OP_STREXD_T1b = 0x0070,
} OpcodeID2;
struct FourFours {
FourFours(unsigned f3, unsigned f2, unsigned f1, unsigned f0)
{
m_u.f0 = f0;
m_u.f1 = f1;
m_u.f2 = f2;
m_u.f3 = f3;
}
union {
unsigned value;
struct {
unsigned f0 : 4;
unsigned f1 : 4;
unsigned f2 : 4;
unsigned f3 : 4;
};
} m_u;
};
class ARMInstructionFormatter;
// false means else!
static bool ifThenElseConditionBit(Condition condition, bool isIf)
{
return isIf ? (condition & 1) : !(condition & 1);
}
static uint8_t ifThenElse(Condition condition, bool inst2if, bool inst3if, bool inst4if)
{
int mask = (ifThenElseConditionBit(condition, inst2if) << 3)
| (ifThenElseConditionBit(condition, inst3if) << 2)
| (ifThenElseConditionBit(condition, inst4if) << 1)
| 1;
ASSERT((condition != ConditionAL) || !(mask & (mask - 1)));
return (condition << 4) | mask;
}
static uint8_t ifThenElse(Condition condition, bool inst2if, bool inst3if)
{
int mask = (ifThenElseConditionBit(condition, inst2if) << 3)
| (ifThenElseConditionBit(condition, inst3if) << 2)
| 2;
ASSERT((condition != ConditionAL) || !(mask & (mask - 1)));
return (condition << 4) | mask;
}
static uint8_t ifThenElse(Condition condition, bool inst2if)
{
int mask = (ifThenElseConditionBit(condition, inst2if) << 3)
| 4;
ASSERT((condition != ConditionAL) || !(mask & (mask - 1)));
return (condition << 4) | mask;
}
static uint8_t ifThenElse(Condition condition)
{
int mask = 8;
return (condition << 4) | mask;
}
public:
void adc(RegisterID rd, RegisterID rn, ARMThumbImmediate imm)
{
// Rd can only be SP if Rn is also SP.
ASSERT((rd != ARMRegisters::sp) || (rn == ARMRegisters::sp));
ASSERT(rd != ARMRegisters::pc);
ASSERT(rn != ARMRegisters::pc);
ASSERT(imm.isEncodedImm());
m_formatter.twoWordOp5i6Imm4Reg4EncodedImm(OP_ADC_imm, rn, rd, imm);
}
void add(RegisterID rd, RegisterID rn, ARMThumbImmediate imm)
{
// Rd can only be SP if Rn is also SP.
ASSERT((rd != ARMRegisters::sp) || (rn == ARMRegisters::sp));
ASSERT(rd != ARMRegisters::pc);
ASSERT(rn != ARMRegisters::pc);
ASSERT(imm.isValid());
if (rn == ARMRegisters::sp && imm.isUInt16()) {
ASSERT(!(imm.getUInt16() & 3));
if (!(rd & 8) && imm.isUInt10()) {
m_formatter.oneWordOp5Reg3Imm8(OP_ADD_SP_imm_T1, rd, static_cast<uint8_t>(imm.getUInt10() >> 2));
return;
} else if ((rd == ARMRegisters::sp) && imm.isUInt9()) {
m_formatter.oneWordOp9Imm7(OP_ADD_SP_imm_T2, static_cast<uint8_t>(imm.getUInt9() >> 2));
return;
}
} else if (!((rd | rn) & 8)) {
if (imm.isUInt3()) {
m_formatter.oneWordOp7Reg3Reg3Reg3(OP_ADD_imm_T1, (RegisterID)imm.getUInt3(), rn, rd);
return;
} else if ((rd == rn) && imm.isUInt8()) {
m_formatter.oneWordOp5Reg3Imm8(OP_ADD_imm_T2, rd, imm.getUInt8());
return;
}
}
if (imm.isEncodedImm())
m_formatter.twoWordOp5i6Imm4Reg4EncodedImm(OP_ADD_imm_T3, rn, rd, imm);
else {
ASSERT(imm.isUInt12());
m_formatter.twoWordOp5i6Imm4Reg4EncodedImm(OP_ADD_imm_T4, rn, rd, imm);
}
}
ALWAYS_INLINE void add(RegisterID rd, RegisterID rn, RegisterID rm, ShiftTypeAndAmount shift)
{
ASSERT((rd != ARMRegisters::sp) || (rn == ARMRegisters::sp));
ASSERT(rd != ARMRegisters::pc);
ASSERT(rn != ARMRegisters::pc);
ASSERT(!BadReg(rm));
m_formatter.twoWordOp12Reg4FourFours(OP_ADD_reg_T3, rn, FourFours(shift.hi4(), rd, shift.lo4(), rm));
}
// NOTE: In an IT block, add doesn't modify the flags register.
ALWAYS_INLINE void add(RegisterID rd, RegisterID rn, RegisterID rm)
{
if (rd == ARMRegisters::sp) {
mov(rd, rn);
rn = rd;
}
if (rd == rn)
m_formatter.oneWordOp8RegReg143(OP_ADD_reg_T2, rm, rd);
else if (rd == rm)
m_formatter.oneWordOp8RegReg143(OP_ADD_reg_T2, rn, rd);
else if (!((rd | rn | rm) & 8))
m_formatter.oneWordOp7Reg3Reg3Reg3(OP_ADD_reg_T1, rm, rn, rd);
else
add(rd, rn, rm, ShiftTypeAndAmount());
}
// Not allowed in an IT (if then) block.
ALWAYS_INLINE void add_S(RegisterID rd, RegisterID rn, ARMThumbImmediate imm)
{
// Rd can only be SP if Rn is also SP.
ASSERT((rd != ARMRegisters::sp) || (rn == ARMRegisters::sp));
ASSERT(rd != ARMRegisters::pc);
ASSERT(rn != ARMRegisters::pc);
ASSERT(imm.isEncodedImm());
if (!((rd | rn) & 8)) {
if (imm.isUInt3()) {
m_formatter.oneWordOp7Reg3Reg3Reg3(OP_ADD_imm_T1, (RegisterID)imm.getUInt3(), rn, rd);
return;
} else if ((rd == rn) && imm.isUInt8()) {
m_formatter.oneWordOp5Reg3Imm8(OP_ADD_imm_T2, rd, imm.getUInt8());
return;
}
}
m_formatter.twoWordOp5i6Imm4Reg4EncodedImm(OP_ADD_S_imm_T3, rn, rd, imm);
}
// Not allowed in an IT (if then) block?
ALWAYS_INLINE void add_S(RegisterID rd, RegisterID rn, RegisterID rm, ShiftTypeAndAmount shift)
{
ASSERT((rd != ARMRegisters::sp) || (rn == ARMRegisters::sp));
ASSERT(rd != ARMRegisters::pc);
ASSERT(rn != ARMRegisters::pc);
ASSERT(!BadReg(rm));
m_formatter.twoWordOp12Reg4FourFours(OP_ADD_S_reg_T3, rn, FourFours(shift.hi4(), rd, shift.lo4(), rm));
}
// Not allowed in an IT (if then) block.
ALWAYS_INLINE void add_S(RegisterID rd, RegisterID rn, RegisterID rm)
{
if (!((rd | rn | rm) & 8))
m_formatter.oneWordOp7Reg3Reg3Reg3(OP_ADD_reg_T1, rm, rn, rd);
else
add_S(rd, rn, rm, ShiftTypeAndAmount());
}
ALWAYS_INLINE void ARM_and(RegisterID rd, RegisterID rn, ARMThumbImmediate imm)
{
ASSERT(!BadReg(rd));
ASSERT(!BadReg(rn));
ASSERT(imm.isEncodedImm());
m_formatter.twoWordOp5i6Imm4Reg4EncodedImm(OP_AND_imm_T1, rn, rd, imm);
}
ALWAYS_INLINE void ARM_and(RegisterID rd, RegisterID rn, RegisterID rm, ShiftTypeAndAmount shift)
{
ASSERT(!BadReg(rd));
ASSERT(!BadReg(rn));
ASSERT(!BadReg(rm));
m_formatter.twoWordOp12Reg4FourFours(OP_AND_reg_T2, rn, FourFours(shift.hi4(), rd, shift.lo4(), rm));
}
ALWAYS_INLINE void ARM_and(RegisterID rd, RegisterID rn, RegisterID rm)
{
if ((rd == rn) && !((rd | rm) & 8))
m_formatter.oneWordOp10Reg3Reg3(OP_AND_reg_T1, rm, rd);
else if ((rd == rm) && !((rd | rn) & 8))
m_formatter.oneWordOp10Reg3Reg3(OP_AND_reg_T1, rn, rd);
else
ARM_and(rd, rn, rm, ShiftTypeAndAmount());
}
ALWAYS_INLINE void asr(RegisterID rd, RegisterID rm, int32_t shiftAmount)
{
ASSERT(!BadReg(rd));
ASSERT(!BadReg(rm));
ShiftTypeAndAmount shift(SRType_ASR, shiftAmount);
m_formatter.twoWordOp16FourFours(OP_ASR_imm_T1, FourFours(shift.hi4(), rd, shift.lo4(), rm));
}
ALWAYS_INLINE void asr(RegisterID rd, RegisterID rn, RegisterID rm)
{
ASSERT(!BadReg(rd));
ASSERT(!BadReg(rn));
ASSERT(!BadReg(rm));
m_formatter.twoWordOp12Reg4FourFours(OP_ASR_reg_T2, rn, FourFours(0xf, rd, 0, rm));
}
// Only allowed in IT (if then) block if last instruction.
ALWAYS_INLINE AssemblerLabel b()
{
m_formatter.twoWordOp16Op16(OP_B_T4a, OP_B_T4b);
return m_formatter.label();
}
// Only allowed in IT (if then) block if last instruction.
ALWAYS_INLINE AssemblerLabel blx(RegisterID rm)
{
ASSERT(rm != ARMRegisters::pc);
m_formatter.oneWordOp8RegReg143(OP_BLX, rm, (RegisterID)8);
return m_formatter.label();
}
// Only allowed in IT (if then) block if last instruction.
ALWAYS_INLINE AssemblerLabel bx(RegisterID rm)
{
m_formatter.oneWordOp8RegReg143(OP_BX, rm, (RegisterID)0);
return m_formatter.label();
}
void bkpt(uint8_t imm = 0)
{
m_formatter.oneWordOp8Imm8(OP_BKPT, imm);
}
static bool isBkpt(void* address)
{
unsigned short expected = OP_BKPT;
unsigned short immediateMask = 0xff;
unsigned short candidateInstruction = *reinterpret_cast<unsigned short*>(address);
return (candidateInstruction & ~immediateMask) == expected;
}
ALWAYS_INLINE void clz(RegisterID rd, RegisterID rm)
{
ASSERT(!BadReg(rd));
ASSERT(!BadReg(rm));
m_formatter.twoWordOp12Reg4FourFours(OP_CLZ, rm, FourFours(0xf, rd, 8, rm));
}
ALWAYS_INLINE void cmn(RegisterID rn, ARMThumbImmediate imm)
{
ASSERT(rn != ARMRegisters::pc);
ASSERT(imm.isEncodedImm());
m_formatter.twoWordOp5i6Imm4Reg4EncodedImm(OP_CMN_imm, rn, (RegisterID)0xf, imm);
}
ALWAYS_INLINE void cmp(RegisterID rn, ARMThumbImmediate imm)
{
ASSERT(rn != ARMRegisters::pc);
ASSERT(imm.isEncodedImm());
if (!(rn & 8) && imm.isUInt8())
m_formatter.oneWordOp5Reg3Imm8(OP_CMP_imm_T1, rn, imm.getUInt8());
else
m_formatter.twoWordOp5i6Imm4Reg4EncodedImm(OP_CMP_imm_T2, rn, (RegisterID)0xf, imm);
}
ALWAYS_INLINE void cmp(RegisterID rn, RegisterID rm, ShiftTypeAndAmount shift)
{
ASSERT(rn != ARMRegisters::pc);
ASSERT(!BadReg(rm));
m_formatter.twoWordOp12Reg4FourFours(OP_CMP_reg_T2, rn, FourFours(shift.hi4(), 0xf, shift.lo4(), rm));
}
ALWAYS_INLINE void cmp(RegisterID rn, RegisterID rm)
{
if ((rn | rm) & 8)
cmp(rn, rm, ShiftTypeAndAmount());
else
m_formatter.oneWordOp10Reg3Reg3(OP_CMP_reg_T1, rm, rn);
}
// xor is not spelled with an 'e'. :-(
ALWAYS_INLINE void eor(RegisterID rd, RegisterID rn, ARMThumbImmediate imm)
{
ASSERT(!BadReg(rd));
ASSERT(!BadReg(rn));
ASSERT(imm.isEncodedImm());
m_formatter.twoWordOp5i6Imm4Reg4EncodedImm(OP_EOR_imm_T1, rn, rd, imm);
}
// xor is not spelled with an 'e'. :-(
ALWAYS_INLINE void eor(RegisterID rd, RegisterID rn, RegisterID rm, ShiftTypeAndAmount shift)
{
ASSERT(!BadReg(rd));
ASSERT(!BadReg(rn));
ASSERT(!BadReg(rm));
m_formatter.twoWordOp12Reg4FourFours(OP_EOR_reg_T2, rn, FourFours(shift.hi4(), rd, shift.lo4(), rm));
}
// xor is not spelled with an 'e'. :-(
void eor(RegisterID rd, RegisterID rn, RegisterID rm)
{
if ((rd == rn) && !((rd | rm) & 8))
m_formatter.oneWordOp10Reg3Reg3(OP_EOR_reg_T1, rm, rd);
else if ((rd == rm) && !((rd | rn) & 8))
m_formatter.oneWordOp10Reg3Reg3(OP_EOR_reg_T1, rn, rd);
else
eor(rd, rn, rm, ShiftTypeAndAmount());
}
ALWAYS_INLINE void it(Condition cond)
{
m_formatter.oneWordOp8Imm8(OP_IT, ifThenElse(cond));
}
ALWAYS_INLINE void it(Condition cond, bool inst2if)
{
m_formatter.oneWordOp8Imm8(OP_IT, ifThenElse(cond, inst2if));
}
ALWAYS_INLINE void it(Condition cond, bool inst2if, bool inst3if)
{
m_formatter.oneWordOp8Imm8(OP_IT, ifThenElse(cond, inst2if, inst3if));
}
ALWAYS_INLINE void it(Condition cond, bool inst2if, bool inst3if, bool inst4if)
{
m_formatter.oneWordOp8Imm8(OP_IT, ifThenElse(cond, inst2if, inst3if, inst4if));
}
// rt == ARMRegisters::pc only allowed if last instruction in IT (if then) block.
ALWAYS_INLINE void ldr(RegisterID rt, RegisterID rn, ARMThumbImmediate imm)
{
ASSERT(rn != ARMRegisters::pc); // LDR (literal)
ASSERT(imm.isUInt12());
if (!((rt | rn) & 8) && imm.isUInt7())
m_formatter.oneWordOp5Imm5Reg3Reg3(OP_LDR_imm_T1, imm.getUInt7() >> 2, rn, rt);
else if ((rn == ARMRegisters::sp) && !(rt & 8) && imm.isUInt10())
m_formatter.oneWordOp5Reg3Imm8(OP_LDR_imm_T2, rt, static_cast<uint8_t>(imm.getUInt10() >> 2));
else
m_formatter.twoWordOp12Reg4Reg4Imm12(OP_LDR_imm_T3, rn, rt, imm.getUInt12());
}
ALWAYS_INLINE void ldrWide8BitImmediate(RegisterID rt, RegisterID rn, uint8_t immediate)
{
ASSERT(rn != ARMRegisters::pc);
m_formatter.twoWordOp12Reg4Reg4Imm12(OP_LDR_imm_T3, rn, rt, immediate);
}
ALWAYS_INLINE void ldrCompact(RegisterID rt, RegisterID rn, ARMThumbImmediate imm)
{
ASSERT(rn != ARMRegisters::pc); // LDR (literal)
ASSERT(imm.isUInt7());
ASSERT(!((rt | rn) & 8));
m_formatter.oneWordOp5Imm5Reg3Reg3(OP_LDR_imm_T1, imm.getUInt7() >> 2, rn, rt);
}
// If index is set, this is a regular offset or a pre-indexed load;
// if index is not set then is is a post-index load.
//
// If wback is set rn is updated - this is a pre or post index load,
// if wback is not set this is a regular offset memory access.
//
// (-255 <= offset <= 255)
// _reg = REG[rn]
// _tmp = _reg + offset
// MEM[index ? _tmp : _reg] = REG[rt]
// if (wback) REG[rn] = _tmp
ALWAYS_INLINE void ldr(RegisterID rt, RegisterID rn, int offset, bool index, bool wback)
{
ASSERT(rt != ARMRegisters::pc);
ASSERT(rn != ARMRegisters::pc);
ASSERT(index || wback);
ASSERT(!wback | (rt != rn));
bool add = true;
if (offset < 0) {
add = false;
offset = -offset;
}
ASSERT((offset & ~0xff) == 0);
offset |= (wback << 8);
offset |= (add << 9);
offset |= (index << 10);
offset |= (1 << 11);
m_formatter.twoWordOp12Reg4Reg4Imm12(OP_LDR_imm_T4, rn, rt, offset);
}
// rt == ARMRegisters::pc only allowed if last instruction in IT (if then) block.
ALWAYS_INLINE void ldr(RegisterID rt, RegisterID rn, RegisterID rm, unsigned shift = 0)
{
ASSERT(rn != ARMRegisters::pc); // LDR (literal)
ASSERT(!BadReg(rm));
ASSERT(shift <= 3);
if (!shift && !((rt | rn | rm) & 8))
m_formatter.oneWordOp7Reg3Reg3Reg3(OP_LDR_reg_T1, rm, rn, rt);
else
m_formatter.twoWordOp12Reg4FourFours(OP_LDR_reg_T2, rn, FourFours(rt, 0, shift, rm));
}
// rt == ARMRegisters::pc only allowed if last instruction in IT (if then) block.
ALWAYS_INLINE void ldrh(RegisterID rt, RegisterID rn, ARMThumbImmediate imm)
{
ASSERT(rn != ARMRegisters::pc); // LDR (literal)
ASSERT(imm.isUInt12());
ASSERT(!(imm.getUInt12() & 1));
if (!((rt | rn) & 8) && imm.isUInt6())
m_formatter.oneWordOp5Imm5Reg3Reg3(OP_LDRH_imm_T1, imm.getUInt6() >> 1, rn, rt);
else
m_formatter.twoWordOp12Reg4Reg4Imm12(OP_LDRH_imm_T2, rn, rt, imm.getUInt12());
}
// If index is set, this is a regular offset or a pre-indexed load;
// if index is not set then is is a post-index load.
//
// If wback is set rn is updated - this is a pre or post index load,
// if wback is not set this is a regular offset memory access.
//
// (-255 <= offset <= 255)
// _reg = REG[rn]
// _tmp = _reg + offset
// MEM[index ? _tmp : _reg] = REG[rt]
// if (wback) REG[rn] = _tmp
ALWAYS_INLINE void ldrh(RegisterID rt, RegisterID rn, int offset, bool index, bool wback)
{
ASSERT(rt != ARMRegisters::pc);
ASSERT(rn != ARMRegisters::pc);
ASSERT(index || wback);
ASSERT(!wback | (rt != rn));
bool add = true;
if (offset < 0) {
add = false;
offset = -offset;
}
ASSERT((offset & ~0xff) == 0);
offset |= (wback << 8);
offset |= (add << 9);
offset |= (index << 10);
offset |= (1 << 11);
m_formatter.twoWordOp12Reg4Reg4Imm12(OP_LDRH_imm_T3, rn, rt, offset);
}
ALWAYS_INLINE void ldrh(RegisterID rt, RegisterID rn, RegisterID rm, unsigned shift = 0)
{
ASSERT(!BadReg(rt)); // Memory hint
ASSERT(rn != ARMRegisters::pc); // LDRH (literal)
ASSERT(!BadReg(rm));
ASSERT(shift <= 3);
if (!shift && !((rt | rn | rm) & 8))
m_formatter.oneWordOp7Reg3Reg3Reg3(OP_LDRH_reg_T1, rm, rn, rt);
else
m_formatter.twoWordOp12Reg4FourFours(OP_LDRH_reg_T2, rn, FourFours(rt, 0, shift, rm));
}
void ldrb(RegisterID rt, RegisterID rn, ARMThumbImmediate imm)
{
ASSERT(rn != ARMRegisters::pc); // LDR (literal)
ASSERT(imm.isUInt12());
if (!((rt | rn) & 8) && imm.isUInt5())
m_formatter.oneWordOp5Imm5Reg3Reg3(OP_LDRB_imm_T1, imm.getUInt5(), rn, rt);
else
m_formatter.twoWordOp12Reg4Reg4Imm12(OP_LDRB_imm_T2, rn, rt, imm.getUInt12());
}
void ldrb(RegisterID rt, RegisterID rn, int offset, bool index, bool wback)
{
ASSERT(rt != ARMRegisters::pc);
ASSERT(rn != ARMRegisters::pc);
ASSERT(index || wback);
ASSERT(!wback | (rt != rn));
bool add = true;
if (offset < 0) {
add = false;
offset = -offset;
}
ASSERT(!(offset & ~0xff));
offset |= (wback << 8);
offset |= (add << 9);
offset |= (index << 10);
offset |= (1 << 11);
m_formatter.twoWordOp12Reg4Reg4Imm12(OP_LDRB_imm_T3, rn, rt, offset);
}
ALWAYS_INLINE void ldrb(RegisterID rt, RegisterID rn, RegisterID rm, unsigned shift = 0)
{
ASSERT(rn != ARMRegisters::pc); // LDR (literal)
ASSERT(!BadReg(rm));
ASSERT(shift <= 3);
if (!shift && !((rt | rn | rm) & 8))
m_formatter.oneWordOp7Reg3Reg3Reg3(OP_LDRB_reg_T1, rm, rn, rt);
else
m_formatter.twoWordOp12Reg4FourFours(OP_LDRB_reg_T2, rn, FourFours(rt, 0, shift, rm));
}
void ldrsb(RegisterID rt, RegisterID rn, RegisterID rm, unsigned shift = 0)
{
ASSERT(rn != ARMRegisters::pc);
ASSERT(!BadReg(rm));
ASSERT(shift <= 3);
if (!shift && !((rt | rn | rm) & 8))
m_formatter.oneWordOp7Reg3Reg3Reg3(OP_LDRSB_reg_T1, rm, rn, rt);
else
m_formatter.twoWordOp12Reg4FourFours(OP_LDRSB_reg_T2, rn, FourFours(rt, 0, shift, rm));
}
void ldrsh(RegisterID rt, RegisterID rn, RegisterID rm, unsigned shift = 0)
{
ASSERT(rn != ARMRegisters::pc);
ASSERT(!BadReg(rm));
ASSERT(shift <= 3);
if (!shift && !((rt | rn | rm) & 8))
m_formatter.oneWordOp7Reg3Reg3Reg3(OP_LDRSH_reg_T1, rm, rn, rt);
else
m_formatter.twoWordOp12Reg4FourFours(OP_LDRSH_reg_T2, rn, FourFours(rt, 0, shift, rm));
}
void ldrexd(RegisterID rn, RegisterID t1, RegisterID t2)
{
m_formatter.twoWordOp12Reg4Reg4Reg4Op8(OP_LDREXD_T1, OP_LDREXD_T1b, rn, t1, t2);
}
void strexd(RegisterID rd, RegisterID t1, RegisterID t2, RegisterID rn)
{
m_formatter.twoWordOp12Reg4Reg4Reg4Op4Reg4(OP_STREXD_T1, OP_STREXD_T1b, rn, t1, t2, rd);
}
void lsl(RegisterID rd, RegisterID rm, int32_t shiftAmount)
{
ASSERT(!BadReg(rd));
ASSERT(!BadReg(rm));
ShiftTypeAndAmount shift(SRType_LSL, shiftAmount);
m_formatter.twoWordOp16FourFours(OP_LSL_imm_T1, FourFours(shift.hi4(), rd, shift.lo4(), rm));
}
ALWAYS_INLINE void lsl(RegisterID rd, RegisterID rn, RegisterID rm)
{
ASSERT(!BadReg(rd));
ASSERT(!BadReg(rn));
ASSERT(!BadReg(rm));
m_formatter.twoWordOp12Reg4FourFours(OP_LSL_reg_T2, rn, FourFours(0xf, rd, 0, rm));
}
ALWAYS_INLINE void lsr(RegisterID rd, RegisterID rm, int32_t shiftAmount)
{
ASSERT(!BadReg(rd));
ASSERT(!BadReg(rm));
ShiftTypeAndAmount shift(SRType_LSR, shiftAmount);
m_formatter.twoWordOp16FourFours(OP_LSR_imm_T1, FourFours(shift.hi4(), rd, shift.lo4(), rm));
}
ALWAYS_INLINE void lsr(RegisterID rd, RegisterID rn, RegisterID rm)
{
ASSERT(!BadReg(rd));
ASSERT(!BadReg(rn));
ASSERT(!BadReg(rm));
m_formatter.twoWordOp12Reg4FourFours(OP_LSR_reg_T2, rn, FourFours(0xf, rd, 0, rm));
}
ALWAYS_INLINE void movT3(RegisterID rd, ARMThumbImmediate imm)
{
ASSERT(imm.isValid());
ASSERT(!imm.isEncodedImm());
ASSERT(!BadReg(rd));
m_formatter.twoWordOp5i6Imm4Reg4EncodedImm(OP_MOV_imm_T3, imm.m_value.imm4, rd, imm);
}
#if OS(LINUX)
static void revertJumpTo_movT3movtcmpT2(void* instructionStart, RegisterID left, RegisterID right, uintptr_t imm)
{
uint16_t* address = static_cast<uint16_t*>(instructionStart);
ARMThumbImmediate lo16 = ARMThumbImmediate::makeUInt16(static_cast<uint16_t>(imm));
ARMThumbImmediate hi16 = ARMThumbImmediate::makeUInt16(static_cast<uint16_t>(imm >> 16));
uint16_t instruction[] = {
twoWordOp5i6Imm4Reg4EncodedImmFirst(OP_MOV_imm_T3, lo16),
twoWordOp5i6Imm4Reg4EncodedImmSecond(right, lo16),
twoWordOp5i6Imm4Reg4EncodedImmFirst(OP_MOVT, hi16),
twoWordOp5i6Imm4Reg4EncodedImmSecond(right, hi16),
static_cast<uint16_t>(OP_CMP_reg_T2 | left)
};
performJITMemcpy(address, instruction, sizeof(uint16_t) * 5);
cacheFlush(address, sizeof(uint16_t) * 5);
}
#else
static void revertJumpTo_movT3(void* instructionStart, RegisterID rd, ARMThumbImmediate imm)
{
ASSERT(imm.isValid());
ASSERT(!imm.isEncodedImm());
ASSERT(!BadReg(rd));
uint16_t* address = static_cast<uint16_t*>(instructionStart);
uint16_t instruction[] = {
twoWordOp5i6Imm4Reg4EncodedImmFirst(OP_MOV_imm_T3, imm),
twoWordOp5i6Imm4Reg4EncodedImmSecond(rd, imm)
};
performJITMemcpy(address, instruction, sizeof(uint16_t) * 2);
cacheFlush(address, sizeof(uint16_t) * 2);
}
#endif
ALWAYS_INLINE void mov(RegisterID rd, ARMThumbImmediate imm)
{
ASSERT(imm.isValid());
ASSERT(!BadReg(rd));
if ((rd < 8) && imm.isUInt8())
m_formatter.oneWordOp5Reg3Imm8(OP_MOV_imm_T1, rd, imm.getUInt8());
else if (imm.isEncodedImm())
m_formatter.twoWordOp5i6Imm4Reg4EncodedImm(OP_MOV_imm_T2, 0xf, rd, imm);
else
movT3(rd, imm);
}
ALWAYS_INLINE void mov(RegisterID rd, RegisterID rm)
{
m_formatter.oneWordOp8RegReg143(OP_MOV_reg_T1, rm, rd);
}
ALWAYS_INLINE void movt(RegisterID rd, ARMThumbImmediate imm)
{
ASSERT(imm.isUInt16());
ASSERT(!BadReg(rd));
m_formatter.twoWordOp5i6Imm4Reg4EncodedImm(OP_MOVT, imm.m_value.imm4, rd, imm);
}
ALWAYS_INLINE void mvn(RegisterID rd, ARMThumbImmediate imm)
{
ASSERT(imm.isEncodedImm());
ASSERT(!BadReg(rd));
m_formatter.twoWordOp5i6Imm4Reg4EncodedImm(OP_MVN_imm, 0xf, rd, imm);
}
ALWAYS_INLINE void mvn(RegisterID rd, RegisterID rm, ShiftTypeAndAmount shift)
{
ASSERT(!BadReg(rd));
ASSERT(!BadReg(rm));
m_formatter.twoWordOp16FourFours(OP_MVN_reg_T2, FourFours(shift.hi4(), rd, shift.lo4(), rm));
}
ALWAYS_INLINE void mvn(RegisterID rd, RegisterID rm)
{
if (!((rd | rm) & 8))
m_formatter.oneWordOp10Reg3Reg3(OP_MVN_reg_T1, rm, rd);
else
mvn(rd, rm, ShiftTypeAndAmount());
}
ALWAYS_INLINE void neg(RegisterID rd, RegisterID rm)
{
ARMThumbImmediate zero = ARMThumbImmediate::makeUInt12(0);
sub(rd, zero, rm);
}
ALWAYS_INLINE void orr(RegisterID rd, RegisterID rn, ARMThumbImmediate imm)
{
ASSERT(!BadReg(rd));
ASSERT(!BadReg(rn));
ASSERT(imm.isEncodedImm());
m_formatter.twoWordOp5i6Imm4Reg4EncodedImm(OP_ORR_imm_T1, rn, rd, imm);
}
ALWAYS_INLINE void orr(RegisterID rd, RegisterID rn, RegisterID rm, ShiftTypeAndAmount shift)
{
ASSERT(!BadReg(rd));
ASSERT(!BadReg(rn));
ASSERT(!BadReg(rm));
m_formatter.twoWordOp12Reg4FourFours(OP_ORR_reg_T2, rn, FourFours(shift.hi4(), rd, shift.lo4(), rm));
}
void orr(RegisterID rd, RegisterID rn, RegisterID rm)
{
if ((rd == rn) && !((rd | rm) & 8))
m_formatter.oneWordOp10Reg3Reg3(OP_ORR_reg_T1, rm, rd);
else if ((rd == rm) && !((rd | rn) & 8))
m_formatter.oneWordOp10Reg3Reg3(OP_ORR_reg_T1, rn, rd);
else
orr(rd, rn, rm, ShiftTypeAndAmount());
}
ALWAYS_INLINE void orr_S(RegisterID rd, RegisterID rn, RegisterID rm, ShiftTypeAndAmount shift)
{
ASSERT(!BadReg(rd));
ASSERT(!BadReg(rn));
ASSERT(!BadReg(rm));
m_formatter.twoWordOp12Reg4FourFours(OP_ORR_S_reg_T2, rn, FourFours(shift.hi4(), rd, shift.lo4(), rm));
}
void orr_S(RegisterID rd, RegisterID rn, RegisterID rm)
{
if ((rd == rn) && !((rd | rm) & 8))
m_formatter.oneWordOp10Reg3Reg3(OP_ORR_reg_T1, rm, rd);
else if ((rd == rm) && !((rd | rn) & 8))
m_formatter.oneWordOp10Reg3Reg3(OP_ORR_reg_T1, rn, rd);
else
orr_S(rd, rn, rm, ShiftTypeAndAmount());
}
ALWAYS_INLINE void ror(RegisterID rd, RegisterID rm, int32_t shiftAmount)
{
ASSERT(!BadReg(rd));
ASSERT(!BadReg(rm));
ShiftTypeAndAmount shift(SRType_ROR, shiftAmount);
m_formatter.twoWordOp16FourFours(OP_ROR_imm_T1, FourFours(shift.hi4(), rd, shift.lo4(), rm));
}
ALWAYS_INLINE void ror(RegisterID rd, RegisterID rn, RegisterID rm)
{
ASSERT(!BadReg(rd));
ASSERT(!BadReg(rn));
ASSERT(!BadReg(rm));
m_formatter.twoWordOp12Reg4FourFours(OP_ROR_reg_T2, rn, FourFours(0xf, rd, 0, rm));
}
ALWAYS_INLINE void pop(RegisterID dest)
{
if (dest < ARMRegisters::r8)
m_formatter.oneWordOp7Imm9(OP_POP_T1, 1 << dest);
else {
// Load postindexed with writeback.
ldr(dest, ARMRegisters::sp, sizeof(void*), false, true);
}
}
ALWAYS_INLINE void pop(uint32_t registerList)
{
ASSERT(WTF::bitCount(registerList) > 1);
ASSERT(!((1 << ARMRegisters::pc) & registerList) || !((1 << ARMRegisters::lr) & registerList));
ASSERT(!((1 << ARMRegisters::sp) & registerList));
m_formatter.twoWordOp16Imm16(OP_POP_T2, registerList);
}
ALWAYS_INLINE void push(RegisterID src)
{
if (src < ARMRegisters::r8)
m_formatter.oneWordOp7Imm9(OP_PUSH_T1, 1 << src);
else if (src == ARMRegisters::lr)
m_formatter.oneWordOp7Imm9(OP_PUSH_T1, 0x100);
else {
// Store preindexed with writeback.
str(src, ARMRegisters::sp, -sizeof(void*), true, true);
}
}
ALWAYS_INLINE void push(uint32_t registerList)
{
ASSERT(WTF::bitCount(registerList) > 1);
ASSERT(!((1 << ARMRegisters::pc) & registerList));
ASSERT(!((1 << ARMRegisters::sp) & registerList));
m_formatter.twoWordOp16Imm16(OP_PUSH_T2, registerList);
}
#if HAVE(ARM_IDIV_INSTRUCTIONS)
template<int datasize>
ALWAYS_INLINE void sdiv(RegisterID rd, RegisterID rn, RegisterID rm)
{
static_assert(datasize == 32, "sdiv datasize must be 32 for armv7s");
ASSERT(!BadReg(rd));
ASSERT(!BadReg(rn));
ASSERT(!BadReg(rm));
m_formatter.twoWordOp12Reg4FourFours(OP_SDIV_T1, rn, FourFours(0xf, rd, 0xf, rm));
}
#endif
ALWAYS_INLINE void smull(RegisterID rdLo, RegisterID rdHi, RegisterID rn, RegisterID rm)
{
ASSERT(!BadReg(rdLo));
ASSERT(!BadReg(rdHi));
ASSERT(!BadReg(rn));
ASSERT(!BadReg(rm));
ASSERT(rdLo != rdHi);
m_formatter.twoWordOp12Reg4FourFours(OP_SMULL_T1, rn, FourFours(rdLo, rdHi, 0, rm));
}
// rt == ARMRegisters::pc only allowed if last instruction in IT (if then) block.
ALWAYS_INLINE void str(RegisterID rt, RegisterID rn, ARMThumbImmediate imm)
{
ASSERT(rt != ARMRegisters::pc);
ASSERT(rn != ARMRegisters::pc);
ASSERT(imm.isUInt12());
if (!((rt | rn) & 8) && imm.isUInt7())
m_formatter.oneWordOp5Imm5Reg3Reg3(OP_STR_imm_T1, imm.getUInt7() >> 2, rn, rt);
else if ((rn == ARMRegisters::sp) && !(rt & 8) && imm.isUInt10())
m_formatter.oneWordOp5Reg3Imm8(OP_STR_imm_T2, rt, static_cast<uint8_t>(imm.getUInt10() >> 2));
else
m_formatter.twoWordOp12Reg4Reg4Imm12(OP_STR_imm_T3, rn, rt, imm.getUInt12());
}
// If index is set, this is a regular offset or a pre-indexed store;
// if index is not set then is is a post-index store.
//
// If wback is set rn is updated - this is a pre or post index store,
// if wback is not set this is a regular offset memory access.
//
// (-255 <= offset <= 255)
// _reg = REG[rn]
// _tmp = _reg + offset
// MEM[index ? _tmp : _reg] = REG[rt]
// if (wback) REG[rn] = _tmp
ALWAYS_INLINE void str(RegisterID rt, RegisterID rn, int offset, bool index, bool wback)
{
ASSERT(rt != ARMRegisters::pc);
ASSERT(rn != ARMRegisters::pc);
ASSERT(index || wback);
ASSERT(!wback | (rt != rn));
bool add = true;
if (offset < 0) {
add = false;
offset = -offset;
}
ASSERT((offset & ~0xff) == 0);
offset |= (wback << 8);
offset |= (add << 9);
offset |= (index << 10);
offset |= (1 << 11);
m_formatter.twoWordOp12Reg4Reg4Imm12(OP_STR_imm_T4, rn, rt, offset);
}
// rt == ARMRegisters::pc only allowed if last instruction in IT (if then) block.
ALWAYS_INLINE void str(RegisterID rt, RegisterID rn, RegisterID rm, unsigned shift = 0)
{
ASSERT(rn != ARMRegisters::pc);
ASSERT(!BadReg(rm));
ASSERT(shift <= 3);
if (!shift && !((rt | rn | rm) & 8))
m_formatter.oneWordOp7Reg3Reg3Reg3(OP_STR_reg_T1, rm, rn, rt);
else
m_formatter.twoWordOp12Reg4FourFours(OP_STR_reg_T2, rn, FourFours(rt, 0, shift, rm));
}
// rt == ARMRegisters::pc only allowed if last instruction in IT (if then) block.
ALWAYS_INLINE void strb(RegisterID rt, RegisterID rn, ARMThumbImmediate imm)
{
ASSERT(rt != ARMRegisters::pc);
ASSERT(rn != ARMRegisters::pc);
ASSERT(imm.isUInt12());
if (!((rt | rn) & 8) && imm.isUInt7())
m_formatter.oneWordOp5Imm5Reg3Reg3(OP_STRB_imm_T1, imm.getUInt7() >> 2, rn, rt);
else
m_formatter.twoWordOp12Reg4Reg4Imm12(OP_STRB_imm_T2, rn, rt, imm.getUInt12());
}
// If index is set, this is a regular offset or a pre-indexed store;
// if index is not set then is is a post-index store.
//
// If wback is set rn is updated - this is a pre or post index store,
// if wback is not set this is a regular offset memory access.
//
// (-255 <= offset <= 255)
// _reg = REG[rn]
// _tmp = _reg + offset
// MEM[index ? _tmp : _reg] = REG[rt]
// if (wback) REG[rn] = _tmp
ALWAYS_INLINE void strb(RegisterID rt, RegisterID rn, int offset, bool index, bool wback)
{
ASSERT(rt != ARMRegisters::pc);
ASSERT(rn != ARMRegisters::pc);
ASSERT(index || wback);
ASSERT(!wback | (rt != rn));
bool add = true;
if (offset < 0) {
add = false;
offset = -offset;
}
ASSERT((offset & ~0xff) == 0);
offset |= (wback << 8);
offset |= (add << 9);
offset |= (index << 10);
offset |= (1 << 11);
m_formatter.twoWordOp12Reg4Reg4Imm12(OP_STRB_imm_T3, rn, rt, offset);
}
// rt == ARMRegisters::pc only allowed if last instruction in IT (if then) block.
ALWAYS_INLINE void strb(RegisterID rt, RegisterID rn, RegisterID rm, unsigned shift = 0)
{
ASSERT(rn != ARMRegisters::pc);
ASSERT(!BadReg(rm));
ASSERT(shift <= 3);
if (!shift && !((rt | rn | rm) & 8))
m_formatter.oneWordOp7Reg3Reg3Reg3(OP_STRB_reg_T1, rm, rn, rt);
else
m_formatter.twoWordOp12Reg4FourFours(OP_STRB_reg_T2, rn, FourFours(rt, 0, shift, rm));
}
// rt == ARMRegisters::pc only allowed if last instruction in IT (if then) block.
ALWAYS_INLINE void strh(RegisterID rt, RegisterID rn, ARMThumbImmediate imm)
{
ASSERT(rt != ARMRegisters::pc);
ASSERT(rn != ARMRegisters::pc);
ASSERT(imm.isUInt12());
if (!((rt | rn) & 8) && imm.isUInt6())
m_formatter.oneWordOp5Imm5Reg3Reg3(OP_STRH_imm_T1, imm.getUInt6() >> 1, rn, rt);
else
m_formatter.twoWordOp12Reg4Reg4Imm12(OP_STRH_imm_T2, rn, rt, imm.getUInt12());
}
// If index is set, this is a regular offset or a pre-indexed store;
// if index is not set then is is a post-index store.
//
// If wback is set rn is updated - this is a pre or post index store,
// if wback is not set this is a regular offset memory access.
//
// (-255 <= offset <= 255)
// _reg = REG[rn]
// _tmp = _reg + offset
// MEM[index ? _tmp : _reg] = REG[rt]
// if (wback) REG[rn] = _tmp
ALWAYS_INLINE void strh(RegisterID rt, RegisterID rn, int offset, bool index, bool wback)
{
ASSERT(rt != ARMRegisters::pc);
ASSERT(rn != ARMRegisters::pc);
ASSERT(index || wback);
ASSERT(!wback | (rt != rn));
bool add = true;
if (offset < 0) {
add = false;
offset = -offset;
}
ASSERT(!(offset & ~0xff));
offset |= (wback << 8);
offset |= (add << 9);
offset |= (index << 10);
offset |= (1 << 11);
m_formatter.twoWordOp12Reg4Reg4Imm12(OP_STRH_imm_T3, rn, rt, offset);
}
// rt == ARMRegisters::pc only allowed if last instruction in IT (if then) block.
ALWAYS_INLINE void strh(RegisterID rt, RegisterID rn, RegisterID rm, unsigned shift = 0)
{
ASSERT(rn != ARMRegisters::pc);
ASSERT(!BadReg(rm));
ASSERT(shift <= 3);
if (!shift && !((rt | rn | rm) & 8))
m_formatter.oneWordOp7Reg3Reg3Reg3(OP_STRH_reg_T1, rm, rn, rt);
else
m_formatter.twoWordOp12Reg4FourFours(OP_STRH_reg_T2, rn, FourFours(rt, 0, shift, rm));
}
ALWAYS_INLINE void sub(RegisterID rd, RegisterID rn, ARMThumbImmediate imm)
{
// Rd can only be SP if Rn is also SP.
ASSERT((rd != ARMRegisters::sp) || (rn == ARMRegisters::sp));
ASSERT(rd != ARMRegisters::pc);
ASSERT(rn != ARMRegisters::pc);
ASSERT(imm.isValid());
if ((rn == ARMRegisters::sp) && (rd == ARMRegisters::sp) && imm.isUInt9()) {
ASSERT(!(imm.getUInt16() & 3));
m_formatter.oneWordOp9Imm7(OP_SUB_SP_imm_T1, static_cast<uint8_t>(imm.getUInt9() >> 2));
return;
} else if (!((rd | rn) & 8)) {
if (imm.isUInt3()) {
m_formatter.oneWordOp7Reg3Reg3Reg3(OP_SUB_imm_T1, (RegisterID)imm.getUInt3(), rn, rd);
return;
} else if ((rd == rn) && imm.isUInt8()) {
m_formatter.oneWordOp5Reg3Imm8(OP_SUB_imm_T2, rd, imm.getUInt8());
return;
}
}
if (imm.isEncodedImm())
m_formatter.twoWordOp5i6Imm4Reg4EncodedImm(OP_SUB_imm_T3, rn, rd, imm);
else {
ASSERT(imm.isUInt12());
m_formatter.twoWordOp5i6Imm4Reg4EncodedImm(OP_SUB_imm_T4, rn, rd, imm);
}
}
ALWAYS_INLINE void sub(RegisterID rd, ARMThumbImmediate imm, RegisterID rn)
{
ASSERT(rd != ARMRegisters::pc);
ASSERT(rn != ARMRegisters::pc);
ASSERT(imm.isValid());
ASSERT(imm.isUInt12());
if (!((rd | rn) & 8) && !imm.getUInt12())
m_formatter.oneWordOp10Reg3Reg3(OP_RSB_imm_T1, rn, rd);
else
m_formatter.twoWordOp5i6Imm4Reg4EncodedImm(OP_RSB_imm_T2, rn, rd, imm);
}
ALWAYS_INLINE void sub(RegisterID rd, RegisterID rn, RegisterID rm, ShiftTypeAndAmount shift)
{
ASSERT((rd != ARMRegisters::sp) || (rn == ARMRegisters::sp));
ASSERT(rd != ARMRegisters::pc);
ASSERT(rn != ARMRegisters::pc);
ASSERT(!BadReg(rm));
m_formatter.twoWordOp12Reg4FourFours(OP_SUB_reg_T2, rn, FourFours(shift.hi4(), rd, shift.lo4(), rm));
}
// NOTE: In an IT block, add doesn't modify the flags register.
ALWAYS_INLINE void sub(RegisterID rd, RegisterID rn, RegisterID rm)
{
if (!((rd | rn | rm) & 8))
m_formatter.oneWordOp7Reg3Reg3Reg3(OP_SUB_reg_T1, rm, rn, rd);
else
sub(rd, rn, rm, ShiftTypeAndAmount());
}
// Not allowed in an IT (if then) block.
void sub_S(RegisterID rd, RegisterID rn, ARMThumbImmediate imm)
{
// Rd can only be SP if Rn is also SP.
ASSERT((rd != ARMRegisters::sp) || (rn == ARMRegisters::sp));
ASSERT(rd != ARMRegisters::pc);
ASSERT(rn != ARMRegisters::pc);
ASSERT(imm.isValid());
if ((rn == ARMRegisters::sp) && (rd == ARMRegisters::sp) && imm.isUInt9()) {
ASSERT(!(imm.getUInt16() & 3));
m_formatter.oneWordOp9Imm7(OP_SUB_SP_imm_T1, static_cast<uint8_t>(imm.getUInt9() >> 2));
return;
} else if (!((rd | rn) & 8)) {
if (imm.isUInt3()) {
m_formatter.oneWordOp7Reg3Reg3Reg3(OP_SUB_imm_T1, (RegisterID)imm.getUInt3(), rn, rd);
return;
} else if ((rd == rn) && imm.isUInt8()) {
m_formatter.oneWordOp5Reg3Imm8(OP_SUB_imm_T2, rd, imm.getUInt8());
return;
}
}
m_formatter.twoWordOp5i6Imm4Reg4EncodedImm(OP_SUB_S_imm_T3, rn, rd, imm);
}
ALWAYS_INLINE void sub_S(RegisterID rd, ARMThumbImmediate imm, RegisterID rn)
{
ASSERT(rd != ARMRegisters::pc);
ASSERT(rn != ARMRegisters::pc);
ASSERT(imm.isValid());
ASSERT(imm.isUInt12());
m_formatter.twoWordOp5i6Imm4Reg4EncodedImm(OP_RSB_S_imm_T2, rn, rd, imm);
}
// Not allowed in an IT (if then) block?
ALWAYS_INLINE void sub_S(RegisterID rd, RegisterID rn, RegisterID rm, ShiftTypeAndAmount shift)
{
ASSERT((rd != ARMRegisters::sp) || (rn == ARMRegisters::sp));
ASSERT(rd != ARMRegisters::pc);
ASSERT(rn != ARMRegisters::pc);
ASSERT(!BadReg(rm));
m_formatter.twoWordOp12Reg4FourFours(OP_SUB_S_reg_T2, rn, FourFours(shift.hi4(), rd, shift.lo4(), rm));
}
// Not allowed in an IT (if then) block.
ALWAYS_INLINE void sub_S(RegisterID rd, RegisterID rn, RegisterID rm)
{
if (!((rd | rn | rm) & 8))
m_formatter.oneWordOp7Reg3Reg3Reg3(OP_SUB_reg_T1, rm, rn, rd);
else
sub_S(rd, rn, rm, ShiftTypeAndAmount());
}
ALWAYS_INLINE void tst(RegisterID rn, ARMThumbImmediate imm)
{
ASSERT(!BadReg(rn));
ASSERT(imm.isEncodedImm());
m_formatter.twoWordOp5i6Imm4Reg4EncodedImm(OP_TST_imm, rn, (RegisterID)0xf, imm);
}
ALWAYS_INLINE void tst(RegisterID rn, RegisterID rm, ShiftTypeAndAmount shift)
{
ASSERT(!BadReg(rn));
ASSERT(!BadReg(rm));
m_formatter.twoWordOp12Reg4FourFours(OP_TST_reg_T2, rn, FourFours(shift.hi4(), 0xf, shift.lo4(), rm));
}
ALWAYS_INLINE void tst(RegisterID rn, RegisterID rm)
{
if ((rn | rm) & 8)
tst(rn, rm, ShiftTypeAndAmount());
else
m_formatter.oneWordOp10Reg3Reg3(OP_TST_reg_T1, rm, rn);
}
ALWAYS_INLINE void ubfx(RegisterID rd, RegisterID rn, unsigned lsb, unsigned width)
{
ASSERT(lsb < 32);
ASSERT((width >= 1) && (width <= 32));
ASSERT((lsb + width) <= 32);
m_formatter.twoWordOp12Reg40Imm3Reg4Imm20Imm5(OP_UBFX_T1, rd, rn, (lsb & 0x1c) << 10, (lsb & 0x3) << 6, (width - 1) & 0x1f);
}
#if HAVE(ARM_IDIV_INSTRUCTIONS)
ALWAYS_INLINE void udiv(RegisterID rd, RegisterID rn, RegisterID rm)
{
ASSERT(!BadReg(rd));
ASSERT(!BadReg(rn));
ASSERT(!BadReg(rm));
m_formatter.twoWordOp12Reg4FourFours(OP_UDIV_T1, rn, FourFours(0xf, rd, 0xf, rm));
}
#endif
void vadd(FPDoubleRegisterID rd, FPDoubleRegisterID rn, FPDoubleRegisterID rm)
{
m_formatter.vfpOp(OP_VADD_T2, OP_VADD_T2b, true, rn, rd, rm);
}
void vcmp(FPDoubleRegisterID rd, FPDoubleRegisterID rm)
{
m_formatter.vfpOp(OP_VCMP, OP_VCMPb, true, VFPOperand(4), rd, rm);
}
void vcmpz(FPDoubleRegisterID rd)
{
m_formatter.vfpOp(OP_VCMP, OP_VCMPb, true, VFPOperand(5), rd, VFPOperand(0));
}
void vcvt_signedToFloatingPoint(FPDoubleRegisterID rd, FPSingleRegisterID rm)
{
// boolean values are 64bit (toInt, unsigned, roundZero)
m_formatter.vfpOp(OP_VCVT_FPIVFP, OP_VCVT_FPIVFPb, true, vcvtOp(false, false, false), rd, rm);
}
void vcvt_floatingPointToSigned(FPSingleRegisterID rd, FPDoubleRegisterID rm)
{
// boolean values are 64bit (toInt, unsigned, roundZero)
m_formatter.vfpOp(OP_VCVT_FPIVFP, OP_VCVT_FPIVFPb, true, vcvtOp(true, false, true), rd, rm);
}
void vcvt_floatingPointToUnsigned(FPSingleRegisterID rd, FPDoubleRegisterID rm)
{
// boolean values are 64bit (toInt, unsigned, roundZero)
m_formatter.vfpOp(OP_VCVT_FPIVFP, OP_VCVT_FPIVFPb, true, vcvtOp(true, true, true), rd, rm);
}
void vdiv(FPDoubleRegisterID rd, FPDoubleRegisterID rn, FPDoubleRegisterID rm)
{
m_formatter.vfpOp(OP_VDIV, OP_VDIVb, true, rn, rd, rm);
}
void vldr(FPDoubleRegisterID rd, RegisterID rn, int32_t imm)
{
m_formatter.vfpMemOp(OP_VLDR, OP_VLDRb, true, rn, rd, imm);
}
void flds(FPSingleRegisterID rd, RegisterID rn, int32_t imm)
{
m_formatter.vfpMemOp(OP_FLDS, OP_FLDSb, false, rn, rd, imm);
}
void vmov(RegisterID rd, FPSingleRegisterID rn)
{
ASSERT(!BadReg(rd));
m_formatter.vfpOp(OP_VMOV_StoC, OP_VMOV_StoCb, false, rn, rd, VFPOperand(0));
}
void vmov(FPSingleRegisterID rd, RegisterID rn)
{
ASSERT(!BadReg(rn));
m_formatter.vfpOp(OP_VMOV_CtoS, OP_VMOV_CtoSb, false, rd, rn, VFPOperand(0));
}
void vmov(RegisterID rd1, RegisterID rd2, FPDoubleRegisterID rn)
{
ASSERT(!BadReg(rd1));
ASSERT(!BadReg(rd2));
m_formatter.vfpOp(OP_VMOV_DtoC, OP_VMOV_DtoCb, true, rd2, VFPOperand(rd1 | 16), rn);
}
void vmov(FPDoubleRegisterID rd, RegisterID rn1, RegisterID rn2)
{
ASSERT(!BadReg(rn1));
ASSERT(!BadReg(rn2));
m_formatter.vfpOp(OP_VMOV_CtoD, OP_VMOV_CtoDb, true, rn2, VFPOperand(rn1 | 16), rd);
}
void vmov(FPDoubleRegisterID rd, FPDoubleRegisterID rn)
{
m_formatter.vfpOp(OP_VMOV_T2, OP_VMOV_T2b, true, VFPOperand(0), rd, rn);
}
void vmrs(RegisterID reg = ARMRegisters::pc)
{
ASSERT(reg != ARMRegisters::sp);
m_formatter.vfpOp(OP_VMRS, OP_VMRSb, false, VFPOperand(1), VFPOperand(0x10 | reg), VFPOperand(0));
}
void vmul(FPDoubleRegisterID rd, FPDoubleRegisterID rn, FPDoubleRegisterID rm)
{
m_formatter.vfpOp(OP_VMUL_T2, OP_VMUL_T2b, true, rn, rd, rm);
}
void vstr(FPDoubleRegisterID rd, RegisterID rn, int32_t imm)
{
m_formatter.vfpMemOp(OP_VSTR, OP_VSTRb, true, rn, rd, imm);
}
void fsts(FPSingleRegisterID rd, RegisterID rn, int32_t imm)
{
m_formatter.vfpMemOp(OP_FSTS, OP_FSTSb, false, rn, rd, imm);
}
void vsub(FPDoubleRegisterID rd, FPDoubleRegisterID rn, FPDoubleRegisterID rm)
{
m_formatter.vfpOp(OP_VSUB_T2, OP_VSUB_T2b, true, rn, rd, rm);
}
void vabs(FPDoubleRegisterID rd, FPDoubleRegisterID rm)
{
m_formatter.vfpOp(OP_VABS_T2, OP_VABS_T2b, true, VFPOperand(16), rd, rm);
}
void vneg(FPDoubleRegisterID rd, FPDoubleRegisterID rm)
{
m_formatter.vfpOp(OP_VNEG_T2, OP_VNEG_T2b, true, VFPOperand(1), rd, rm);
}
void vsqrt(FPDoubleRegisterID rd, FPDoubleRegisterID rm)
{
m_formatter.vfpOp(OP_VSQRT_T1, OP_VSQRT_T1b, true, VFPOperand(17), rd, rm);
}
void vcvtds(FPDoubleRegisterID rd, FPSingleRegisterID rm)
{
m_formatter.vfpOp(OP_VCVTDS_T1, OP_VCVTDS_T1b, false, VFPOperand(23), rd, rm);
}
void vcvtsd(FPSingleRegisterID rd, FPDoubleRegisterID rm)
{
m_formatter.vfpOp(OP_VCVTSD_T1, OP_VCVTSD_T1b, true, VFPOperand(23), rd, rm);
}
void nop()
{
m_formatter.oneWordOp8Imm8(OP_NOP_T1, 0);
}
void nopw()
{
m_formatter.twoWordOp16Op16(OP_NOP_T2a, OP_NOP_T2b);
}
static constexpr int16_t nopPseudo16()
{
return OP_NOP_T1;
}
static constexpr int32_t nopPseudo32()
{
return OP_NOP_T2a | (OP_NOP_T2b << 16);
}
static void fillNops(void* base, size_t size, bool isCopyingToExecutableMemory)
{
RELEASE_ASSERT(!(size % sizeof(int16_t)));
char* ptr = static_cast<char*>(base);
const size_t num32s = size / sizeof(int32_t);
for (size_t i = 0; i < num32s; i++) {
const int32_t insn = nopPseudo32();
if (isCopyingToExecutableMemory)
performJITMemcpy(ptr, &insn, sizeof(int32_t));
else
memcpy(ptr, &insn, sizeof(int32_t));
ptr += sizeof(int32_t);
}
const size_t num16s = (size % sizeof(int32_t)) / sizeof(int16_t);
ASSERT(num16s == 0 || num16s == 1);
ASSERT(num16s * sizeof(int16_t) + num32s * sizeof(int32_t) == size);
if (num16s) {
const int16_t insn = nopPseudo16();
if (isCopyingToExecutableMemory)
performJITMemcpy(ptr, &insn, sizeof(int16_t));
else
memcpy(ptr, &insn, sizeof(int16_t));
}
}
void dmbSY()
{
m_formatter.twoWordOp16Op16(OP_DMB_T1a, OP_DMB_SY_T1b);
}
void dmbISHST()
{
m_formatter.twoWordOp16Op16(OP_DMB_T1a, OP_DMB_ISHST_T1b);
}
AssemblerLabel labelIgnoringWatchpoints()
{
return m_formatter.label();
}
AssemblerLabel labelForWatchpoint()
{
AssemblerLabel result = m_formatter.label();
if (static_cast<int>(result.m_offset) != m_indexOfLastWatchpoint)
result = label();
m_indexOfLastWatchpoint = result.m_offset;
m_indexOfTailOfLastWatchpoint = result.m_offset + maxJumpReplacementSize();
return result;
}
AssemblerLabel label()
{
AssemblerLabel result = m_formatter.label();
while (UNLIKELY(static_cast<int>(result.m_offset) < m_indexOfTailOfLastWatchpoint)) {
if (UNLIKELY(static_cast<int>(result.m_offset) + 4 <= m_indexOfTailOfLastWatchpoint))
nopw();
else
nop();
result = m_formatter.label();
}
return result;
}
AssemblerLabel align(int alignment)
{
while (!m_formatter.isAligned(alignment))
bkpt();
return label();
}
static void* getRelocatedAddress(void* code, AssemblerLabel label)
{
ASSERT(label.isSet());
return reinterpret_cast<void*>(reinterpret_cast<ptrdiff_t>(code) + label.m_offset);
}
static int getDifferenceBetweenLabels(AssemblerLabel a, AssemblerLabel b)
{
return b.m_offset - a.m_offset;
}
static int jumpSizeDelta(JumpType jumpType, JumpLinkType jumpLinkType) { return JUMP_ENUM_SIZE(jumpType) - JUMP_ENUM_SIZE(jumpLinkType); }
// Assembler admin methods:
static ALWAYS_INLINE bool linkRecordSourceComparator(const LinkRecord& a, const LinkRecord& b)
{
return a.from() < b.from();
}
static bool canCompact(JumpType jumpType)
{
// The following cannot be compacted:
// JumpFixed: represents custom jump sequence
// JumpNoConditionFixedSize: represents unconditional jump that must remain a fixed size
// JumpConditionFixedSize: represents conditional jump that must remain a fixed size
return (jumpType == JumpNoCondition) || (jumpType == JumpCondition);
}
static JumpLinkType computeJumpType(JumpType jumpType, const uint8_t* from, const uint8_t* to)
{
if (jumpType == JumpFixed)
return LinkInvalid;
// for patchable jump we must leave space for the longest code sequence
if (jumpType == JumpNoConditionFixedSize)
return LinkBX;
if (jumpType == JumpConditionFixedSize)
return LinkConditionalBX;
const int paddingSize = JUMP_ENUM_SIZE(jumpType);
if (jumpType == JumpCondition) {
// 2-byte conditional T1
const uint16_t* jumpT1Location = reinterpret_cast_ptr<const uint16_t*>(from - (paddingSize - JUMP_ENUM_SIZE(LinkJumpT1)));
if (canBeJumpT1(jumpT1Location, to))
return LinkJumpT1;
// 4-byte conditional T3
const uint16_t* jumpT3Location = reinterpret_cast_ptr<const uint16_t*>(from - (paddingSize - JUMP_ENUM_SIZE(LinkJumpT3)));
if (canBeJumpT3(jumpT3Location, to))
return LinkJumpT3;
// 4-byte conditional T4 with IT
const uint16_t* conditionalJumpT4Location =
reinterpret_cast_ptr<const uint16_t*>(from - (paddingSize - JUMP_ENUM_SIZE(LinkConditionalJumpT4)));
if (canBeJumpT4(conditionalJumpT4Location, to))
return LinkConditionalJumpT4;
} else {
// 2-byte unconditional T2
const uint16_t* jumpT2Location = reinterpret_cast_ptr<const uint16_t*>(from - (paddingSize - JUMP_ENUM_SIZE(LinkJumpT2)));
if (canBeJumpT2(jumpT2Location, to))
return LinkJumpT2;
// 4-byte unconditional T4
const uint16_t* jumpT4Location = reinterpret_cast_ptr<const uint16_t*>(from - (paddingSize - JUMP_ENUM_SIZE(LinkJumpT4)));
if (canBeJumpT4(jumpT4Location, to))
return LinkJumpT4;
// use long jump sequence
return LinkBX;
}
ASSERT(jumpType == JumpCondition);
return LinkConditionalBX;
}
static JumpLinkType computeJumpType(LinkRecord& record, const uint8_t* from, const uint8_t* to)
{
JumpLinkType linkType = computeJumpType(record.type(), from, to);
record.setLinkType(linkType);
return linkType;
}
Vector<LinkRecord, 0, UnsafeVectorOverflow>& jumpsToLink()
{
std::sort(m_jumpsToLink.begin(), m_jumpsToLink.end(), linkRecordSourceComparator);
return m_jumpsToLink;
}
static void ALWAYS_INLINE link(LinkRecord& record, uint8_t* from, const uint8_t* fromInstruction8, uint8_t* to)
{
const uint16_t* fromInstruction = reinterpret_cast_ptr<const uint16_t*>(fromInstruction8);
switch (record.linkType()) {
case LinkJumpT1:
linkJumpT1(record.condition(), reinterpret_cast_ptr<uint16_t*>(from), fromInstruction, to);
break;
case LinkJumpT2:
linkJumpT2(reinterpret_cast_ptr<uint16_t*>(from), fromInstruction, to);
break;
case LinkJumpT3:
linkJumpT3(record.condition(), reinterpret_cast_ptr<uint16_t*>(from), fromInstruction, to);
break;
case LinkJumpT4:
linkJumpT4(reinterpret_cast_ptr<uint16_t*>(from), fromInstruction, to);
break;
case LinkConditionalJumpT4:
linkConditionalJumpT4(record.condition(), reinterpret_cast_ptr<uint16_t*>(from), fromInstruction, to);
break;
case LinkConditionalBX:
linkConditionalBX(record.condition(), reinterpret_cast_ptr<uint16_t*>(from), fromInstruction, to);
break;
case LinkBX:
linkBX(reinterpret_cast_ptr<uint16_t*>(from), fromInstruction, to);
break;
default:
RELEASE_ASSERT_NOT_REACHED();
break;
}
}
void* unlinkedCode() { return m_formatter.data(); }
size_t codeSize() const { return m_formatter.codeSize(); }
static unsigned getCallReturnOffset(AssemblerLabel call)
{
ASSERT(call.isSet());
return call.m_offset;
}
// Linking & patching:
//
// 'link' and 'patch' methods are for use on unprotected code - such as the code
// within the AssemblerBuffer, and code being patched by the patch buffer. Once
// code has been finalized it is (platform support permitting) within a non-
// writable region of memory; to modify the code in an execute-only execuable
// pool the 'repatch' and 'relink' methods should be used.
void linkJump(AssemblerLabel from, AssemblerLabel to, JumpType type, Condition condition)
{
ASSERT(to.isSet());
ASSERT(from.isSet());
m_jumpsToLink.append(LinkRecord(from.m_offset, to.m_offset, type, condition));
}
static void linkJump(void* code, AssemblerLabel from, void* to)
{
ASSERT(from.isSet());
uint16_t* location = reinterpret_cast<uint16_t*>(reinterpret_cast<intptr_t>(code) + from.m_offset);
linkJumpAbsolute(location, location, to);
}
static void linkCall(void* code, AssemblerLabel from, void* to)
{
ASSERT(!(reinterpret_cast<intptr_t>(code) & 1));
ASSERT(from.isSet());
setPointer(reinterpret_cast<uint16_t*>(reinterpret_cast<intptr_t>(code) + from.m_offset) - 1, to, false);
}
static void linkPointer(void* code, AssemblerLabel where, void* value)
{
setPointer(reinterpret_cast<char*>(code) + where.m_offset, value, false);
}
// The static relink and replace methods can use can use |from| for both
// the write and executable address for call and jump patching
// as they're modifying existing (linked) code, so the address being
// provided is correct for relative address computation.
static void relinkJump(void* from, void* to)
{
ASSERT(!(reinterpret_cast<intptr_t>(from) & 1));
ASSERT(!(reinterpret_cast<intptr_t>(to) & 1));
linkJumpAbsolute(reinterpret_cast<uint16_t*>(from), reinterpret_cast<uint16_t*>(from), to);
cacheFlush(reinterpret_cast<uint16_t*>(from) - 5, 5 * sizeof(uint16_t));
}
static void relinkJumpToNop(void* from)
{
relinkJump(from, from);
}
static void relinkCall(void* from, void* to)
{
ASSERT(!(reinterpret_cast<intptr_t>(from) & 1));
setPointer(reinterpret_cast<uint16_t*>(from) - 1, to, true);
}
static void* readCallTarget(void* from)
{
return readPointer(reinterpret_cast<uint16_t*>(from) - 1);
}
static void repatchInt32(void* where, int32_t value)
{
ASSERT(!(reinterpret_cast<intptr_t>(where) & 1));
setInt32(where, value, true);
}
static void repatchCompact(void* where, int32_t offset)
{
ASSERT(offset >= -255 && offset <= 255);
bool add = true;
if (offset < 0) {
add = false;
offset = -offset;
}
offset |= (add << 9);
offset |= (1 << 10);
offset |= (1 << 11);
uint16_t* location = reinterpret_cast<uint16_t*>(where);
uint16_t instruction = location[1] & ~((1 << 12) - 1);
instruction |= offset;
performJITMemcpy(location + 1, &instruction, sizeof(uint16_t));
cacheFlush(location, sizeof(uint16_t) * 2);
}
static void repatchPointer(void* where, void* value)
{
ASSERT(!(reinterpret_cast<intptr_t>(where) & 1));
setPointer(where, value, true);
}
static void* readPointer(void* where)
{
return reinterpret_cast<void*>(readInt32(where));
}
static void replaceWithBkpt(void* instructionStart)
{
ASSERT(!(bitwise_cast<uintptr_t>(instructionStart) & 1));
uint16_t* ptr = reinterpret_cast<uint16_t*>(instructionStart);
uint16_t instructions = OP_BKPT;
performJITMemcpy(ptr, &instructions, sizeof(uint16_t));
cacheFlush(ptr, sizeof(uint16_t));
}
static void replaceWithJump(void* instructionStart, void* to)
{
ASSERT(!(bitwise_cast<uintptr_t>(instructionStart) & 1));
ASSERT(!(bitwise_cast<uintptr_t>(to) & 1));
#if OS(LINUX)
if (canBeJumpT4(reinterpret_cast<uint16_t*>(instructionStart), to)) {
uint16_t* ptr = reinterpret_cast<uint16_t*>(instructionStart) + 2;
linkJumpT4(ptr, ptr, to);
cacheFlush(ptr - 2, sizeof(uint16_t) * 2);
} else {
uint16_t* ptr = reinterpret_cast<uint16_t*>(instructionStart) + 5;
linkBX(ptr, ptr, to);
cacheFlush(ptr - 5, sizeof(uint16_t) * 5);
}
#else
uint16_t* ptr = reinterpret_cast<uint16_t*>(instructionStart) + 2;
linkJumpT4(ptr, ptr, to);
cacheFlush(ptr - 2, sizeof(uint16_t) * 2);
#endif
}
static ptrdiff_t maxJumpReplacementSize()
{
#if OS(LINUX)
return 10;
#else
return 4;
#endif
}
static constexpr ptrdiff_t patchableJumpSize()
{
return 10;
}
static void replaceWithLoad(void* instructionStart)
{
ASSERT(!(bitwise_cast<uintptr_t>(instructionStart) & 1));
uint16_t* ptr = reinterpret_cast<uint16_t*>(instructionStart);
switch (ptr[0] & 0xFFF0) {
case OP_LDR_imm_T3:
break;
case OP_ADD_imm_T3: {
ASSERT(!(ptr[1] & 0xF000));
uint16_t instructions[2];
instructions[0] = ptr[0] & 0x000F;
instructions[0] |= OP_LDR_imm_T3;
instructions[1] = ptr[1] | (ptr[1] & 0x0F00) << 4;
instructions[1] &= 0xF0FF;
performJITMemcpy(ptr, instructions, sizeof(uint16_t) * 2);
cacheFlush(ptr, sizeof(uint16_t) * 2);
break;
}
default:
RELEASE_ASSERT_NOT_REACHED();
}
}
static void replaceWithAddressComputation(void* instructionStart)
{
ASSERT(!(bitwise_cast<uintptr_t>(instructionStart) & 1));
uint16_t* ptr = reinterpret_cast<uint16_t*>(instructionStart);
switch (ptr[0] & 0xFFF0) {
case OP_LDR_imm_T3: {
ASSERT(!(ptr[1] & 0x0F00));
uint16_t instructions[2];
instructions[0] = ptr[0] & 0x000F;
instructions[0] |= OP_ADD_imm_T3;
instructions[1] = ptr[1] | (ptr[1] & 0xF000) >> 4;
instructions[1] &= 0x0FFF;
performJITMemcpy(ptr, instructions, sizeof(uint16_t) * 2);
cacheFlush(ptr, sizeof(uint16_t) * 2);
break;
}
case OP_ADD_imm_T3:
break;
default:
RELEASE_ASSERT_NOT_REACHED();
}
}
unsigned debugOffset() { return m_formatter.debugOffset(); }
#if OS(LINUX)
static inline void linuxPageFlush(uintptr_t begin, uintptr_t end)
{
asm volatile(
"push {r7}\n"
"mov r0, %0\n"
"mov r1, %1\n"
"movw r7, #0x2\n"
"movt r7, #0xf\n"
"movs r2, #0x0\n"
"svc 0x0\n"
"pop {r7}\n"
:
: "r" (begin), "r" (end)
: "r0", "r1", "r2");
}
#endif
static void cacheFlush(void* code, size_t size)
{
#if OS(IOS)
sys_cache_control(kCacheFunctionPrepareForExecution, code, size);
#elif OS(LINUX)
size_t page = pageSize();
uintptr_t current = reinterpret_cast<uintptr_t>(code);
uintptr_t end = current + size;
uintptr_t firstPageEnd = (current & ~(page - 1)) + page;
if (end <= firstPageEnd) {
linuxPageFlush(current, end);
return;
}
linuxPageFlush(current, firstPageEnd);
for (current = firstPageEnd; current + page < end; current += page)
linuxPageFlush(current, current + page);
linuxPageFlush(current, end);
#else
#error "The cacheFlush support is missing on this platform."
#endif
}
private:
// VFP operations commonly take one or more 5-bit operands, typically representing a
// floating point register number. This will commonly be encoded in the instruction
// in two parts, with one single bit field, and one 4-bit field. In the case of
// double precision operands the high bit of the register number will be encoded
// separately, and for single precision operands the high bit of the register number
// will be encoded individually.
// VFPOperand encapsulates a 5-bit VFP operand, with bits 0..3 containing the 4-bit
// field to be encoded together in the instruction (the low 4-bits of a double
// register number, or the high 4-bits of a single register number), and bit 4
// contains the bit value to be encoded individually.
struct VFPOperand {
explicit VFPOperand(uint32_t value)
: m_value(value)
{
ASSERT(!(m_value & ~0x1f));
}
VFPOperand(FPDoubleRegisterID reg)
: m_value(reg)
{
}
VFPOperand(RegisterID reg)
: m_value(reg)
{
}
VFPOperand(FPSingleRegisterID reg)
: m_value(((reg & 1) << 4) | (reg >> 1)) // rotate the lowest bit of 'reg' to the top.
{
}
uint32_t bits1()
{
return m_value >> 4;
}
uint32_t bits4()
{
return m_value & 0xf;
}
uint32_t m_value;
};
VFPOperand vcvtOp(bool toInteger, bool isUnsigned, bool isRoundZero)
{
// Cannot specify rounding when converting to float.
ASSERT(toInteger || !isRoundZero);
uint32_t op = 0x8;
if (toInteger) {
// opc2 indicates both toInteger & isUnsigned.
op |= isUnsigned ? 0x4 : 0x5;
// 'op' field in instruction is isRoundZero
if (isRoundZero)
op |= 0x10;
} else {
ASSERT(!isRoundZero);
// 'op' field in instruction is isUnsigned
if (!isUnsigned)
op |= 0x10;
}
return VFPOperand(op);
}
static void setInt32(void* code, uint32_t value, bool flush)
{
uint16_t* location = reinterpret_cast<uint16_t*>(code);
ASSERT(isMOV_imm_T3(location - 4) && isMOVT(location - 2));
ARMThumbImmediate lo16 = ARMThumbImmediate::makeUInt16(static_cast<uint16_t>(value));
ARMThumbImmediate hi16 = ARMThumbImmediate::makeUInt16(static_cast<uint16_t>(value >> 16));
uint16_t instructions[4];
instructions[0] = twoWordOp5i6Imm4Reg4EncodedImmFirst(OP_MOV_imm_T3, lo16);
instructions[1] = twoWordOp5i6Imm4Reg4EncodedImmSecond((location[-3] >> 8) & 0xf, lo16);
instructions[2] = twoWordOp5i6Imm4Reg4EncodedImmFirst(OP_MOVT, hi16);
instructions[3] = twoWordOp5i6Imm4Reg4EncodedImmSecond((location[-1] >> 8) & 0xf, hi16);
performJITMemcpy(location - 4, instructions, 4 * sizeof(uint16_t));
if (flush)
cacheFlush(location - 4, 4 * sizeof(uint16_t));
}
static int32_t readInt32(void* code)
{
uint16_t* location = reinterpret_cast<uint16_t*>(code);
ASSERT(isMOV_imm_T3(location - 4) && isMOVT(location - 2));
ARMThumbImmediate lo16;
ARMThumbImmediate hi16;
decodeTwoWordOp5i6Imm4Reg4EncodedImmFirst(lo16, location[-4]);
decodeTwoWordOp5i6Imm4Reg4EncodedImmSecond(lo16, location[-3]);
decodeTwoWordOp5i6Imm4Reg4EncodedImmFirst(hi16, location[-2]);
decodeTwoWordOp5i6Imm4Reg4EncodedImmSecond(hi16, location[-1]);
uint32_t result = hi16.asUInt16();
result <<= 16;
result |= lo16.asUInt16();
return static_cast<int32_t>(result);
}
static void setUInt7ForLoad(void* code, ARMThumbImmediate imm)
{
// Requires us to have planted a LDR_imm_T1
ASSERT(imm.isValid());
ASSERT(imm.isUInt7());
uint16_t* location = reinterpret_cast<uint16_t*>(code);
uint16_t instruction;
instruction = location[0] & ~((static_cast<uint16_t>(0x7f) >> 2) << 6);
instruction |= (imm.getUInt7() >> 2) << 6;
performJITMemcpy(location, &instruction, sizeof(uint16_t));
cacheFlush(location, sizeof(uint16_t));
}
static void setPointer(void* code, void* value, bool flush)
{
setInt32(code, reinterpret_cast<uint32_t>(value), flush);
}
static bool isB(const void* address)
{
const uint16_t* instruction = static_cast<const uint16_t*>(address);
return ((instruction[0] & 0xf800) == OP_B_T4a) && ((instruction[1] & 0xd000) == OP_B_T4b);
}
static bool isBX(const void* address)
{
const uint16_t* instruction = static_cast<const uint16_t*>(address);
return (instruction[0] & 0xff87) == OP_BX;
}
static bool isMOV_imm_T3(const void* address)
{
const uint16_t* instruction = static_cast<const uint16_t*>(address);
return ((instruction[0] & 0xFBF0) == OP_MOV_imm_T3) && ((instruction[1] & 0x8000) == 0);
}
static bool isMOVT(const void* address)
{
const uint16_t* instruction = static_cast<const uint16_t*>(address);
return ((instruction[0] & 0xFBF0) == OP_MOVT) && ((instruction[1] & 0x8000) == 0);
}
static bool isNOP_T1(const void* address)
{
const uint16_t* instruction = static_cast<const uint16_t*>(address);
return instruction[0] == OP_NOP_T1;
}
static bool isNOP_T2(const void* address)
{
const uint16_t* instruction = static_cast<const uint16_t*>(address);
return (instruction[0] == OP_NOP_T2a) && (instruction[1] == OP_NOP_T2b);
}
static bool canBeJumpT1(const uint16_t* instruction, const void* target)
{
ASSERT(!(reinterpret_cast<intptr_t>(instruction) & 1));
ASSERT(!(reinterpret_cast<intptr_t>(target) & 1));
intptr_t relative = reinterpret_cast<intptr_t>(target) - (reinterpret_cast<intptr_t>(instruction));
// It does not appear to be documented in the ARM ARM (big surprise), but
// for OP_B_T1 the branch displacement encoded in the instruction is 2
// less than the actual displacement.
relative -= 2;
return ((relative << 23) >> 23) == relative;
}
static bool canBeJumpT2(const uint16_t* instruction, const void* target)
{
ASSERT(!(reinterpret_cast<intptr_t>(instruction) & 1));
ASSERT(!(reinterpret_cast<intptr_t>(target) & 1));
intptr_t relative = reinterpret_cast<intptr_t>(target) - (reinterpret_cast<intptr_t>(instruction));
// It does not appear to be documented in the ARM ARM (big surprise), but
// for OP_B_T2 the branch displacement encoded in the instruction is 2
// less than the actual displacement.
relative -= 2;
return ((relative << 20) >> 20) == relative;
}
static bool canBeJumpT3(const uint16_t* instruction, const void* target)
{
ASSERT(!(reinterpret_cast<intptr_t>(instruction) & 1));
ASSERT(!(reinterpret_cast<intptr_t>(target) & 1));
intptr_t relative = reinterpret_cast<intptr_t>(target) - (reinterpret_cast<intptr_t>(instruction));
return ((relative << 11) >> 11) == relative;
}
static bool canBeJumpT4(const uint16_t* instruction, const void* target)
{
ASSERT(!(reinterpret_cast<intptr_t>(instruction) & 1));
ASSERT(!(reinterpret_cast<intptr_t>(target) & 1));
intptr_t relative = reinterpret_cast<intptr_t>(target) - (reinterpret_cast<intptr_t>(instruction));
return ((relative << 7) >> 7) == relative;
}
static void linkJumpT1(Condition cond, uint16_t* writeTarget, const uint16_t* instruction, void* target)
{
// FIMXE: this should be up in the MacroAssembler layer. :-(
ASSERT(!(reinterpret_cast<intptr_t>(instruction) & 1));
ASSERT(!(reinterpret_cast<intptr_t>(target) & 1));
ASSERT(canBeJumpT1(instruction, target));
intptr_t relative = reinterpret_cast<intptr_t>(target) - (reinterpret_cast<intptr_t>(instruction));
// It does not appear to be documented in the ARM ARM (big surprise), but
// for OP_B_T1 the branch displacement encoded in the instruction is 2
// less than the actual displacement.
relative -= 2;
// All branch offsets should be an even distance.
ASSERT(!(relative & 1));
uint16_t newInstruction = OP_B_T1 | ((cond & 0xf) << 8) | ((relative & 0x1fe) >> 1);
performJITMemcpy(writeTarget - 1, &newInstruction, sizeof(uint16_t));
}
static void linkJumpT2(uint16_t* writeTarget, const uint16_t* instruction, void* target)
{
// FIMXE: this should be up in the MacroAssembler layer. :-(
ASSERT(!(reinterpret_cast<intptr_t>(instruction) & 1));
ASSERT(!(reinterpret_cast<intptr_t>(target) & 1));
ASSERT(canBeJumpT2(instruction, target));
intptr_t relative = reinterpret_cast<intptr_t>(target) - (reinterpret_cast<intptr_t>(instruction));
// It does not appear to be documented in the ARM ARM (big surprise), but
// for OP_B_T2 the branch displacement encoded in the instruction is 2
// less than the actual displacement.
relative -= 2;
// All branch offsets should be an even distance.
ASSERT(!(relative & 1));
uint16_t newInstruction = OP_B_T2 | ((relative & 0xffe) >> 1);
performJITMemcpy(writeTarget - 1, &newInstruction, sizeof(uint16_t));
}
static void linkJumpT3(Condition cond, uint16_t* writeTarget, const uint16_t* instruction, void* target)
{
// FIMXE: this should be up in the MacroAssembler layer. :-(
ASSERT(!(reinterpret_cast<intptr_t>(instruction) & 1));
ASSERT(!(reinterpret_cast<intptr_t>(target) & 1));
ASSERT(canBeJumpT3(instruction, target));
intptr_t relative = reinterpret_cast<intptr_t>(target) - (reinterpret_cast<intptr_t>(instruction));
// All branch offsets should be an even distance.
ASSERT(!(relative & 1));
uint16_t instructions[2];
instructions[0] = OP_B_T3a | ((relative & 0x100000) >> 10) | ((cond & 0xf) << 6) | ((relative & 0x3f000) >> 12);
instructions[1] = OP_B_T3b | ((relative & 0x80000) >> 8) | ((relative & 0x40000) >> 5) | ((relative & 0xffe) >> 1);
performJITMemcpy(writeTarget - 2, instructions, 2 * sizeof(uint16_t));
}
static void linkJumpT4(uint16_t* writeTarget, const uint16_t* instruction, void* target)
{
// FIMXE: this should be up in the MacroAssembler layer. :-(
ASSERT(!(reinterpret_cast<intptr_t>(instruction) & 1));
ASSERT(!(reinterpret_cast<intptr_t>(target) & 1));
ASSERT(canBeJumpT4(instruction, target));
intptr_t relative = reinterpret_cast<intptr_t>(target) - (reinterpret_cast<intptr_t>(instruction));
// ARM encoding for the top two bits below the sign bit is 'peculiar'.
if (relative >= 0)
relative ^= 0xC00000;
// All branch offsets should be an even distance.
ASSERT(!(relative & 1));
uint16_t instructions[2];
instructions[0] = OP_B_T4a | ((relative & 0x1000000) >> 14) | ((relative & 0x3ff000) >> 12);
instructions[1] = OP_B_T4b | ((relative & 0x800000) >> 10) | ((relative & 0x400000) >> 11) | ((relative & 0xffe) >> 1);
performJITMemcpy(writeTarget - 2, instructions, 2 * sizeof(uint16_t));
}
static void linkConditionalJumpT4(Condition cond, uint16_t* writeTarget, const uint16_t* instruction, void* target)
{
// FIMXE: this should be up in the MacroAssembler layer. :-(
ASSERT(!(reinterpret_cast<intptr_t>(instruction) & 1));
ASSERT(!(reinterpret_cast<intptr_t>(target) & 1));
uint16_t newInstruction = ifThenElse(cond) | OP_IT;
performJITMemcpy(writeTarget - 3, &newInstruction, sizeof(uint16_t));
linkJumpT4(writeTarget, instruction, target);
}
static void linkBX(uint16_t* writeTarget, const uint16_t* instruction, void* target)
{
// FIMXE: this should be up in the MacroAssembler layer. :-(
ASSERT_UNUSED(instruction, !(reinterpret_cast<intptr_t>(instruction) & 1));
ASSERT(!(reinterpret_cast<intptr_t>(writeTarget) & 1));
ASSERT(!(reinterpret_cast<intptr_t>(target) & 1));
const uint16_t JUMP_TEMPORARY_REGISTER = ARMRegisters::ip;
ARMThumbImmediate lo16 = ARMThumbImmediate::makeUInt16(static_cast<uint16_t>(reinterpret_cast<uint32_t>(target) + 1));
ARMThumbImmediate hi16 = ARMThumbImmediate::makeUInt16(static_cast<uint16_t>(reinterpret_cast<uint32_t>(target) >> 16));
uint16_t instructions[5];
instructions[0] = twoWordOp5i6Imm4Reg4EncodedImmFirst(OP_MOV_imm_T3, lo16);
instructions[1] = twoWordOp5i6Imm4Reg4EncodedImmSecond(JUMP_TEMPORARY_REGISTER, lo16);
instructions[2] = twoWordOp5i6Imm4Reg4EncodedImmFirst(OP_MOVT, hi16);
instructions[3] = twoWordOp5i6Imm4Reg4EncodedImmSecond(JUMP_TEMPORARY_REGISTER, hi16);
instructions[4] = OP_BX | (JUMP_TEMPORARY_REGISTER << 3);
performJITMemcpy(writeTarget - 5, instructions, 5 * sizeof(uint16_t));
}
static void linkConditionalBX(Condition cond, uint16_t* writeTarget, const uint16_t* instruction, void* target)
{
// FIMXE: this should be up in the MacroAssembler layer. :-(
ASSERT(!(reinterpret_cast<intptr_t>(instruction) & 1));
ASSERT(!(reinterpret_cast<intptr_t>(target) & 1));
linkBX(writeTarget, instruction, target);
uint16_t newInstruction = ifThenElse(cond, true, true) | OP_IT;
performJITMemcpy(writeTarget - 6, &newInstruction, sizeof(uint16_t));
}
static void linkJumpAbsolute(uint16_t* writeTarget, const uint16_t* instruction, void* target)
{
// FIMXE: this should be up in the MacroAssembler layer. :-(
ASSERT(!(reinterpret_cast<intptr_t>(instruction) & 1));
ASSERT(!(reinterpret_cast<intptr_t>(target) & 1));
ASSERT((isMOV_imm_T3(instruction - 5) && isMOVT(instruction - 3) && isBX(instruction - 1))
|| (isNOP_T1(instruction - 5) && isNOP_T2(instruction - 4) && isB(instruction - 2)));
if (canBeJumpT4(instruction, target)) {
// There may be a better way to fix this, but right now put the NOPs first, since in the
// case of an conditional branch this will be coming after an ITTT predicating *three*
// instructions! Looking backwards to modify the ITTT to an IT is not easy, due to
// variable wdith encoding - the previous instruction might *look* like an ITTT but
// actually be the second half of a 2-word op.
uint16_t instructions[3];
instructions[0] = OP_NOP_T1;
instructions[1] = OP_NOP_T2a;
instructions[2] = OP_NOP_T2b;
performJITMemcpy(writeTarget - 5, instructions, 3 * sizeof(uint16_t));
linkJumpT4(writeTarget, instruction, target);
} else {
const uint16_t JUMP_TEMPORARY_REGISTER = ARMRegisters::ip;
ARMThumbImmediate lo16 = ARMThumbImmediate::makeUInt16(static_cast<uint16_t>(reinterpret_cast<uint32_t>(target) + 1));
ARMThumbImmediate hi16 = ARMThumbImmediate::makeUInt16(static_cast<uint16_t>(reinterpret_cast<uint32_t>(target) >> 16));
uint16_t instructions[5];
instructions[0] = twoWordOp5i6Imm4Reg4EncodedImmFirst(OP_MOV_imm_T3, lo16);
instructions[1] = twoWordOp5i6Imm4Reg4EncodedImmSecond(JUMP_TEMPORARY_REGISTER, lo16);
instructions[2] = twoWordOp5i6Imm4Reg4EncodedImmFirst(OP_MOVT, hi16);
instructions[3] = twoWordOp5i6Imm4Reg4EncodedImmSecond(JUMP_TEMPORARY_REGISTER, hi16);
instructions[4] = OP_BX | (JUMP_TEMPORARY_REGISTER << 3);
performJITMemcpy(writeTarget - 5, instructions, 5 * sizeof(uint16_t));
}
}
static uint16_t twoWordOp5i6Imm4Reg4EncodedImmFirst(uint16_t op, ARMThumbImmediate imm)
{
return op | (imm.m_value.i << 10) | imm.m_value.imm4;
}
static void decodeTwoWordOp5i6Imm4Reg4EncodedImmFirst(ARMThumbImmediate& result, uint16_t value)
{
result.m_value.i = (value >> 10) & 1;
result.m_value.imm4 = value & 15;
}
static uint16_t twoWordOp5i6Imm4Reg4EncodedImmSecond(uint16_t rd, ARMThumbImmediate imm)
{
return (imm.m_value.imm3 << 12) | (rd << 8) | imm.m_value.imm8;
}
static void decodeTwoWordOp5i6Imm4Reg4EncodedImmSecond(ARMThumbImmediate& result, uint16_t value)
{
result.m_value.imm3 = (value >> 12) & 7;
result.m_value.imm8 = value & 255;
}
class ARMInstructionFormatter {
public:
ALWAYS_INLINE void oneWordOp5Reg3Imm8(OpcodeID op, RegisterID rd, uint8_t imm)
{
m_buffer.putShort(op | (rd << 8) | imm);
}
ALWAYS_INLINE void oneWordOp5Imm5Reg3Reg3(OpcodeID op, uint8_t imm, RegisterID reg1, RegisterID reg2)
{
m_buffer.putShort(op | (imm << 6) | (reg1 << 3) | reg2);
}
ALWAYS_INLINE void oneWordOp7Reg3Reg3Reg3(OpcodeID op, RegisterID reg1, RegisterID reg2, RegisterID reg3)
{
m_buffer.putShort(op | (reg1 << 6) | (reg2 << 3) | reg3);
}
ALWAYS_INLINE void oneWordOp7Imm9(OpcodeID op, uint16_t imm)
{
m_buffer.putShort(op | imm);
}
ALWAYS_INLINE void oneWordOp8Imm8(OpcodeID op, uint8_t imm)
{
m_buffer.putShort(op | imm);
}
ALWAYS_INLINE void oneWordOp8RegReg143(OpcodeID op, RegisterID reg1, RegisterID reg2)
{
m_buffer.putShort(op | ((reg2 & 8) << 4) | (reg1 << 3) | (reg2 & 7));
}
ALWAYS_INLINE void oneWordOp9Imm7(OpcodeID op, uint8_t imm)
{
m_buffer.putShort(op | imm);
}
ALWAYS_INLINE void oneWordOp10Reg3Reg3(OpcodeID op, RegisterID reg1, RegisterID reg2)
{
m_buffer.putShort(op | (reg1 << 3) | reg2);
}
ALWAYS_INLINE void twoWordOp12Reg4FourFours(OpcodeID1 op, RegisterID reg, FourFours ff)
{
m_buffer.putShort(op | reg);
m_buffer.putShort(ff.m_u.value);
}
ALWAYS_INLINE void twoWordOp16FourFours(OpcodeID1 op, FourFours ff)
{
m_buffer.putShort(op);
m_buffer.putShort(ff.m_u.value);
}
ALWAYS_INLINE void twoWordOp16Op16(OpcodeID1 op1, OpcodeID2 op2)
{
m_buffer.putShort(op1);
m_buffer.putShort(op2);
}
ALWAYS_INLINE void twoWordOp16Imm16(OpcodeID1 op1, uint16_t imm)
{
m_buffer.putShort(op1);
m_buffer.putShort(imm);
}
ALWAYS_INLINE void twoWordOp12Reg4Reg4Reg4Op4Reg4(OpcodeID1 op1, OpcodeID2 op2, RegisterID reg1,
RegisterID reg2, RegisterID reg3, RegisterID reg4)
{
m_buffer.putShort(op1 | reg1);
m_buffer.putShort((reg2 << 12) | (reg3 << 8) | op2 | reg4);
}
ALWAYS_INLINE void twoWordOp12Reg4Reg4Reg4Op8(OpcodeID1 op1, OpcodeID2 op2, RegisterID reg1,
RegisterID reg2, RegisterID reg3)
{
m_buffer.putShort(op1 | reg1);
m_buffer.putShort((reg2 << 12) | (reg3 << 8) | op2);
}
ALWAYS_INLINE void twoWordOp5i6Imm4Reg4EncodedImm(OpcodeID1 op, int imm4, RegisterID rd, ARMThumbImmediate imm)
{
ARMThumbImmediate newImm = imm;
newImm.m_value.imm4 = imm4;
m_buffer.putShort(ARMv7Assembler::twoWordOp5i6Imm4Reg4EncodedImmFirst(op, newImm));
m_buffer.putShort(ARMv7Assembler::twoWordOp5i6Imm4Reg4EncodedImmSecond(rd, newImm));
}
ALWAYS_INLINE void twoWordOp12Reg4Reg4Imm12(OpcodeID1 op, RegisterID reg1, RegisterID reg2, uint16_t imm)
{
m_buffer.putShort(op | reg1);
m_buffer.putShort((reg2 << 12) | imm);
}
ALWAYS_INLINE void twoWordOp12Reg40Imm3Reg4Imm20Imm5(OpcodeID1 op, RegisterID reg1, RegisterID reg2, uint16_t imm1, uint16_t imm2, uint16_t imm3)
{
m_buffer.putShort(op | reg1);
m_buffer.putShort((imm1 << 12) | (reg2 << 8) | (imm2 << 6) | imm3);
}
// Formats up instructions of the pattern:
// 111111111B11aaaa:bbbb222SA2C2cccc
// Where 1s in the pattern come from op1, 2s in the pattern come from op2, S is the provided size bit.
// Operands provide 5 bit values of the form Aaaaa, Bbbbb, Ccccc.
ALWAYS_INLINE void vfpOp(OpcodeID1 op1, OpcodeID2 op2, bool size, VFPOperand a, VFPOperand b, VFPOperand c)
{
ASSERT(!(op1 & 0x004f));
ASSERT(!(op2 & 0xf1af));
m_buffer.putShort(op1 | b.bits1() << 6 | a.bits4());
m_buffer.putShort(op2 | b.bits4() << 12 | size << 8 | a.bits1() << 7 | c.bits1() << 5 | c.bits4());
}
// Arm vfp addresses can be offset by a 9-bit ones-comp immediate, left shifted by 2.
// (i.e. +/-(0..255) 32-bit words)
ALWAYS_INLINE void vfpMemOp(OpcodeID1 op1, OpcodeID2 op2, bool size, RegisterID rn, VFPOperand rd, int32_t imm)
{
bool up = true;
if (imm < 0) {
imm = -imm;
up = false;
}
uint32_t offset = imm;
ASSERT(!(offset & ~0x3fc));
offset >>= 2;
m_buffer.putShort(op1 | (up << 7) | rd.bits1() << 6 | rn);
m_buffer.putShort(op2 | rd.bits4() << 12 | size << 8 | offset);
}
// Administrative methods:
size_t codeSize() const { return m_buffer.codeSize(); }
AssemblerLabel label() const { return m_buffer.label(); }
bool isAligned(int alignment) const { return m_buffer.isAligned(alignment); }
void* data() const { return m_buffer.data(); }
unsigned debugOffset() { return m_buffer.debugOffset(); }
AssemblerBuffer m_buffer;
} m_formatter;
Vector<LinkRecord, 0, UnsafeVectorOverflow> m_jumpsToLink;
int m_indexOfLastWatchpoint;
int m_indexOfTailOfLastWatchpoint;
};
} // namespace JSC
#endif // ENABLE(ASSEMBLER) && CPU(ARM_THUMB2)
| [
"[email protected]"
] | |
4cf37533c437231ea2051d6351786eef7a57b358 | d17a8870ff8ac77b82d0d37e20c85b23aa29ca74 | /lite/kernels/host/select_input_compute.h | a8bfc692515b7a169506f1f9e485fb6d3b5b7678 | [
"Apache-2.0"
] | permissive | PaddlePaddle/Paddle-Lite | 4ab49144073451d38da6f085a8c56822caecd5b2 | e241420f813bd91f5164f0d9ee0bc44166c0a172 | refs/heads/develop | 2023-09-02T05:28:14.017104 | 2023-09-01T10:32:39 | 2023-09-01T10:32:39 | 104,208,128 | 2,545 | 1,041 | Apache-2.0 | 2023-09-12T06:46:10 | 2017-09-20T11:41:42 | C++ | UTF-8 | C++ | false | false | 1,344 | h | // Copyright (c) 2019 PaddlePaddle Authors. All Rights Reserved.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
#pragma once
#include <algorithm>
#include <string>
#include "lite/core/kernel.h"
#include "lite/core/op_registry.h"
namespace paddle {
namespace lite {
namespace kernels {
namespace host {
class SelectInputCompute : public KernelLite<TARGET(kHost), PRECISION(kAny)> {
public:
using param_t = operators::SelectInputParam;
void Run() override;
virtual ~SelectInputCompute() = default;
#ifdef LITE_WITH_PROFILE
virtual void SetProfileRuntimeKernelInfo(
paddle::lite::profile::OpCharacter* ch) {
ch->kernel_func_name = kernel_func_name_;
}
std::string kernel_func_name_{"NotImplForSelectInput"};
#endif
};
} // namespace host
} // namespace kernels
} // namespace lite
} // namespace paddle
| [
"[email protected]"
] | |
45fb9ae292c707edc801702c2369dec3fd5eda07 | 9137ac4e2cdde893f326eafecf0af9b9b54fd254 | /tic_tac_toe/src/min_max_impl/engine_mmg.hpp | 9d1547760e9f21d9367cbac19039783637cc0d1f | [] | no_license | boutboutnico/game | 1be06e6685223bf3a3638fa498beee4a9c158691 | f3cabc03bbf4f1140bc52bf69fa8447e038b4d8b | refs/heads/master | 2021-01-10T21:15:41.072587 | 2015-07-23T12:38:12 | 2015-07-23T12:38:12 | 38,621,126 | 0 | 0 | null | 2015-07-23T12:18:03 | 2015-07-06T13:36:55 | C++ | UTF-8 | C++ | false | false | 1,641 | hpp | ///
/// \file ai_engine_wrapper.h
/// \brief
/// \date 16 juil. 2015
/// \author nboutin
///
#ifndef ENGINE_GMM_HPP_
#define ENGINE_GMM_HPP_
/// === Includes ================================================================================
#include <min_max_generic/min_max_engine.hpp>
#include "engine/engine.hpp"
/// === Namespaces ================================================================================
namespace tic_tac_toe
{
struct move_t
{
move_t() = default;
move_t(uint8_t _x, uint8_t _y)
: x_(_x), y_(_y)
{
}
uint8_t x_ = 0;
uint8_t y_ = 0;
};
/// === Class Declarations ========================================================================
class Engine_MMG : public ai::min_max::Min_Max_Engine<move_t>
{
public:
/// === Public Declarations ====================================================================
Engine_MMG(Engine& _engine, const std::string& _ai_player);
virtual std::vector<move_t> get_moves() const;
virtual void execute_move(const move_t& _move) const;
virtual void undo_move(const move_t& _move) const;
virtual int16_t eval() const;
virtual bool is_game_finished() const
{
return engine_.is_game_finished();
}
private:
/// === Private Declarations ================================================================
/// === Private Attributs ====================================================================
Engine& engine_;
std::string ai_player_;
};
/// ------------------------------------------------------------------------------------------------
}
#endif
/// === END OF FILE ================================================================================
| [
"[email protected]"
] | |
24caf893db9d5e6e0f09a79f8384c38468887455 | 0a3a009fa93539a2b45b5642341f4cb0c5c62df5 | /Axis.Mint/services/language/primitives/Parser.cpp | 62ea232451d428c2ff2f7ee4c220e1162e47af28 | [
"MIT"
] | permissive | renato-yuzup/axis-fem | 5bdb610457013d78a9f62496d4a0ba5e68a5a966 | 2e8d325eb9c8e99285f513b4c1218ef53eb0ab22 | refs/heads/master | 2020-04-28T19:54:21.273024 | 2019-03-31T22:04:22 | 2019-03-31T22:04:22 | 175,526,004 | 4 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 2,199 | cpp | #include "Parser.hpp"
#include "ParserImpl.hpp"
namespace asla = axis::services::language::actions;
namespace asli = axis::services::language::iterators;
namespace aslp = axis::services::language::parsing;
namespace aslpp = axis::services::language::primitives;
aslpp::Parser::Parser( const Parser& other )
{
parserImpl_ = NULL;
lastParserImplInChain_ = NULL;
Copy(other);
}
aslpp::Parser::Parser( ParserImpl& implementationLogic )
{
// increment reference counter
parserImpl_ = &implementationLogic;
lastParserImplInChain_ = parserImpl_;
implementationLogic.NotifyUse();
}
aslpp::Parser::Parser( ParserImpl *firstParserInChain, ParserImpl *lastParserInChain )
{
parserImpl_ = firstParserInChain;
lastParserImplInChain_ = lastParserInChain;
parserImpl_->NotifyUse();
}
aslpp::Parser::~Parser( void )
{
// decrement reference counter
parserImpl_->NotifyDestroy();
/*
NOTE: we are not notifying other parsers to destroy because that will
be done by the first parser in chain
*/
}
aslp::ParseResult aslpp::Parser::Parse( const asli::InputIterator& begin,
const asli::InputIterator& end, bool trimSpaces /*= true*/ ) const
{
return parserImpl_->Parse(begin, end, trimSpaces);
}
aslpp::Parser& aslpp::Parser::operator=( const Parser& other )
{
Copy(other);
return *this;
}
void aslpp::Parser::Copy( const Parser& other )
{
if (other.parserImpl_ == this->parserImpl_)
{ // uses the same business object, ignore it
return;
}
if (parserImpl_ != NULL)
{
parserImpl_->NotifyDestroy();
}
parserImpl_ = other.parserImpl_;
parserImpl_->NotifyUse();
lastParserImplInChain_ = other.lastParserImplInChain_;
}
aslpp::Parser& aslpp::Parser::AddAction( const asla::ParserAction& action )
{
parserImpl_->AddAction(action);
return *this;
}
aslpp::Parser& aslpp::Parser::operator<<( const asla::ParserAction& action )
{
return AddAction(action);
}
aslp::ParseResult aslpp::Parser::operator()( const asli::InputIterator& begin,
const asli::InputIterator& end,
bool trimSpaces /*= true*/ ) const
{
return Parse(begin, end, trimSpaces);
}
| [
"[email protected]"
] | |
9d7bf929cfb1dbbaae48265032334951031be795 | 836d3d8aaaf4abcc59f6a0be1e9678d10877fe22 | /OSSIA/ossia/network/websocket-generic-client/ws_generic_client_protocol.hpp | 35085f861c3adead06313c26359896d3278e08b7 | [] | no_license | avilleret/API | c8a3a7eb132fa0a2e89ece976050d46332cc7acb | e585a160a4b6acab305b614791d75dd2c28f5a12 | refs/heads/master | 2020-06-13T20:03:32.779677 | 2016-12-04T00:15:11 | 2016-12-04T00:15:11 | 75,563,833 | 0 | 0 | null | 2016-12-04T20:53:04 | 2016-12-04T20:53:04 | null | UTF-8 | C++ | false | false | 1,865 | hpp | #pragma once
#include <ossia/network/base/protocol.hpp>
#include <ossia/network/websocket-generic-client/ws_generic_client_address.hpp>
#include <QList>
#include <QByteArray>
#include <QJSValue>
#include <QObject>
class QQmlEngine;
class QQmlComponent;
class QWebSocket;
class QNetworkReply;
namespace ossia
{
namespace net
{
class ws_generic_client_device;
class ws_generic_client_node;
class ws_generic_client_address;
class OSSIA_EXPORT ws_generic_client_protocol final :
public QObject,
public ossia::net::protocol_base
{
Q_OBJECT
public:
ws_generic_client_protocol(const QString& addr, QByteArray code);
ws_generic_client_protocol(const ws_generic_client_protocol&) = delete;
ws_generic_client_protocol(ws_generic_client_protocol&&) = delete;
ws_generic_client_protocol& operator=(const ws_generic_client_protocol&) = delete;
ws_generic_client_protocol& operator=(ws_generic_client_protocol&&) = delete;
~ws_generic_client_protocol();
bool update(ossia::net::node_base& node_base) override;
bool pull(ossia::net::address_base& address_base) override;
bool push(const ossia::net::address_base& address_base) override;
bool observe(ossia::net::address_base& address_base, bool enable) override;
void setDevice(ossia::net::device_base& dev) override;
static ws_generic_client_address_data read_data(const QJSValue& js) { return js; }
signals:
void sig_push(const ws_generic_client_address*);
private slots:
void slot_push(const ws_generic_client_address*);
private:
void apply_reply(QJSValue);
QQmlEngine *mEngine{};
QQmlComponent* mComponent{};
QObject* mItem{};
QWebSocket* mWebsocket{};
QByteArray mCode;
ws_generic_client_device* mDevice{};
QList<std::pair<QNetworkReply*, const ws_generic_client_address*>> mReplies;
};
}
}
Q_DECLARE_METATYPE(ossia::net::ws_generic_client_address*)
| [
"[email protected]"
] | |
dc40a8cd843553ed8d0462d19c6e437367857f0e | a7ae0828130519464d310faee5a091c3ab6a95a0 | /autodock_vina_1_1_2/src/lib/jmetalcpp-old/src/main/PSO_main.cc | 4781c2ab62119549b4e3dfb71842c63868a21b5d | [
"Apache-2.0"
] | permissive | mjggodoy/AutoDockVinaMeta | 8974b7b39d64bc321132c675cee64743ecdf308b | 53bb092328024e97590c361c2aceb93c74cd726f | refs/heads/master | 2020-04-25T10:11:27.329688 | 2019-02-26T13:07:47 | 2019-02-26T13:07:47 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 2,737 | cc | // PSO_main.cpp
//
// Author:
// Esteban López-Camacho <[email protected]>
//
// Copyright (c) 2011 Antonio J. Nebro, Juan J. Durillo
//
// This program 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 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 Lesser General Public License for more details.
//
// You should have received a copy of the GNU Lesser General Public License
// along with this program. If not, see <http://www.gnu.org/licenses/>.
#include <Problem.hh>
#include <Algorithm.hh>
#include <Solution.hh>
#include <iostream>
#include <PSO.hh>
#include <time.h>
#include <PolynomialMutation.hh>
#include <ProblemFactory.hh>
int main(int argc, char ** argv) {
clock_t t_ini, t_fin;
Problem * problem ; // The problem to solve
Algorithm * algorithm ; // The algorithm to use
Operator * mutation ; // Mutation operator
if (argc>=2) {
problem = ProblemFactory::getProblem(argc, argv);
cout << "Selected problem: " << problem->getName() << endl;
} else {
cout << "No problem selected." << endl;
cout << "Default problem will be used: Sphere" << endl;
problem = ProblemFactory::getProblem(const_cast<char *>("Sphere"));
}
algorithm = new PSO(problem);
// Algorithm parameters
int swarmSize = 50;
int maxIterations = 5000;
algorithm->setInputParameter("swarmSize",&swarmSize);
algorithm->setInputParameter("maxIterations",&maxIterations);
// Mutation operator
map<string, void *> parameters;
double probability = 1.0/problem->getNumberOfVariables();
double distributionIndex = 20.0;
parameters["probability"] = &probability;
parameters["distributionIndex"] = &distributionIndex;
mutation = new PolynomialMutation(parameters);
// Add the operators to the algorithm
algorithm->addOperator("mutation",mutation);
// Execute the Algorithm
t_ini = clock();
SolutionSet * population = algorithm->execute();
t_fin = clock();
double secs = (double) (t_fin - t_ini);
secs = secs / CLOCKS_PER_SEC;
// Result messages
cout << "Total execution time: " << secs << "s" << endl;
cout << "Variables values have been written to file VAR" << endl;
population->printVariablesToFile("VAR");
cout << "Objectives values have been written to file FUN" << endl;
population->printObjectivesToFile("FUN");
delete mutation;
delete population;
delete algorithm;
} // main
| [
"[email protected]"
] | |
05849d32a4ee518ac6a80d6ff71431f1afa4b4a5 | 8f0696abb21731526c7d8c87a16f267655a9b2e4 | /public/speak.js/src/synthdata.cpp | 4ad64b362b325a87cd2cf81cd42ee24d770af71d | [
"MIT",
"GPL-3.0-only"
] | permissive | raimohanska/turtle-roy | 0139b7f2776ee9f014639c70e5371c5a65c963b4 | 8458b31c6438bbfd66b996f9dac56c0fb7f82fd8 | refs/heads/master | 2023-07-20T18:00:43.621752 | 2022-09-24T22:35:50 | 2022-09-24T22:35:50 | 6,905,143 | 17 | 11 | MIT | 2023-08-30T21:47:37 | 2012-11-28T16:15:19 | JavaScript | UTF-8 | C++ | false | false | 24,980 | cpp | /***************************************************************************
* Copyright (C) 2005 to 2011 by Jonathan Duddington *
* email: [email protected] *
* *
* 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 3 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 "StdAfx.h"
#include <stdio.h>
#include <stdlib.h>
#include <ctype.h>
#include <wctype.h>
#include <string.h>
#include "speak_lib.h"
#include "speech.h"
#include "phoneme.h"
#include "synthesize.h"
#include "voice.h"
#include "translate.h"
#include "wave.h"
const char *version_string = "1.45.04 25.Apr.11";
const int version_phdata = 0x014500;
int option_device_number = -1;
FILE *f_logespeak = NULL;
int logging_type;
// copy the current phoneme table into here
int n_phoneme_tab;
int current_phoneme_table;
PHONEME_TAB *phoneme_tab[N_PHONEME_TAB];
unsigned char phoneme_tab_flags[N_PHONEME_TAB]; // bit 0: not inherited
USHORT *phoneme_index=NULL;
char *phondata_ptr=NULL;
unsigned char *wavefile_data=NULL;
static unsigned char *phoneme_tab_data = NULL;
int n_phoneme_tables;
PHONEME_TAB_LIST phoneme_tab_list[N_PHONEME_TABS];
int phoneme_tab_number = 0;
int wavefile_ix; // a wavefile to play along with the synthesis
int wavefile_amp;
int wavefile_ix2;
int wavefile_amp2;
int seq_len_adjust;
int vowel_transition[4];
int vowel_transition0;
int vowel_transition1;
int FormantTransition2(frameref_t *seq, int &n_frames, unsigned int data1, unsigned int data2, PHONEME_TAB *other_ph, int which);
static char *ReadPhFile(void *ptr, const char *fname, int *size)
{//=============================================================
FILE *f_in;
char *p;
unsigned int length;
char buf[sizeof(path_home)+40];
sprintf(buf,"%s%c%s",path_home,PATHSEP,fname);
length = GetFileLength(buf);
if((f_in = fopen(buf,"rb")) == NULL)
{
fprintf(stderr,"Can't read data file: '%s'\n",buf);
return(NULL);
}
if(ptr != NULL)
Free(ptr);
if((p = Alloc(length)) == NULL)
{
fclose(f_in);
return(NULL);
}
if(fread(p,1,length,f_in) != length)
{
fclose(f_in);
return(NULL);
}
fclose(f_in);
if(size != NULL)
*size = length;
return(p);
} // end of ReadPhFile
int LoadPhData()
{//=============
int ix;
int n_phonemes;
int version;
int result = 1;
int length;
unsigned char *p;
int *pw;
if((phoneme_tab_data = (unsigned char *)ReadPhFile((void *)(phoneme_tab_data),"phontab",NULL)) == NULL)
return(-1);
if((phoneme_index = (USHORT *)ReadPhFile((void *)(phoneme_index),"phonindex",NULL)) == NULL)
return(-1);
if((phondata_ptr = ReadPhFile((void *)(phondata_ptr),"phondata",NULL)) == NULL)
return(-1);
if((tunes = (TUNE *)ReadPhFile((void *)(tunes),"intonations",&length)) == NULL)
return(-1);
wavefile_data = (unsigned char *)phondata_ptr;
n_tunes = length / sizeof(TUNE);
// read the version number from the first 4 bytes of phondata
version = 0;
for(ix=0; ix<4; ix++)
{
version += (wavefile_data[ix] << (ix*8));
}
if(version != version_phdata)
{
result = version;
}
// set up phoneme tables
p = phoneme_tab_data;
n_phoneme_tables = p[0];
p+=4;
for(ix=0; ix<n_phoneme_tables; ix++)
{
n_phonemes = p[0];
phoneme_tab_list[ix].n_phonemes = p[0];
phoneme_tab_list[ix].includes = p[1];
pw = (int *)p;
phoneme_tab_list[ix].equivalence_tables = Reverse4Bytes(pw[1]);
p += 8;
memcpy(phoneme_tab_list[ix].name,p,N_PHONEME_TAB_NAME);
p += N_PHONEME_TAB_NAME;
phoneme_tab_list[ix].phoneme_tab_ptr = (PHONEME_TAB *)p;
p += (n_phonemes * sizeof(PHONEME_TAB));
}
if(phoneme_tab_number >= n_phoneme_tables)
phoneme_tab_number = 0;
return(result);
} // end of LoadPhData
void FreePhData(void)
{//==================
Free(phoneme_tab_data);
Free(phoneme_index);
Free(phondata_ptr);
phoneme_tab_data=NULL;
phoneme_index=NULL;
phondata_ptr=NULL;
}
int PhonemeCode(unsigned int mnem)
{//===============================
int ix;
for(ix=0; ix<n_phoneme_tab; ix++)
{
if(phoneme_tab[ix] == NULL)
continue;
if(phoneme_tab[ix]->mnemonic == mnem)
return(phoneme_tab[ix]->code);
}
return(0);
}
int LookupPhonemeString(const char *string)
{//========================================
int ix;
unsigned char c;
unsigned int mnem;
// Pack up to 4 characters into a word
mnem = 0;
for(ix=0; ix<4; ix++)
{
if(string[ix]==0) break;
c = string[ix];
mnem |= (c << (ix*8));
}
return(PhonemeCode(mnem));
}
frameref_t *LookupSpect(PHONEME_TAB *this_ph, int which, FMT_PARAMS *fmt_params, int *n_frames, PHONEME_LIST *plist)
{//===================================================================================================================
int ix;
int nf;
int nf1;
int seq_break;
frameref_t *frames;
int length1;
int length_std;
int length_factor;
SPECT_SEQ *seq, *seq2;
SPECT_SEQK *seqk, *seqk2;
frame_t *frame;
static frameref_t frames_buf[N_SEQ_FRAMES];
seq = (SPECT_SEQ *)(&phondata_ptr[fmt_params->fmt_addr]);
seqk = (SPECT_SEQK *)seq;
nf = seq->n_frames;
if(nf >= N_SEQ_FRAMES)
nf = N_SEQ_FRAMES - 1;
seq_len_adjust = fmt_params->fmt2_lenadj + fmt_params->fmt_length;
seq_break = 0;
for(ix=0; ix<nf; ix++)
{
if(seq->frame[0].frflags & FRFLAG_KLATT)
frame = &seqk->frame[ix];
else
frame = (frame_t *)&seq->frame[ix];
frames_buf[ix].frame = frame;
frames_buf[ix].frflags = frame->frflags;
frames_buf[ix].length = frame->length;
if(frame->frflags & FRFLAG_VOWEL_CENTRE)
seq_break = ix;
}
frames = &frames_buf[0];
if(seq_break > 0)
{
if(which==1)
{
nf = seq_break + 1;
}
else
{
frames = &frames_buf[seq_break]; // body of vowel, skip past initial frames
nf -= seq_break;
}
}
// do we need to modify a frame for blending with a consonant?
if((this_ph->type == phVOWEL) && (fmt_params->fmt2_addr == 0) && (fmt_params->use_vowelin))
{
seq_len_adjust += FormantTransition2(frames,nf,fmt_params->transition0,fmt_params->transition1,NULL,which);
}
length1 = 0;
nf1 = nf - 1;
for(ix=0; ix<nf1; ix++)
length1 += frames[ix].length;
if(fmt_params->fmt2_addr != 0)
{
// a secondary reference has been returned, which is not a wavefile
// add these spectra to the main sequence
seq2 = (SPECT_SEQ *)(&phondata_ptr[fmt_params->fmt2_addr]);
seqk2 = (SPECT_SEQK *)seq2;
// first frame of the addition just sets the length of the last frame of the main seq
nf--;
for(ix=0; ix<seq2->n_frames; ix++)
{
if(seq2->frame[0].frflags & FRFLAG_KLATT)
frame = &seqk2->frame[ix];
else
frame = (frame_t *)&seq2->frame[ix];
frames[nf].length = frame->length;
if(ix > 0)
{
frames[nf].frame = frame;
frames[nf].frflags = frame->frflags;
}
nf++;
}
wavefile_ix = 0;
}
if(length1 > 0)
{
if(which==2)
{
// adjust the length of the main part to match the standard length specified for the vowel
// less the front part of the vowel and any added suffix
length_std = fmt_params->std_length + seq_len_adjust - 45;
if(length_std < 10)
length_std = 10;
if(plist->synthflags & SFLAG_LENGTHEN)
length_std += (phoneme_tab[phonLENGTHEN]->std_length * 2); // phoneme was followed by an extra : symbol
// can adjust vowel length for stressed syllables here
length_factor = (length_std * 256)/ length1;
for(ix=0; ix<nf1; ix++)
{
frames[ix].length = (frames[ix].length * length_factor)/256;
}
}
else
{
if(which == 1)
{
// front of a vowel
if(fmt_params->fmt_control == 1)
{
// This is the default start of a vowel.
// Allow very short vowels to have shorter front parts
if(fmt_params->std_length < 130)
frames[0].length = (frames[0].length * fmt_params->std_length)/130;
}
}
else
{
//not a vowel
if(fmt_params->std_length > 0)
{
seq_len_adjust += (fmt_params->std_length - length1);
}
}
if(seq_len_adjust != 0)
{
length_factor = ((length1 + seq_len_adjust) * 256)/length1;
for(ix=0; ix<nf1; ix++)
{
frames[ix].length = (frames[ix].length * length_factor)/256;
}
}
}
}
*n_frames = nf;
return(frames);
} // end of LookupSpect
unsigned char *GetEnvelope(int index)
{//==================================
if(index==0)
{
fprintf(stderr,"espeak: No envelope\n");
return(envelope_data[0]); // not found, use a default envelope
}
return((unsigned char *)&phondata_ptr[index]);
}
static void SetUpPhonemeTable(int number, int recursing)
{//=====================================================
int ix;
int includes;
int ph_code;
PHONEME_TAB *phtab;
if(recursing==0)
{
memset(phoneme_tab_flags,0,sizeof(phoneme_tab_flags));
}
if((includes = phoneme_tab_list[number].includes) > 0)
{
// recursively include base phoneme tables
SetUpPhonemeTable(includes-1,1);
}
// now add the phonemes from this table
phtab = phoneme_tab_list[number].phoneme_tab_ptr;
for(ix=0; ix<phoneme_tab_list[number].n_phonemes; ix++)
{
ph_code = phtab[ix].code;
phoneme_tab[ph_code] = &phtab[ix];
if(ph_code > n_phoneme_tab)
n_phoneme_tab = ph_code;
if(recursing == 0)
phoneme_tab_flags[ph_code] |= 1; // not inherited
}
} // end of SetUpPhonemeTable
void SelectPhonemeTable(int number)
{//================================
n_phoneme_tab = 0;
SetUpPhonemeTable(number,0); // recursively for included phoneme tables
n_phoneme_tab++;
current_phoneme_table = number;
} // end of SelectPhonemeTable
int LookupPhonemeTable(const char *name)
{//=====================================
int ix;
for(ix=0; ix<n_phoneme_tables; ix++)
{
if(strcmp(name,phoneme_tab_list[ix].name)==0)
{
phoneme_tab_number = ix;
break;
}
}
if(ix == n_phoneme_tables)
return(-1);
return(ix);
}
int SelectPhonemeTableName(const char *name)
{//=========================================
// Look up a phoneme set by name, and select it if it exists
// Returns the phoneme table number
int ix;
if((ix = LookupPhonemeTable(name)) == -1)
return(-1);
SelectPhonemeTable(ix);
return(ix);
} // end of DelectPhonemeTableName
void LoadConfig(void)
{//==================
// Load configuration file, if one exists
char buf[sizeof(path_home)+10];
FILE *f;
int ix;
char c1;
char *p;
char string[200];
logging_type = 0;
for(ix=0; ix<N_SOUNDICON_SLOTS; ix++)
{
soundicon_tab[ix].filename = NULL;
soundicon_tab[ix].data = NULL;
}
sprintf(buf,"%s%c%s",path_home,PATHSEP,"config");
if((f = fopen(buf,"r"))==NULL)
{
return;
}
while(fgets(buf,sizeof(buf),f)!=NULL)
{
if(buf[0] == '/') continue;
if(memcmp(buf,"log",3)==0)
{
if(sscanf(&buf[4],"%d %s",&logging_type,string)==2)
f_logespeak = fopen(string,"w");
}
else
if(memcmp(buf,"tone",4)==0)
{
ReadTonePoints(&buf[5],tone_points);
}
else
if(memcmp(buf,"pa_device",9)==0)
{
sscanf(&buf[10],"%d",&option_device_number);
}
else
if(memcmp(buf,"soundicon",9)==0)
{
ix = sscanf(&buf[10],"_%c %s",&c1,string);
if(ix==2)
{
soundicon_tab[n_soundicon_tab].name = c1;
p = Alloc(strlen(string)+1);
strcpy(p,string);
soundicon_tab[n_soundicon_tab].filename = p;
soundicon_tab[n_soundicon_tab++].length = 0;
}
}
}
} // end of LoadConfig
PHONEME_DATA this_ph_data;
static void InvalidInstn(PHONEME_TAB *ph, int instn)
{//====================================================
fprintf(stderr,"Invalid instruction %.4x for phoneme '%s'\n", instn, WordToString(ph->mnemonic));
}
static bool StressCondition(Translator *tr, PHONEME_LIST *plist, int condition, int control)
{//========================================================================================
// condition:
// 0 if diminished, 1 if unstressed, 2 if not stressed, 3 if stressed, 4 if max stress
int stress_level;
PHONEME_LIST *pl;
static int condition_level[4] = {1,2,4,15};
if(phoneme_tab[plist[0].phcode]->type == phVOWEL)
{
pl = plist;
}
else
{
// consonant, get stress from the following vowel
if(phoneme_tab[plist[1].phcode]->type == phVOWEL)
{
pl = &plist[1];
}
else
return(false); // no stress elevel for this consonant
}
stress_level = pl->stresslevel & 0xf;
if(tr != NULL)
{
if((control & 1) && (plist->synthflags & SFLAG_DICTIONARY) && ((tr->langopts.param[LOPT_REDUCE] & 1)==0))
{
// change phoneme. Don't change phonemes which are given for the word in the dictionary.
return(false);
}
if((tr->langopts.param[LOPT_REDUCE] & 0x2) && (stress_level >= pl->wordstress))
{
// treat the most stressed syllable in an unstressed word as stressed
stress_level = 4;
}
}
if(condition == 4)
{
return(stress_level >= pl->wordstress);
}
if(condition == 3)
{
// if stressed
if(stress_level > 3)
return(true);
}
else
{
if(stress_level < condition_level[condition])
return(true);
}
return(false);
} // end of StressCondition
static bool InterpretCondition(Translator *tr, int control, PHONEME_LIST *plist, int instn)
{//========================================================================================
int which;
unsigned int data;
int instn2;
int count;
PHONEME_TAB *ph;
PHONEME_LIST *plist_this;
static int ph_position[8] = {0, 1, 2, 3, 2, 0, 1, 3}; // prevPh, thisPh, nextPh, next2Ph, nextPhW, prevPhW, nextVowel, next2PhW
data = instn & 0xff;
instn2 = instn >> 8;
if(instn2 < 14)
{
which = (instn2) % 7;
if(which==4)
{
// nextPh not word boundary
if(plist[1].sourceix)
return(false);
}
if(which==5)
{
// prevPh, not word boundary
if(plist[0].sourceix)
return(false);
}
if(which==7)
{
// nextPh2 not word boundary
if((plist[1].sourceix) || (plist[2].sourceix))
return(false);
}
if(which==6)
{
// nextVowel, not word boundary
for(which=2;;which++)
{
if(plist[which-1].sourceix)
return(false);
if(phoneme_tab[plist[which-1].phcode]->type == phVOWEL)
break;
}
}
else
{
which = ph_position[which];
}
plist_this = plist;
plist = &plist[which-1];
if(which == 0)
{
if(plist->phcode == 1)
{
// This is a NULL phoneme, a phoneme has been deleted so look at the previous phoneme
plist = &plist[-1];
}
}
if(control & 0x100)
{
// change phonemes pass
plist->ph = phoneme_tab[plist->phcode];
}
ph = plist->ph;
if(instn2 < 7)
{
// 'data' is a phoneme number
if((phoneme_tab[data]->mnemonic == ph->mnemonic) == true)
return(true);
if((which == 0) && (ph->type == phVOWEL))
return(data == ph->end_type); // prevPh() match on end_type
return(data == ph->start_type); // thisPh() or nextPh(), match on start_type
}
data = instn & 0x1f;
switch(instn & 0xe0)
{
case 0x00:
// phoneme type, vowel, nasal, fricative, etc
return(ph->type == data);
break;
case 0x20:
// place of articulation
return(((ph->phflags >> 16) & 0xf) == data);
break;
case 0x40:
// is a bit set in phoneme flags
return((ph->phflags & (1 << data)) != 0);
break;
case 0x80:
switch(data)
{
case 0:
case 1:
case 2:
case 3:
case 4:
return(StressCondition(tr, plist, data, 0));
case 5: // isBreak, Either pause phoneme, or (stop/vstop/vfric not followed by vowel or (liquid in same word))
return((ph->type == phPAUSE) || (plist_this->synthflags & SFLAG_NEXT_PAUSE));
case 6: // isWordStart
return(plist->sourceix != 0);
case 7: // notWordStart
return(plist->sourceix == 0);
case 8: // isWordEnd
return(plist[1].sourceix || (plist[1].ph->type == phPAUSE));
break;
case 9: // isAfterStress
if(plist->sourceix != 0)
return(false);
do {
plist--;
if((plist->stresslevel & 0xf) >= 4)
return(true);
} while (plist->sourceix == 0);
break;
case 10: // isNotVowel
return(ph->type != phVOWEL);
case 11: // isFinalVowel
for(;;)
{
plist++;
plist->ph = phoneme_tab[plist->phcode];
if(plist->sourceix != 0)
return(true); // start of next word, without finding another vowel
if(plist->ph->type == phVOWEL)
return(false);
}
break;
case 12: // isVoiced
return((ph->type == phVOWEL) || (ph->type == phLIQUID) || (ph->phflags & phVOICED));
}
case 13: // isFirstVowel
count = 0;
for(;;)
{
if(plist->ph->type == phVOWEL)
count++;
if(plist->sourceix != 0)
break;
plist--;
}
return(count==1);
break;
}
return(false);
}
else
if(instn2 == 0xf)
{
// Other conditions
switch(data)
{
case 1: // PreVoicing
return(control & 1);
case 2: // KlattSynth
return(voice->klattv[0] != 0);
case 3: // MbrolaSynth
return(mbrola_name[0] != 0);
}
}
return(false);
} // end of InterpretCondition
static void SwitchVowelType(PHONEME_LIST *plist, PHONEME_DATA *phdata, USHORT **p_prog, int instn_type)
{//=====================================================================================================
USHORT *prog;
int voweltype;
signed char x;
if(instn_type == 2)
{
phdata->pd_control |= pd_FORNEXTPH;
voweltype = plist[1].ph->start_type; // SwitchNextVowelType
}
else
{
voweltype = plist[-1].ph->end_type; // SwitchPrevVowelType
}
voweltype -= phonVOWELTYPES;
if((voweltype >= 0) && (voweltype < 6))
{
prog = *p_prog + voweltype*2;
phdata->sound_addr[instn_type] = (((prog[1] & 0xf) << 16) + prog[2]) * 4;
x = (prog[1] >> 4) & 0xff;
phdata->sound_param[instn_type] = x; // sign extend
}
*p_prog += 12;
} // end of SwitchVowelType
static int NumInstnWords(USHORT *prog)
{//===================================
int instn;
int instn2;
int instn_type;
static char n_words[11] = {1,1,1,1,1,1,1,1,1,2,4};
instn = *prog;
instn_type = instn >> 12;
if(instn_type < 11)
return(n_words[instn_type]);
// 11 to 15, 2 words
instn2 = prog[2];
if((instn2 >> 12) == 0xf)
{
// addWav(), 2 more words
return(4);
}
if(instn2 == i_CONTINUE)
{
return(3);
}
return(2);
} // end of NumInstnWords
void InterpretPhoneme(Translator *tr, int control, PHONEME_LIST *plist, PHONEME_DATA *phdata)
{//==========================================================================================
// control:
//bit 0: PreVoicing
//bit 8: change phonemes
PHONEME_TAB *ph;
USHORT *prog;
USHORT instn;
int instn2;
int or_flag;
bool truth;
int data;
int end_flag;
int ix;
signed char param_sc;
#define N_RETURN 10
int n_return=0;
USHORT *return_addr[N_RETURN]; // return address stack
ph = plist->ph;
memset(phdata, 0, sizeof(PHONEME_DATA));
phdata->pd_param[i_SET_LENGTH] = ph->std_length;
phdata->pd_param[i_LENGTH_MOD] = ph->length_mod;
if(ph->program == 0)
return;
end_flag = 0;
for(prog = &phoneme_index[ph->program]; end_flag != 1; prog++)
{
instn = *prog;
instn2 = (instn >> 8) & 0xf;
or_flag = 0;
switch(instn >> 12)
{
case 0:
data = instn & 0xff;
if(instn2 == 0)
{
// instructions with no operand
switch(data)
{
case i_RETURN:
end_flag = 1;
break;
case i_CONTINUE:
break;
default:
InvalidInstn(ph,instn);
break;
}
}
else
if(instn2 == i_APPEND_IFNEXTVOWEL)
{
if(phoneme_tab[plist[1].phcode]->type == phVOWEL)
phdata->pd_param[i_APPEND_PHONEME] = data;
}
else
if(instn2 == i_IPA_NAME)
{
// followed by utf-8 characters, 2 per instn word
for(ix=0; (ix < data) && (ix < 16); ix += 2)
{
prog++;
phdata->ipa_string[ix] = prog[0] >> 8;
phdata->ipa_string[ix+1] = prog[0] & 0xff;
}
phdata->ipa_string[ix] = 0;
}
else
if(instn2 < N_PHONEME_DATA_PARAM)
{
if(instn2 == i_CHANGE_PHONEME2)
{
phdata->pd_param[i_CHANGE_PHONEME] = data; // also set ChangePhoneme
}
phdata->pd_param[instn2] = data;
if((instn2 == i_CHANGE_PHONEME) && (control & 0x100))
{
// found ChangePhoneme() in PhonemeList mode, exit
end_flag = 1;
}
}
else
{
InvalidInstn(ph,instn);
}
break;
case 1:
if(tr == NULL)
break; // ignore if in synthesis stage
if(instn2 < 8)
{
// ChangeIf
if(StressCondition(tr, plist, instn2 & 7, 1))
{
phdata->pd_param[i_CHANGE_PHONEME] = instn & 0xff;
end_flag = 1; // change phoneme, exit
}
}
break;
case 2:
case 3:
// conditions
or_flag = 0;
truth = true;
while((instn & 0xe000) == 0x2000)
{
// process a sequence of conditions, using boolean accumulator
if(or_flag)
truth = (truth || InterpretCondition(tr, control, plist, instn & 0xfff));
else
truth = (truth && InterpretCondition(tr, control, plist, instn & 0xfff));
or_flag = instn & 0x1000;
instn = *(++prog);
}
if(truth == false)
{
if((instn & 0xf800) == i_JUMP_FALSE)
{
prog += instn & 0xff;
}
else
{
// instruction after a condition is not JUMP_FALSE, so skip the instruction.
prog += NumInstnWords(prog);
if((prog[0] & 0xfe00) == 0x6000)
prog++; // and skip ELSE jump
}
}
prog--;
break;
case 6:
// JUMP
switch(instn2 >> 1)
{
case 0:
prog += (instn & 0xff) - 1;
break;
case 4:
// conditional jumps should have been processed in the Condition section
break;
case 5: // NexttVowelStarts
SwitchVowelType(plist, phdata, &prog, 2);
break;
case 6: // PrevVowelTypeEndings
SwitchVowelType(plist, phdata, &prog, 3);
break;
}
break;
case 9:
data = ((instn & 0xf) << 16) + prog[1];
prog++;
switch(instn2)
{
case 1:
// call a procedure or another phoneme
if(n_return < N_RETURN)
{
return_addr[n_return++] = prog;
prog = &phoneme_index[data] - 1;
}
break;
case 2:
// pitch envelope
phdata->pitch_env = data;
break;
case 3:
// amplitude envelope
phdata->amp_env = data;
break;
}
break;
case 10: // Vowelin, Vowelout
if(instn2 == 1)
ix = 0;
else
ix = 2;
phdata->vowel_transition[ix] = ((prog[0] & 0xff) << 16) + prog[1];
phdata->vowel_transition[ix+1] = (prog[2] << 16) + prog[3];
prog += 3;
break;
case 11: // FMT
case 12: // WAV
case 13: // VowelStart
case 14: // VowelEnd
case 15: // addWav
instn2 = (instn >> 12) - 11;
phdata->sound_addr[instn2] = ((instn & 0xf) << 18) + (prog[1] << 2);
param_sc = phdata->sound_param[instn2] = (instn >> 4) & 0xff;
prog++;
if(prog[1] != i_CONTINUE)
{
if(instn2 < 2)
{
// FMT() and WAV() imply Return
end_flag = 1;
if((prog[1] >> 12) == 0xf)
{
// Return after the following addWav()
end_flag = 2;
}
}
else
if(instn2 ==pd_ADDWAV)
{
// addWav(), return if previous instruction was FMT() or WAV()
end_flag--;
}
if((instn2 == pd_VWLSTART) || (instn2 == pd_VWLEND))
{
// VowelStart or VowelEnding.
phdata->sound_param[instn2] = param_sc; // sign extend
}
}
break;
default:
InvalidInstn(ph,instn);
break;
}
if(ph->phflags & phSINGLE_INSTN)
{
end_flag = 1; // this phoneme has a one-instruction program, with an implicit Return
}
if((end_flag == 1) && (n_return > 0))
{
// return from called procedure or phoneme
end_flag = 0;
prog = return_addr[--n_return];
}
}
} // end of InterpretPhoneme
void InterpretPhoneme2(int phcode, PHONEME_DATA *phdata)
{//=====================================================
// Examine the program of a single isolated phoneme
int ix;
PHONEME_LIST plist[4];
memset(plist, 0, sizeof(plist));
for(ix=0; ix<4; ix++)
{
plist[ix].phcode = phonPAUSE;
plist[ix].ph = phoneme_tab[phonPAUSE];
}
plist[1].phcode = phcode;
plist[1].ph = phoneme_tab[phcode];
plist[2].sourceix = 1;
InterpretPhoneme(NULL, 0, &plist[1], phdata);
} // end of InterpretPhoneme2
| [
"[email protected]"
] | |
87ebda654dd9c72aa970b46b33f354be34e94f71 | 2482a5977fed6a48f64ca31ae04f5b1e40f6dd9b | /src/XRP/Entry.cpp | b28a843c670d91155b9dfdd3a2da010380b31fbf | [
"MIT"
] | permissive | monacohq/wallet-core | 65c570a7b9bd15e18168cf5f5bffe4561ea305e3 | 3a2facbc78d3740ed5cde5d398e8462c8bd9786a | refs/heads/master | 2022-10-22T10:45:19.340415 | 2022-09-28T10:27:12 | 2022-09-28T10:27:12 | 227,562,081 | 4 | 2 | MIT | 2022-09-24T07:26:36 | 2019-12-12T08:55:20 | C++ | UTF-8 | C++ | false | false | 1,035 | cpp | // Copyright © 2017-2022 Trust Wallet.
//
// This file is part of Trust. The full Trust copyright notice, including
// terms governing use, modification, and redistribution, is contained in the
// file LICENSE at the root of the source code distribution tree.
#include "Entry.h"
#include "Address.h"
#include "XAddress.h"
#include "Signer.h"
namespace TW::Ripple {
// Note: avoid business logic from here, rather just call into classes like Address, Signer, etc.
bool Entry::validateAddress([[maybe_unused]] TWCoinType coin, const std::string& address, TW::byte, TW::byte, const char*) const {
return Address::isValid(address) || XAddress::isValid(address);
}
std::string Entry::deriveAddress([[maybe_unused]] TWCoinType coin, const PublicKey& publicKey, TW::byte, const char*) const {
return Address(publicKey).string();
}
void Entry::sign([[maybe_unused]] TWCoinType coin, const TW::Data& dataIn, TW::Data& dataOut) const {
signTemplate<Signer, Proto::SigningInput>(dataIn, dataOut);
}
} // namespace TW::Ripple
| [
"[email protected]"
] | |
1355874f6dbfb51b305de234d60a9bcaea3b9073 | c20c4812ac0164c8ec2434e1126c1fdb1a2cc09e | /Source/Source/Server/KG_AgentServer/PlugIn_GM/stdafx.cpp | 85c28166da5bce1def513ac90ac31b9cd2e7b9fe | [
"MIT"
] | permissive | uvbs/FullSource | f8673b02e10c8c749b9b88bf18018a69158e8cb9 | 07601c5f18d243fb478735b7bdcb8955598b9a90 | refs/heads/master | 2020-03-24T03:11:13.148940 | 2018-07-25T18:30:25 | 2018-07-25T18:30:25 | 142,408,505 | 2 | 2 | null | 2018-07-26T07:58:12 | 2018-07-26T07:58:12 | null | UTF-8 | C++ | false | false | 462 | cpp | ////////////////////////////////////////////////////////////////////////////////
//
// FileName : stdafx.cpp
// Version : 1.0
// Creator : tongxuehu, zoukewei
// Create Date : 01/16/2007
// Comment :
//
// Copyright (C) 2007 - All Rights Reserved
////////////////////////////////////////////////////////////////////////////////
#include "stdafx.h"
// TODO: reference any additional headers you need in STDAFX.H
// and not in this file
| [
"[email protected]"
] | |
74b54fc13d3e3474a960cf65a164316a0b27d2a7 | 30d6c69506fc0e0a5dc3d8e24df215873e3cacde | /Game.cpp | d737fef55a36084127777fd6dd008b8632cf6ac3 | [] | no_license | eden696/mtm | 4984ea82f03f3ebe426ae93fbbabae98808128e6 | b39d89530d7485a1a9b1a441c537dfa6437dd313 | refs/heads/master | 2023-07-29T05:17:52.758509 | 2021-09-12T19:35:35 | 2021-09-12T19:35:35 | 405,736,080 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 9,884 | cpp | #include "Game.h"
#define RANGE_DIVIDER 3
#define ATTACK_DIVIDER 3
namespace mtm
{
std::ostream& printGameBoard(std::ostream& os, const char* begin,
const char* end, unsigned int width) {
std::string delimiter = std::string(2 * width + 1, '*');
const char* temp = begin;
os << delimiter << std::endl;
while(temp != end) {
os << "|" << (*temp);
++temp;
if ((temp - begin) % width == 0)
os << "|" << std::endl;
}
os << delimiter;
delete[] begin;
return os;
}
int Game::getBoardHeight() const
{
return board_height;
}
int Game::getBoardWidth() const
{
return board_width;
}
// returns true if the coordinates are illegal
bool Game::checkIllegalCoordinates(const GridPoint& coordinates)
{
return (coordinates.row >= board_height ||
coordinates.col >= board_width ||
coordinates.row < 0 || coordinates.col < 0);
}
Game::Game(int height, int width)
{
if(height<=0 || width<=0){
throw IllegalArgument() ;
}
num_of_team1_players = num_of_team2_players = 0;
Dimensions dims(height, width);
board = new Matrix(dims);
board_height = height;
board_width = width;
}
Game::~Game()
{
delete[] board;
}
Game::Game(const Game& other)
{
Dimensions dims(other.board_height, other.board_width);
board = new Matrix(dims);
board_height = other.board_height;
board_width = other.board_width;
for(int i=0; i<other.board_height; i++){
for(int j=0; j<other.board_width; j++){
if((*other.board)(i,j)!=nullptr){
(*board)(i,j) = std::shared_ptr<Character>((*other.board)(i,j)->clone());
}
}
}
num_of_team2_players = other.num_of_team2_players;
num_of_team1_players = other.num_of_team1_players;
}
Game& Game::operator=(const Game& other)
{
if (this == &other){
return *this;
}
delete board;
board = other.board;
num_of_team2_players = other.num_of_team2_players;
num_of_team1_players = other.num_of_team1_players;
board_height = other.getBoardHeight();
board_width = other.getBoardWidth();
return (*this);
}
void Game::addCharacter(const GridPoint& coordinates, std::shared_ptr<Character> character)
{
if(checkIllegalCoordinates(coordinates)){
IllegalCell error;
throw error;
}
if ((*board)(coordinates.row ,coordinates.col) != nullptr){
CellOccupied error;
throw error;
}
((*board)(coordinates.row ,coordinates.col)) = (character);
}
std::shared_ptr<Character> Game::makeCharacter(CharacterType type, Team team, units_t health,
units_t ammo, units_t range, units_t power)
{
if(health<=0 || power<0 || ammo<0 || range<0){
IllegalArgument error;
throw error;
}
switch (type) {
case SOLDIER: {
std::shared_ptr<Character> character(new Soldier(team, health, ammo, range, power));
return character;
}
case SNIPER: {
std::shared_ptr<Character> character(new Sniper(team, health, ammo, range, power));
return character;
}
case MEDIC: {
std::shared_ptr<Character> character(new Medic(team, health, ammo, range, power));
return character;
}
default: {
std::shared_ptr<Character> character = nullptr;
return character;
}
}
}
void Game::move(const GridPoint& src_coordinates, const GridPoint& dst_coordinates)
{
if(checkIllegalCoordinates(src_coordinates) || checkIllegalCoordinates(dst_coordinates)) {
IllegalCell error;
throw error;
}
if ((*board)(src_coordinates.row ,src_coordinates.col) == nullptr) {
CellEmpty error;
throw error;
}
if (!(*board)(src_coordinates.row ,src_coordinates.col)->canMove(src_coordinates, dst_coordinates)) {
MoveTooFar error;
throw error;
}
if ((*board)(dst_coordinates.row ,dst_coordinates.col) != nullptr) {
CellOccupied error;
throw error;
}
(*board)(dst_coordinates.row ,dst_coordinates.col) = (*board)(src_coordinates.row ,src_coordinates.col);
(*board)(src_coordinates.row ,src_coordinates.col) = nullptr;
}
void Game::attack(const GridPoint& src_coordinates, const GridPoint& dst_coordinates)
{
std::shared_ptr<Character> attacker((*board)(src_coordinates.row, src_coordinates.col));
std::shared_ptr<Character> target((*board)(dst_coordinates.row, dst_coordinates.col));
if(!inBounds(src_coordinates, dst_coordinates)){
IllegalCell error;
throw error;
}
if(attacker==nullptr){
CellEmpty error;
throw error;
}
bool legal = false;
try {
legal = attacker->legalAttack(src_coordinates, dst_coordinates, target);
}
catch (OutOfRange& e){
throw e;
}
catch (IllegalTarget& e){
throw e;
}
if (attacker->ammo() <= 0 ){
OutOfAmmo error;
throw error;
}
if(legal){
if(target != nullptr){
target->health(attacker->attackCharacter(src_coordinates, dst_coordinates, target->team()));
}
if(target == nullptr && attacker->type() == SOLDIER){
attacker->removeOneAmmo();
}
doCollateralDamage(src_coordinates, dst_coordinates);
}
for(int i=0; i<board_height; i++) {
for (int j = 0; j < board_width; j++) {
if((*board)(i,j)!=nullptr){
if((*board)(i,j)->health() <= 0){
(*board)(i,j) = nullptr;
}
}
}
}
}
void Game::doCollateralDamage (const GridPoint& location, const GridPoint& target)
{
for(int i=0; i<board_height; i++) {
for (int j = 0; j < board_width; j++) {
GridPoint cell = GridPoint(i, j);
if((*board)(i,j)!=nullptr && (*board)(i,j)->team()!=(*board)(location.row, location.col)->team()){
int damage = (*board)(location.row, location.col)->adjacentDamage(GridPoint::distance(cell, target));
(*board)(i,j)->health(damage);
}
}
}
}
bool Game::inBounds(const GridPoint& point1, const GridPoint& point2)
{
if(point1.row<0 || point1.col<0 || point2.row<0 || point2.col<0){
return false;
}
if(point1.row>=board_height||point1.col>=board_width){
return false;
}
return !(point2.row >= board_height || point2.col >= board_width);
}
void Game::reload(const GridPoint& coordinates)
{
if(checkIllegalCoordinates(coordinates)) {
IllegalCell error;
throw error;
}
if ((*board)(coordinates.row, coordinates.col) == nullptr) {
CellEmpty error;
throw error;
}
(*board)(coordinates.row, coordinates.col)->load();
}
std::ostream& operator<<(std::ostream &os, Game& game)
{
Team current_team;
CharacterType current_character_type;
char* ptr_matrix = new char[game.getBoardWidth() * game.getBoardHeight()];
for(int i=0; i<game.getBoardHeight(); i++){
for(int j=0; j<game.getBoardWidth(); j++){
if ((*game.board)(i,j) != nullptr){
current_team = (*game.board)(i,j)->team();
current_character_type = (*game.board)(i,j)->type();
switch (current_character_type){
case SOLDIER: {
ptr_matrix[(i*game.getBoardWidth()) +j] = (current_team == CPP)? 'S' : 's';
break;
}
case SNIPER: {
ptr_matrix[(i*game.getBoardWidth()) +j] = (current_team == CPP)? 'N' : 'n';
break;
}
case MEDIC: {
ptr_matrix[(i*game.getBoardWidth()) +j] = (current_team == CPP)? 'M' : 'm';
break;
}
}
}
else{
ptr_matrix[(i*game.getBoardWidth()) +j] = ' ';
}
}
}
return printGameBoard(os, ptr_matrix, ptr_matrix + game.getBoardWidth()* game.getBoardHeight(), game.getBoardWidth());
}
bool Game::isOver(Team* winningTeam) const
{
int cpp_counter = 0, python_counter = 0;
for(int i=0; i<board_height; i++)
{
for(int j=0; j<board_width; j++) {
if ((*board)(i, j) != nullptr) {
((*board)(i, j)->team() == CPP) ? cpp_counter++ : python_counter++;
}
}
}
if (cpp_counter == 0 && python_counter != 0){
*winningTeam = PYTHON;
return true;
}
if (cpp_counter != 0 && python_counter == 0){
*winningTeam = CPP;
return true;
}
return false;
}
}
| [
"[email protected]"
] | |
55da59c98e09c9f7af0a4d3f717316f77d359a7a | 019119e06e765466fb496f03692858d9cdf6ab4f | /_oe-sdk-20071004091648/usr/local/arm/oe/arm-linux/include/mozilla-minimo/widget/nsIClipboardDragDropHookList.h | 37b11bc6a15301c0572201fefc2568c8b58c53b8 | [] | no_license | josuehenrique/iliad-hacking | 44b2a5cda34511f8976fc4a4c2740edb5afa5312 | 49cfd0a8f989491a6cc33cf64e8542f695d2e280 | refs/heads/master | 2020-04-06T06:40:50.174479 | 2009-08-23T16:56:01 | 2009-08-23T16:56:01 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 5,094 | h | /*
* DO NOT EDIT. THIS FILE IS GENERATED FROM /data/workareas/matthijs/svn/openembedded/build/tmp/work/minimo-0.0cvs20051025-r9/mozilla/widget/public/nsIClipboardDragDropHookList.idl
*/
#ifndef __gen_nsIClipboardDragDropHookList_h__
#define __gen_nsIClipboardDragDropHookList_h__
#ifndef __gen_nsISupports_h__
#include "nsISupports.h"
#endif
/* For IDL files that don't want to include root IDL files. */
#ifndef NS_NO_VTABLE
#define NS_NO_VTABLE
#endif
class nsIClipboardDragDropHooks; /* forward declaration */
class nsISimpleEnumerator; /* forward declaration */
/* starting interface: nsIClipboardDragDropHookList */
#define NS_ICLIPBOARDDRAGDROPHOOKLIST_IID_STR "876a2015-6b66-11d7-8f18-0003938a9d96"
#define NS_ICLIPBOARDDRAGDROPHOOKLIST_IID \
{0x876a2015, 0x6b66, 0x11d7, \
{ 0x8f, 0x18, 0x00, 0x03, 0x93, 0x8a, 0x9d, 0x96 }}
/**
* Please note that the following api is not intended for embedders;
* it is intended as an internal (to gecko). Embedders can indirectly
* call these by sending commands (see description in
* nsIClipboardDragDropHooks.idl).
*
* Internal gecko usage is accomplished by calling get_Interface on a
* docshell.
*/
class NS_NO_VTABLE nsIClipboardDragDropHookList : public nsISupports {
public:
NS_DEFINE_STATIC_IID_ACCESSOR(NS_ICLIPBOARDDRAGDROPHOOKLIST_IID)
/**
* Add a hook to list.
* @param aHooks implementation of hooks
*/
/* void addClipboardDragDropHooks (in nsIClipboardDragDropHooks aHooks); */
NS_IMETHOD AddClipboardDragDropHooks(nsIClipboardDragDropHooks *aHooks) = 0;
/**
* Remove a hook from list (note if this implementation is not present
* in the list then removal will be ignored).
* @param aHooks implementation of hooks
*/
/* void removeClipboardDragDropHooks (in nsIClipboardDragDropHooks aHooks); */
NS_IMETHOD RemoveClipboardDragDropHooks(nsIClipboardDragDropHooks *aHooks) = 0;
/**
* Gets an enumerator for all hooks which have been added.
* @return nsISimpleEnumerator for nsIClipboardDragDropHooks
*/
/* nsISimpleEnumerator getHookEnumerator (); */
NS_IMETHOD GetHookEnumerator(nsISimpleEnumerator **_retval) = 0;
};
/* Use this macro when declaring classes that implement this interface. */
#define NS_DECL_NSICLIPBOARDDRAGDROPHOOKLIST \
NS_IMETHOD AddClipboardDragDropHooks(nsIClipboardDragDropHooks *aHooks); \
NS_IMETHOD RemoveClipboardDragDropHooks(nsIClipboardDragDropHooks *aHooks); \
NS_IMETHOD GetHookEnumerator(nsISimpleEnumerator **_retval);
/* Use this macro to declare functions that forward the behavior of this interface to another object. */
#define NS_FORWARD_NSICLIPBOARDDRAGDROPHOOKLIST(_to) \
NS_IMETHOD AddClipboardDragDropHooks(nsIClipboardDragDropHooks *aHooks) { return _to AddClipboardDragDropHooks(aHooks); } \
NS_IMETHOD RemoveClipboardDragDropHooks(nsIClipboardDragDropHooks *aHooks) { return _to RemoveClipboardDragDropHooks(aHooks); } \
NS_IMETHOD GetHookEnumerator(nsISimpleEnumerator **_retval) { return _to GetHookEnumerator(_retval); }
/* Use this macro to declare functions that forward the behavior of this interface to another object in a safe way. */
#define NS_FORWARD_SAFE_NSICLIPBOARDDRAGDROPHOOKLIST(_to) \
NS_IMETHOD AddClipboardDragDropHooks(nsIClipboardDragDropHooks *aHooks) { return !_to ? NS_ERROR_NULL_POINTER : _to->AddClipboardDragDropHooks(aHooks); } \
NS_IMETHOD RemoveClipboardDragDropHooks(nsIClipboardDragDropHooks *aHooks) { return !_to ? NS_ERROR_NULL_POINTER : _to->RemoveClipboardDragDropHooks(aHooks); } \
NS_IMETHOD GetHookEnumerator(nsISimpleEnumerator **_retval) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetHookEnumerator(_retval); }
#if 0
/* Use the code below as a template for the implementation class for this interface. */
/* Header file */
class nsClipboardDragDropHookList : public nsIClipboardDragDropHookList
{
public:
NS_DECL_ISUPPORTS
NS_DECL_NSICLIPBOARDDRAGDROPHOOKLIST
nsClipboardDragDropHookList();
private:
~nsClipboardDragDropHookList();
protected:
/* additional members */
};
/* Implementation file */
NS_IMPL_ISUPPORTS1(nsClipboardDragDropHookList, nsIClipboardDragDropHookList)
nsClipboardDragDropHookList::nsClipboardDragDropHookList()
{
/* member initializers and constructor code */
}
nsClipboardDragDropHookList::~nsClipboardDragDropHookList()
{
/* destructor code */
}
/* void addClipboardDragDropHooks (in nsIClipboardDragDropHooks aHooks); */
NS_IMETHODIMP nsClipboardDragDropHookList::AddClipboardDragDropHooks(nsIClipboardDragDropHooks *aHooks)
{
return NS_ERROR_NOT_IMPLEMENTED;
}
/* void removeClipboardDragDropHooks (in nsIClipboardDragDropHooks aHooks); */
NS_IMETHODIMP nsClipboardDragDropHookList::RemoveClipboardDragDropHooks(nsIClipboardDragDropHooks *aHooks)
{
return NS_ERROR_NOT_IMPLEMENTED;
}
/* nsISimpleEnumerator getHookEnumerator (); */
NS_IMETHODIMP nsClipboardDragDropHookList::GetHookEnumerator(nsISimpleEnumerator **_retval)
{
return NS_ERROR_NOT_IMPLEMENTED;
}
/* End of implementation class template. */
#endif
#endif /* __gen_nsIClipboardDragDropHookList_h__ */
| [
"[email protected]"
] | |
de42dd89f64254f99eef67b64a5b2fe380ca0942 | 097df0a03ead79f6b2880872e33fd6cf04694867 | /PhoneBook/PersonsTable.h | a62540b9d0351203a7b8c0cfe521e561f8825e29 | [] | no_license | KrastevST/Phone-Book | e6f56848abc81c75e31561bd27e074368cd84ed6 | c847b4c336b4a1e56be2590a2686d0600bd4a670 | refs/heads/master | 2021-01-15T00:15:03.287870 | 2020-08-25T16:32:33 | 2020-08-25T16:32:33 | 242,807,997 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 483 | h | #pragma once
#include "Structures.h"
#include "PersonsAccessor.h"
#include "TemplateTable.h"
#include "PersonWithPhoneNums.h"
/////////////////////////////////////////////////////////////////////////////
// CPersonsTable
class CPersonsTable : public CTemplateTable<PERSONS, CPersonsAccessor>
{
// Constructor / Destructor
//---------------------
public:
CPersonsTable();
virtual ~CPersonsTable();
// Overrides
//---------------------
private:
PERSONS& GetRecord() override;
}; | [
"[email protected]"
] | |
f92aa464b1e211dc49432b4c0c928996abefaf36 | 666dfdb18d5455d0ed505d8e9895e198c5807abc | /src/AttributeIndex.hpp | f34d9e22139da5ed787e4beedc877db719d3d467 | [] | no_license | James-Z/fulcrum | 0e4a61d793e5822d91c7be29805ca50199e6e5a6 | 900b8fe367af08da97512666ede4fa7d12cee9c7 | refs/heads/master | 2020-05-16T22:01:43.963711 | 2014-12-14T09:54:40 | 2014-12-14T09:54:40 | 23,421,771 | 1 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 272 | hpp | #pragma once
enum SHADER_ATTRIBUTE { ATTRIBUTE_INDEX_VERTEX= 0,
ATTRIBUTE_INDEX_COLOR,
ATTRIBUTE_INDEX_NORMAL,
ATTRIBUTE_INDEX_TEXTURE0,
ATTRIBUTE_INDEX_TEXTURE1,
ATTRIBUTE_INDEX_TEXTURE2,
ATTRIBUTE_INDEX_TEXTURE3,
ATTRIBUTE_INDEX_LAST
};
| [
"[email protected]"
] | |
ce5dc6cd5da88d4131d727d8fde5d3d2696d25c7 | 91934b8ad2f42f29c445d511c6dd273b7e35ed86 | /juce/extras/Jucer (experimental)/Source/Project/jucer_ProjectExport_Make.h | 27ddffbe9cf154e99e1f4d4a51871254f13a259b | [] | no_license | fubyo/osccalibrator | 882d348ecf738a11f9bfddf3511693a69d6c1d9e | 9c3652957c2ddc3d2a550f80be1cdb5e6707b8ce | refs/heads/master | 2021-01-10T21:04:00.712697 | 2015-03-16T12:45:03 | 2015-03-16T12:45:03 | 32,316,417 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 13,396 | h | /*
==============================================================================
This file is part of the JUCE library - "Jules' Utility Class Extensions"
Copyright 2004-10 by Raw Material Software Ltd.
------------------------------------------------------------------------------
JUCE can be redistributed and/or modified under the terms of the GNU General
Public License (Version 2), as published by the Free Software Foundation.
A copy of the license is included in the JUCE distribution, or can be found
online at www.gnu.org/licenses.
JUCE 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 JUCE, commercial licenses are
available: visit www.rawmaterialsoftware.com/juce for more information.
==============================================================================
*/
#ifndef __JUCER_PROJECTEXPORT_MAKE_JUCEHEADER__
#define __JUCER_PROJECTEXPORT_MAKE_JUCEHEADER__
#include "jucer_ProjectExporter.h"
//==============================================================================
class MakefileProjectExporter : public ProjectExporter
{
public:
//==============================================================================
static const char* getNameLinux() { return "Linux Makefile"; }
static const char* getValueTreeTypeName() { return "LINUX_MAKE"; }
static MakefileProjectExporter* createForSettings (Project& project, const ValueTree& settings)
{
if (settings.hasType (getValueTreeTypeName()))
return new MakefileProjectExporter (project, settings);
return 0;
}
//==============================================================================
MakefileProjectExporter (Project& project_, const ValueTree& settings_)
: ProjectExporter (project_, settings_)
{
name = getNameLinux();
if (getTargetLocation().toString().isEmpty())
getTargetLocation() = getDefaultBuildsRootFolder() + "Linux";
if (getVSTFolder().toString().isEmpty())
getVSTFolder() = "~/SDKs/vstsdk2.4";
}
~MakefileProjectExporter()
{
}
//==============================================================================
bool isDefaultFormatForCurrentOS()
{
#if JUCE_LINUX
return true;
#else
return false;
#endif
}
bool isPossibleForCurrentProject() { return true; }
bool usesMMFiles() const { return false; }
void launchProject()
{
// what to do on linux?
}
void createPropertyEditors (Array <PropertyComponent*>& props)
{
ProjectExporter::createPropertyEditors (props);
}
//==============================================================================
const String create()
{
Array<RelativePath> files;
findAllFilesToCompile (project.getMainGroup(), files);
for (int i = 0; i < juceWrapperFiles.size(); ++i)
if (shouldFileBeCompiledByDefault (juceWrapperFiles.getReference(i)))
files.add (juceWrapperFiles.getReference(i));
const Array<RelativePath> vstFiles (getVSTFilesRequired());
for (int i = 0; i < vstFiles.size(); i++)
files.add (vstFiles.getReference(i));
MemoryOutputStream mo;
writeMakefile (mo, files);
const File makefile (getTargetFolder().getChildFile ("Makefile"));
if (! FileHelpers::overwriteFileWithNewDataIfDifferent (makefile, mo))
return "Can't write to the Makefile: " + makefile.getFullPathName();
return String::empty;
}
private:
//==============================================================================
void findAllFilesToCompile (const Project::Item& projectItem, Array<RelativePath>& results)
{
if (projectItem.isGroup())
{
for (int i = 0; i < projectItem.getNumChildren(); ++i)
findAllFilesToCompile (projectItem.getChild(i), results);
}
else
{
if (projectItem.shouldBeCompiled())
results.add (RelativePath (projectItem.getFile(), getTargetFolder(), RelativePath::buildTargetFolder));
}
}
void writeDefineFlags (OutputStream& out, const Project::BuildConfiguration& config)
{
StringPairArray defines;
defines.set ("LINUX", "1");
if (config.isDebug().getValue())
{
defines.set ("DEBUG", "1");
defines.set ("_DEBUG", "1");
}
else
{
defines.set ("NDEBUG", "1");
}
defines = mergePreprocessorDefs (defines, getAllPreprocessorDefs (config));
for (int i = 0; i < defines.size(); ++i)
{
String def (defines.getAllKeys()[i]);
const String value (defines.getAllValues()[i]);
if (value.isNotEmpty())
def << "=" << value;
out << " -D " << def.quoted();
}
}
void writeHeaderPathFlags (OutputStream& out, const Project::BuildConfiguration& config)
{
StringArray headerPaths (config.getHeaderSearchPaths());
headerPaths.insert (0, "/usr/include/freetype2");
headerPaths.insert (0, "/usr/include");
if (project.shouldAddVSTFolderToPath() && getVSTFolder().toString().isNotEmpty())
headerPaths.insert (0, rebaseFromProjectFolderToBuildTarget (RelativePath (getVSTFolder().toString(), RelativePath::projectFolder)).toUnixStyle());
if (isVST())
headerPaths.insert (0, juceWrapperFolder.toUnixStyle());
for (int i = 0; i < headerPaths.size(); ++i)
out << " -I " << FileHelpers::unixStylePath (replacePreprocessorTokens (config, headerPaths[i])).quoted();
}
void writeCppFlags (OutputStream& out, const Project::BuildConfiguration& config)
{
out << " CPPFLAGS := $(DEPFLAGS)";
writeDefineFlags (out, config);
writeHeaderPathFlags (out, config);
out << newLine;
}
void writeLinkerFlags (OutputStream& out, const Project::BuildConfiguration& config)
{
out << " LDFLAGS += -L$(BINDIR) -L$(LIBDIR)";
if (project.isAudioPlugin())
out << " -shared";
{
Array<RelativePath> libraryPaths;
libraryPaths.add (RelativePath ("/usr/X11R6/lib/", RelativePath::unknown));
libraryPaths.add (getJucePathFromTargetFolder().getChildFile ("bin"));
for (int i = 0; i < libraryPaths.size(); ++i)
out << " -L" << libraryPaths.getReference(i).toUnixStyle().quoted();
}
const char* defaultLibs[] = { "freetype", "pthread", "rt", "X11", "GL", "GLU", "Xinerama", "asound", 0 };
StringArray libs (defaultLibs);
if (project.getJuceLinkageMode() == Project::useLinkedJuce)
libs.add ("juce");
for (int i = 0; i < libs.size(); ++i)
out << " -l" << libs[i];
out << " " << replacePreprocessorTokens (config, getExtraLinkerFlags().toString()).trim()
<< newLine;
}
void writeConfig (OutputStream& out, const Project::BuildConfiguration& config)
{
const String buildDirName ("build");
const String intermediatesDirName (buildDirName + "/intermediate/" + config.getName().toString());
String outputDir (buildDirName);
if (config.getTargetBinaryRelativePath().toString().isNotEmpty())
{
RelativePath binaryPath (config.getTargetBinaryRelativePath().toString(), RelativePath::projectFolder);
outputDir = binaryPath.rebased (project.getFile().getParentDirectory(), getTargetFolder(), RelativePath::buildTargetFolder).toUnixStyle();
}
out << "ifeq ($(CONFIG)," << escapeSpaces (config.getName().toString()) << ")" << newLine;
out << " BINDIR := " << escapeSpaces (buildDirName) << newLine
<< " LIBDIR := " << escapeSpaces (buildDirName) << newLine
<< " OBJDIR := " << escapeSpaces (intermediatesDirName) << newLine
<< " OUTDIR := " << escapeSpaces (outputDir) << newLine;
writeCppFlags (out, config);
out << " CFLAGS += $(CPPFLAGS) $(TARGET_ARCH)";
if (config.isDebug().getValue())
out << " -g -ggdb";
if (project.isAudioPlugin())
out << " -fPIC";
out << " -O" << config.getGCCOptimisationFlag() << newLine;
out << " CXXFLAGS += $(CFLAGS) " << replacePreprocessorTokens (config, getExtraCompilerFlags().toString()).trim() << newLine;
writeLinkerFlags (out, config);
out << " LDDEPS :=" << newLine
<< " RESFLAGS := ";
writeDefineFlags (out, config);
writeHeaderPathFlags (out, config);
out << newLine;
String targetName (config.getTargetBinaryName().getValue().toString());
if (project.isLibrary())
targetName = getLibbedFilename (targetName);
else if (isVST())
targetName = targetName.upToLastOccurrenceOf (".", false, false) + ".so";
out << " TARGET := " << escapeSpaces (targetName) << newLine;
if (project.isLibrary())
out << " BLDCMD = ar -rcs $(OUTDIR)/$(TARGET) $(OBJECTS) $(TARGET_ARCH)" << newLine;
else
out << " BLDCMD = $(CXX) -o $(OUTDIR)/$(TARGET) $(OBJECTS) $(LDFLAGS) $(RESOURCES) $(TARGET_ARCH)" << newLine;
out << "endif" << newLine << newLine;
}
void writeObjects (OutputStream& out, const Array<RelativePath>& files)
{
out << "OBJECTS := \\" << newLine;
for (int i = 0; i < files.size(); ++i)
if (shouldFileBeCompiledByDefault (files.getReference(i)))
out << " $(OBJDIR)/" << escapeSpaces (getObjectFileFor (files.getReference(i))) << " \\" << newLine;
out << newLine;
}
void writeMakefile (OutputStream& out, const Array<RelativePath>& files)
{
out << "# Automatically generated makefile, created by the Jucer" << newLine
<< "# Don't edit this file! Your changes will be overwritten when you re-save the Jucer project!" << newLine
<< newLine;
out << "ifndef CONFIG" << newLine
<< " CONFIG=" << escapeSpaces (project.getConfiguration(0).getName().toString()) << newLine
<< "endif" << newLine
<< newLine;
if (! project.isLibrary())
out << "ifeq ($(TARGET_ARCH),)" << newLine
<< " TARGET_ARCH := -march=native" << newLine
<< "endif" << newLine << newLine;
out << "# (this disables dependency generation if multiple architectures are set)" << newLine
<< "DEPFLAGS := $(if $(word 2, $(TARGET_ARCH)), , -MMD)" << newLine
<< newLine;
int i;
for (i = 0; i < project.getNumConfigurations(); ++i)
writeConfig (out, project.getConfiguration(i));
writeObjects (out, files);
out << ".PHONY: clean" << newLine
<< newLine;
out << "$(OUTDIR)/$(TARGET): $(OBJECTS) $(LDDEPS) $(RESOURCES)" << newLine
<< "\t@echo Linking " << project.getProjectName() << newLine
<< "\t-@mkdir -p $(BINDIR)" << newLine
<< "\t-@mkdir -p $(LIBDIR)" << newLine
<< "\t-@mkdir -p $(OUTDIR)" << newLine
<< "\t@$(BLDCMD)" << newLine
<< newLine;
out << "clean:" << newLine
<< "\t@echo Cleaning " << project.getProjectName() << newLine
<< "\t-@rm -f $(OUTDIR)/$(TARGET)" << newLine
<< "\t-@rm -rf $(OBJDIR)/*" << newLine
<< "\t-@rm -rf $(OBJDIR)" << newLine
<< newLine;
for (i = 0; i < files.size(); ++i)
{
if (shouldFileBeCompiledByDefault (files.getReference(i)))
{
jassert (files.getReference(i).getRoot() == RelativePath::buildTargetFolder);
out << "$(OBJDIR)/" << escapeSpaces (getObjectFileFor (files.getReference(i)))
<< ": " << escapeSpaces (files.getReference(i).toUnixStyle()) << newLine
<< "\t-@mkdir -p $(OBJDIR)" << newLine
<< "\t@echo \"Compiling " << files.getReference(i).getFileName() << "\"" << newLine
<< (files.getReference(i).hasFileExtension (".c") ? "\t@$(CC) $(CFLAGS) -o \"$@\" -c \"$<\""
: "\t@$(CXX) $(CXXFLAGS) -o \"$@\" -c \"$<\"")
<< newLine << newLine;
}
}
out << "-include $(OBJECTS:%.o=%.d)" << newLine;
}
static const String escapeSpaces (const String& s)
{
return s.replace (" ", "\\ ");
}
const String getObjectFileFor (const RelativePath& file) const
{
return file.getFileNameWithoutExtension()
+ "_" + String::toHexString (file.toUnixStyle().hashCode()) + ".o";
}
JUCE_DECLARE_NON_COPYABLE (MakefileProjectExporter);
};
#endif // __JUCER_PROJECTEXPORT_MAKE_JUCEHEADER__
| [
"[email protected]"
] | |
996cb48127db21625a0694d6b23badc276e4891d | ae219d28725c9dd58c200ae76ba3bf3f2a90d557 | /BrowserLauncher/xulrunner-sdk/include/nsIDOMHTMLStyleElement.h | bc96a2f12671f2871ae94ff9182096e6f7251055 | [] | no_license | pepekinha/src | de1f0c64cf1238e019f4daf7f87d95849304d88e | 5223858f05f6791f1dec30df1dbb91ae3e4f5952 | refs/heads/master | 2021-01-22T01:05:54.659896 | 2014-04-06T01:43:37 | 2014-04-06T01:43:37 | 27,421,524 | 3 | 2 | null | null | null | null | UTF-8 | C++ | false | false | 5,252 | h | /*
* DO NOT EDIT. THIS FILE IS GENERATED FROM e:/builds/moz2_slave/release-mozilla-1.9.2-xulrunner_win32_build/build/dom/interfaces/html/nsIDOMHTMLStyleElement.idl
*/
#ifndef __gen_nsIDOMHTMLStyleElement_h__
#define __gen_nsIDOMHTMLStyleElement_h__
#ifndef __gen_nsIDOMHTMLElement_h__
#include "nsIDOMHTMLElement.h"
#endif
/* For IDL files that don't want to include root IDL files. */
#ifndef NS_NO_VTABLE
#define NS_NO_VTABLE
#endif
/* starting interface: nsIDOMHTMLStyleElement */
#define NS_IDOMHTMLSTYLEELEMENT_IID_STR "a6cf908d-15b3-11d2-932e-00805f8add32"
#define NS_IDOMHTMLSTYLEELEMENT_IID \
{0xa6cf908d, 0x15b3, 0x11d2, \
{ 0x93, 0x2e, 0x00, 0x80, 0x5f, 0x8a, 0xdd, 0x32 }}
/**
* The nsIDOMHTMLStyleElement interface is the interface to a [X]HTML
* style element.
*
* For more information on this interface please see
* http://www.w3.org/TR/DOM-Level-2-HTML/
*
* @status FROZEN
*/
class NS_NO_VTABLE NS_SCRIPTABLE nsIDOMHTMLStyleElement : public nsIDOMHTMLElement {
public:
NS_DECLARE_STATIC_IID_ACCESSOR(NS_IDOMHTMLSTYLEELEMENT_IID)
/* attribute boolean disabled; */
NS_SCRIPTABLE NS_IMETHOD GetDisabled(PRBool *aDisabled) = 0;
NS_SCRIPTABLE NS_IMETHOD SetDisabled(PRBool aDisabled) = 0;
/* attribute DOMString media; */
NS_SCRIPTABLE NS_IMETHOD GetMedia(nsAString & aMedia) = 0;
NS_SCRIPTABLE NS_IMETHOD SetMedia(const nsAString & aMedia) = 0;
/* attribute DOMString type; */
NS_SCRIPTABLE NS_IMETHOD GetType(nsAString & aType) = 0;
NS_SCRIPTABLE NS_IMETHOD SetType(const nsAString & aType) = 0;
};
NS_DEFINE_STATIC_IID_ACCESSOR(nsIDOMHTMLStyleElement, NS_IDOMHTMLSTYLEELEMENT_IID)
/* Use this macro when declaring classes that implement this interface. */
#define NS_DECL_NSIDOMHTMLSTYLEELEMENT \
NS_SCRIPTABLE NS_IMETHOD GetDisabled(PRBool *aDisabled); \
NS_SCRIPTABLE NS_IMETHOD SetDisabled(PRBool aDisabled); \
NS_SCRIPTABLE NS_IMETHOD GetMedia(nsAString & aMedia); \
NS_SCRIPTABLE NS_IMETHOD SetMedia(const nsAString & aMedia); \
NS_SCRIPTABLE NS_IMETHOD GetType(nsAString & aType); \
NS_SCRIPTABLE NS_IMETHOD SetType(const nsAString & aType);
/* Use this macro to declare functions that forward the behavior of this interface to another object. */
#define NS_FORWARD_NSIDOMHTMLSTYLEELEMENT(_to) \
NS_SCRIPTABLE NS_IMETHOD GetDisabled(PRBool *aDisabled) { return _to GetDisabled(aDisabled); } \
NS_SCRIPTABLE NS_IMETHOD SetDisabled(PRBool aDisabled) { return _to SetDisabled(aDisabled); } \
NS_SCRIPTABLE NS_IMETHOD GetMedia(nsAString & aMedia) { return _to GetMedia(aMedia); } \
NS_SCRIPTABLE NS_IMETHOD SetMedia(const nsAString & aMedia) { return _to SetMedia(aMedia); } \
NS_SCRIPTABLE NS_IMETHOD GetType(nsAString & aType) { return _to GetType(aType); } \
NS_SCRIPTABLE NS_IMETHOD SetType(const nsAString & aType) { return _to SetType(aType); }
/* Use this macro to declare functions that forward the behavior of this interface to another object in a safe way. */
#define NS_FORWARD_SAFE_NSIDOMHTMLSTYLEELEMENT(_to) \
NS_SCRIPTABLE NS_IMETHOD GetDisabled(PRBool *aDisabled) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetDisabled(aDisabled); } \
NS_SCRIPTABLE NS_IMETHOD SetDisabled(PRBool aDisabled) { return !_to ? NS_ERROR_NULL_POINTER : _to->SetDisabled(aDisabled); } \
NS_SCRIPTABLE NS_IMETHOD GetMedia(nsAString & aMedia) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetMedia(aMedia); } \
NS_SCRIPTABLE NS_IMETHOD SetMedia(const nsAString & aMedia) { return !_to ? NS_ERROR_NULL_POINTER : _to->SetMedia(aMedia); } \
NS_SCRIPTABLE NS_IMETHOD GetType(nsAString & aType) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetType(aType); } \
NS_SCRIPTABLE NS_IMETHOD SetType(const nsAString & aType) { return !_to ? NS_ERROR_NULL_POINTER : _to->SetType(aType); }
#if 0
/* Use the code below as a template for the implementation class for this interface. */
/* Header file */
class nsDOMHTMLStyleElement : public nsIDOMHTMLStyleElement
{
public:
NS_DECL_ISUPPORTS
NS_DECL_NSIDOMHTMLSTYLEELEMENT
nsDOMHTMLStyleElement();
private:
~nsDOMHTMLStyleElement();
protected:
/* additional members */
};
/* Implementation file */
NS_IMPL_ISUPPORTS1(nsDOMHTMLStyleElement, nsIDOMHTMLStyleElement)
nsDOMHTMLStyleElement::nsDOMHTMLStyleElement()
{
/* member initializers and constructor code */
}
nsDOMHTMLStyleElement::~nsDOMHTMLStyleElement()
{
/* destructor code */
}
/* attribute boolean disabled; */
NS_IMETHODIMP nsDOMHTMLStyleElement::GetDisabled(PRBool *aDisabled)
{
return NS_ERROR_NOT_IMPLEMENTED;
}
NS_IMETHODIMP nsDOMHTMLStyleElement::SetDisabled(PRBool aDisabled)
{
return NS_ERROR_NOT_IMPLEMENTED;
}
/* attribute DOMString media; */
NS_IMETHODIMP nsDOMHTMLStyleElement::GetMedia(nsAString & aMedia)
{
return NS_ERROR_NOT_IMPLEMENTED;
}
NS_IMETHODIMP nsDOMHTMLStyleElement::SetMedia(const nsAString & aMedia)
{
return NS_ERROR_NOT_IMPLEMENTED;
}
/* attribute DOMString type; */
NS_IMETHODIMP nsDOMHTMLStyleElement::GetType(nsAString & aType)
{
return NS_ERROR_NOT_IMPLEMENTED;
}
NS_IMETHODIMP nsDOMHTMLStyleElement::SetType(const nsAString & aType)
{
return NS_ERROR_NOT_IMPLEMENTED;
}
/* End of implementation class template. */
#endif
#endif /* __gen_nsIDOMHTMLStyleElement_h__ */
| [
"[email protected]"
] | |
87cddaad95add58021705f1e21827f0f7bb2bd33 | 3c3050f1a66acdd56bc04601c523730225940b8f | /fib/fib.cpp | 6e017d977946b193b7375c55f9197386f1a81015 | [
"MIT"
] | permissive | chenhongqiao/USACO | f8e54a99598b59d461532b5a6a63a36ba124eedc | 186d9d5fffe2663effbbdb9df2c7726eeb651098 | refs/heads/master | 2023-06-25T05:10:56.754702 | 2023-06-07T19:47:42 | 2023-06-07T19:47:42 | 233,294,481 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 248 | cpp | #include <iostream>
using namespace std;
int f[100005];
int main()
{
int n;
cin >> n;
f[0] = 1;
f[1] = 1;
for (int i = 2; i < n; i++)
{
f[i] = f[i - 1] + f[i - 2];
}
cout << f[n - 1] << endl;
return 0;
} | [
"[email protected]"
] | |
962d183b727eca2e5b882b4e00686d320a2671aa | db96b049c8e27f723fcb2f3a99291e631f1a1801 | /src/objtools/blast/seqdb_writer/seqidlist_writer.cpp | 0df7b7d2c4de9228714f1fb13aca90ccdbae12fb | [] | no_license | Watch-Later/ncbi-cxx-toolkit-public | 1c3a2502b21c7c5cee2c20c39e37861351bd2c05 | 39eede0aea59742ca4d346a6411b709a8566b269 | refs/heads/master | 2023-08-15T14:54:41.973806 | 2021-10-04T04:03:02 | 2021-10-04T04:03:02 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 5,674 | cpp | /*
* ===========================================================================
*
* PUBLIC DOMAIN NOTICE
* National Center for Biotechnology Information
*
* This software/database is a "United States Government Work" under the
* terms of the United States Copyright Act. It was written as part of
* the author's official duties as a United States Government employee and
* thus cannot be copyrighted. This software/database is freely available
* to the public for use. The National Library of Medicine and the U.S.
* Government have not placed any restriction on its use or reproduction.
*
* Although all reasonable efforts have been taken to ensure the accuracy
* and reliability of the software and data, the NLM and the U.S.
* Government do not and cannot warrant the performance or results that
* may be obtained by using this software or data. The NLM and the U.S.
* Government disclaim all warranties, express or implied, including
* warranties of performance, merchantability or fitness for any particular
* purpose.
*
* Please cite the author in any work or product based on this material.
*
* ===========================================================================
*
* Author: Amelia Fong
*
*/
#include <ncbi_pch.hpp>
#include <objtools/blast/seqdb_writer/seqidlist_writer.hpp>
#include <objtools/blast/seqdb_reader/seqdbcommon.hpp>
#include <objtools/blast/seqdb_reader/impl/seqdbgeneral.hpp>
#include <objects/seqloc/Seq_id.hpp>
BEGIN_NCBI_SCOPE
USING_SCOPE(objects);
/*
* This function creates v5 seqidlist file
* File Format:
* Header
* ------------------------------------------------------------------------------------
* char NULL byte
* Uint8 File Size
* Uint8 Total Num of Ids
* Uint4 Title Length (in bytes)
* char[] Title
* char Seqidlist create date string size (in bytes)
* char[] Seqidlist Create Date
* Uint8 Totol db length (0 if seqid list not associated with a specific db)
*
* If seqidlist is associated with a particular db:-
* char DB create date string size (in bytes)
* char[] DB create date
* Uint4 DB vol names string size (in bytes)
* char[] DB vol names
*
* Data
* ------------------------------------------------------------------------------------
* char ID string size (in bytes) if size >= byte max then byte set to 0xFF
* Uint4 ID string size if id size >= byte max
* char[] ID string
*
*/
int WriteBlastSeqidlistFile(const vector<string> & idlist, CNcbiOstream & os, const string & title, const CSeqDB * seqdb)
{
const char null_byte = 0;
Uint8 file_size = 0;
Uint8 total_num_ids = 0;
string create_date = kEmptyStr;
char create_date_size = 0;
Uint8 total_length = 0;
string vol_names = kEmptyStr;
Uint4 vol_names_size = 0;
Uint4 title_size = title.size();
string db_date = kEmptyStr;
char db_date_size = 0;
const unsigned char byte_max = 0xFF;
vector<string> tmplist;
tmplist.reserve(idlist.size());
if(seqdb != NULL) {
if (seqdb->GetBlastDbVersion() < eBDB_Version5) {
NCBI_THROW(CSeqDBException, eArgErr, "Seqidlist requires v5 database ");
}
total_length = seqdb->GetVolumeLength();
vector<string> vols;
seqdb->FindVolumePaths(vols, true);
ITERATE(vector<string>, itr, vols) {
if(itr != vols.begin()) {
vol_names += " ";
}
string v = kEmptyStr;
CSeqDB_Path(*itr).FindBaseName().GetString(v);
vol_names += v;
}
vol_names_size = vol_names.size();
db_date = seqdb->GetDate();
db_date_size = db_date.size();
}
for(unsigned int i=0; i < idlist.size(); i++) {
try {
CSeq_id seqid(idlist[i], CSeq_id::fParse_RawText | CSeq_id::fParse_AnyLocal | CSeq_id::fParse_PartialOK);
if(seqid.IsGi()) {
continue;
}
if(seqid.IsPir() || seqid.IsPrf()) {
string id = seqid.AsFastaString();
tmplist.push_back(id);
continue;
}
tmplist.push_back(seqid.GetSeqIdString(true));
} catch (CException & e) {
ERR_POST(e.GetMsg());
NCBI_THROW(CSeqDBException, eArgErr, "Invalid seq id: " + idlist[i]);
}
}
if (tmplist.size() == 0) {
ERR_POST("Empty seqid list");
return -1;
}
sort(tmplist.begin(), tmplist.end());
vector<string>::iterator it = unique (tmplist.begin(), tmplist.end());
tmplist.resize(distance(tmplist.begin(),it));
if(seqdb != NULL) {
vector<blastdb::TOid> oids;
vector<string> check_ids(tmplist);
seqdb->AccessionsToOids(check_ids, oids);
tmplist.clear();
for(unsigned int i=0; i < check_ids.size(); i++) {
if(oids[i] != kSeqDBEntryNotFound){
tmplist.push_back(check_ids[i]);
}
}
}
total_num_ids = tmplist.size();
CTime now(CTime::eCurrent);
create_date = now.AsString("b d, Y H:m P");
create_date_size = create_date.size();
os.write(&null_byte, 1);
os.write((char *)&file_size, 8);
os.write((char *)&total_num_ids, 8);
os.write((char *) &title_size, 4);
os.write(title.c_str(), title_size);
os.write(&create_date_size, 1);
os.write(create_date.c_str(), create_date_size);
os.write((char *)&total_length, 8);
if(vol_names != kEmptyStr) {
os.write(&db_date_size, 1);
os.write(db_date.c_str(), db_date_size);
os.write((char *) &vol_names_size, 4);
os.write(vol_names.c_str(), vol_names_size);
}
for(unsigned int i=0; i < tmplist.size(); i++) {
Uint4 id_len = tmplist[i].size();
if(id_len >= byte_max) {
os.write((char *)&byte_max, 1);
os.write((char *)&id_len, 4);
}
else {
char l = byte_max & id_len;
os.write(&l,1);
}
os.write(tmplist[i].c_str(), id_len);
}
os.flush();
file_size = (Uint8) os.tellp();
os.seekp(1);
os.write((char *)&file_size, 8);
os.flush();
return 0;
}
END_NCBI_SCOPE
| [
"ludwigf@78c7ea69-d796-4a43-9a09-de51944f1b03"
] | ludwigf@78c7ea69-d796-4a43-9a09-de51944f1b03 |
026abafe04e9c7daa8ef5380de84426794ef9f8c | 9de0cec678bc4a3bec2b4adabef9f39ff5b4afac | /PWGLF/SPECTRA/AntiprotonToProton/AliProtonCorrectionAnalysisTask.cxx | 2f39244c32f0e021023edc885b4086101ae456b2 | [] | permissive | alisw/AliPhysics | 91bf1bd01ab2af656a25ff10b25e618a63667d3e | 5df28b2b415e78e81273b0d9bf5c1b99feda3348 | refs/heads/master | 2023-08-31T20:41:44.927176 | 2023-08-31T14:51:12 | 2023-08-31T14:51:12 | 61,661,378 | 129 | 1,150 | BSD-3-Clause | 2023-09-14T18:48:45 | 2016-06-21T19:31:29 | C++ | UTF-8 | C++ | false | false | 9,551 | cxx | #include "TChain.h"
#include "TTree.h"
#include "TString.h"
#include "TList.h"
#include "TH2F.h"
#include "AliAnalysisTask.h"
#include "AliAnalysisManager.h"
#include "AliESDEvent.h"
#include "AliESDInputHandler.h"
#include "AliAODEvent.h"
#include "AliAODInputHandler.h"
#include "AliMCEventHandler.h"
#include "AliMCEvent.h"
#include "AliStack.h"
#include "AliESDVertex.h"
#include "AliProtonFeedDownAnalysis.h"
#include "AliProtonAnalysisBase.h"
#include "AliProtonCorrectionAnalysisTask.h"
#include "AliProtonAbsorptionCorrection.h"
#include "AliProtonSpectraCorrection.h"
#include <Riostream.h>
ClassImp(AliProtonCorrectionAnalysisTask)
//________________________________________________________________________
AliProtonCorrectionAnalysisTask::AliProtonCorrectionAnalysisTask()
: AliAnalysisTask(), fESD(0), fAOD(0), fMC(0),
fList(0),fProtonAnalysisBase(0),fProtonAbsorptionCorrection(0), fProtonFeedDownAnalysis(0),fProtonSpectraCorrection(0),fStatHist(0),
fIsOn_AliProtonAbsorptionCorrection(0),fIsOn_AliProtonFeedDownAnalysis(0),fIsOn_AliProtonSpectraCorrection(0)
{
//Dummy constructor
}
//________________________________________________________________________
AliProtonCorrectionAnalysisTask::AliProtonCorrectionAnalysisTask(const char *name)
: AliAnalysisTask(name, ""), fESD(0), fAOD(0), fMC(0),
fList(0),fProtonAnalysisBase(0),fProtonAbsorptionCorrection(0), fProtonFeedDownAnalysis(0),fProtonSpectraCorrection(0),fStatHist(0),
fIsOn_AliProtonAbsorptionCorrection(0),fIsOn_AliProtonFeedDownAnalysis(0),fIsOn_AliProtonSpectraCorrection(0)
{
// Constructor
// Define input and output slots here
// Input slot #0 works with a TChain
DefineInput(0, TChain::Class());
// Output slot #0 writes into a TList container
DefineOutput(0, TList::Class());
}
//________________________________________________________________________
void AliProtonCorrectionAnalysisTask::ConnectInputData(Option_t *)
{
// Connect ESD or AOD here
// Called once
TString gAnalysisLevel = fProtonAnalysisBase->GetAnalysisLevel();
TTree* tree = dynamic_cast<TTree*> (GetInputData(0));
if (!tree)
{
Printf("ERROR: Could not read chain from input slot 0");
}
else
{
if(gAnalysisLevel == "ESD")
{
AliESDInputHandler *esdH = dynamic_cast<AliESDInputHandler*> (AliAnalysisManager::GetAnalysisManager()->GetInputEventHandler());
if (!esdH)
{
Printf("ERROR: Could not get ESDInputHandler");
}
else
fESD = esdH->GetEvent();
AliMCEventHandler* mcH = dynamic_cast<AliMCEventHandler*> (AliAnalysisManager::GetAnalysisManager()->GetMCtruthEventHandler());
if (!mcH)
{
Printf("ERROR: Could not retrieve MC event handler");
}
else
fMC = mcH->MCEvent();
}
else if(gAnalysisLevel == "AOD")
{
AliAODInputHandler *aodH = dynamic_cast<AliAODInputHandler*> (AliAnalysisManager::GetAnalysisManager()->GetInputEventHandler());
if (!aodH)
{
Printf("ERROR: Could not get AODInputHandler");
}
else
fAOD = aodH->GetEvent();
}
else
Printf("Wrong analysis type: Only ESD, AOD types are allowed!");
}
}
//________________________________________________________________________
void AliProtonCorrectionAnalysisTask::CreateOutputObjects()
{
// Create output objects
// Called once
fList = new TList();
if(fIsOn_AliProtonAbsorptionCorrection)
{
fProtonAbsorptionCorrection->GetProtonContainer()->SetName("containerProtonsAbsorptionCorrection");
fList->Add(fProtonAbsorptionCorrection->GetProtonContainer());
fProtonAbsorptionCorrection->GetAntiProtonContainer()->SetName("containerAntiProtonsAbsorptionCorrection");
fList->Add(fProtonAbsorptionCorrection->GetAntiProtonContainer());
}
if(fIsOn_AliProtonFeedDownAnalysis)
{
fProtonFeedDownAnalysis->GetProtonContainer()->SetName("containerProtonsFeedDown");
fList->Add(fProtonFeedDownAnalysis->GetProtonContainer());
fProtonFeedDownAnalysis->GetAntiProtonContainer()->SetName("containerAntiProtonsFeedDown");
fList->Add(fProtonFeedDownAnalysis->GetAntiProtonContainer());
fList->Add(fProtonFeedDownAnalysis->GetLambdaHist());
fList->Add(fProtonFeedDownAnalysis->GetLambdaweightedHist());
fList->Add(fProtonFeedDownAnalysis->GetAntiLambdaHist());
fList->Add(fProtonFeedDownAnalysis->GetAntiLambdaweightedHist());
}
if(fIsOn_AliProtonSpectraCorrection)
{
fProtonSpectraCorrection->GetProtonContainer()->SetName("containerProtonsSpectraCorrection");
fList->Add(fProtonSpectraCorrection->GetProtonContainer());
fProtonSpectraCorrection->GetProtonContainer()->SetName("containerAntiProtonsSpectraCorrection");
fList->Add(fProtonSpectraCorrection->GetAntiProtonContainer());
}
fStatHist=new TH1F("StatsHist","StatsHist",10,-0.5,9.5);
fList->Add(fStatHist);
fStatHist->GetXaxis()->SetBinLabel(1,"level1cutESD");
fStatHist->GetXaxis()->SetBinLabel(2,"level2cutTrigger");
fStatHist->GetXaxis()->SetBinLabel(3,"level3cutVerstex");
fStatHist->GetXaxis()->SetBinLabel(4,"level4cutMC");
}
//________________________________________________________________________
void AliProtonCorrectionAnalysisTask::Exec(Option_t *)
{
// Main loop
// Called for each event
TString gAnalysisLevel =fProtonAnalysisBase->GetAnalysisLevel();
//TString gAnalysisLevel = (fProtonFeedDownAnalysis->GetProtonAnalysisBaseObject())->GetAnalysisLevel();
if(gAnalysisLevel == "ESD")
{
if (!fESD)
{
Printf("ERROR: fESD not available");
return;
}
fStatHist->Fill(0);
if(fProtonAnalysisBase->IsEventTriggered(fESD,fProtonAnalysisBase->GetTriggerMode()))
{
fStatHist->Fill(1);
const AliESDVertex *vertex = fProtonAnalysisBase->GetVertex(fESD,fProtonAnalysisBase->GetAnalysisMode(),fProtonAnalysisBase->GetVxMax(),fProtonAnalysisBase->GetVyMax(),fProtonAnalysisBase->GetVzMax());
if(vertex)
{
fStatHist->Fill(2);
Printf("Proton ESD analysis task: There are %d tracks in this event", fESD->GetNumberOfTracks());
AliStack* stack1=0x0;
if(!fMC)
return;
stack1 = fMC->Stack();
if(!stack1)
return;
fStatHist->Fill(3);
if(fIsOn_AliProtonAbsorptionCorrection)
//fProtonAbsorptionCorrection->FillAbsorptionMaps(fESD,vertex,fMC);
fProtonAbsorptionCorrection->FillAbsorptionMaps(fESD,fMC);
if(fIsOn_AliProtonFeedDownAnalysis)
{
fProtonFeedDownAnalysis->Analyze(fESD,vertex,stack1);
fProtonFeedDownAnalysis->Analyze(stack1);
}
if(fIsOn_AliProtonSpectraCorrection)
fProtonSpectraCorrection->FillCorrectionMaps(fESD,vertex,fMC);
}//reconstructed vertex
}//triggered event
}//ESD analysis
else if(gAnalysisLevel == "AOD")
{
if (!fAOD)
{
Printf("ERROR: fAOD not available");
return;
}
Printf("Proton AOD analysis task: There are %d tracks in this event", fAOD->GetNumberOfTracks());
if(fIsOn_AliProtonAbsorptionCorrection)
fProtonAbsorptionCorrection->FillAbsorptionMaps(fAOD);
if(fIsOn_AliProtonFeedDownAnalysis)
fProtonFeedDownAnalysis->Analyze(fAOD);
if(fIsOn_AliProtonSpectraCorrection)
fProtonSpectraCorrection->FillCorrectionMaps(fAOD);
}//AOD analysis
// Post output data.
PostData(0, fList);
}
//__________________________________________________________________________________________
void AliProtonCorrectionAnalysisTask::Terminate(Option_t *)
{
}
//___________________________________________________________________________________________
void AliProtonCorrectionAnalysisTask::SetAnalysisObjectAbsorptionCorrection(AliProtonAbsorptionCorrection *const analysis)
{
if (analysis&&fProtonAnalysisBase)
{
Printf("Absorption Correection ON\n");
fIsOn_AliProtonAbsorptionCorrection=kTRUE;
fProtonAbsorptionCorrection = analysis;
fProtonAbsorptionCorrection->SetBaseAnalysis(fProtonAnalysisBase);
fProtonAbsorptionCorrection->InitAnalysisHistograms(fProtonAnalysisBase->GetNBinsX(),fProtonAnalysisBase->GetMinX(),fProtonAnalysisBase->GetMaxX(),fProtonAnalysisBase->GetNBinsY(),fProtonAnalysisBase->GetMinY(),fProtonAnalysisBase->GetMaxY());
}
else
fIsOn_AliProtonAbsorptionCorrection=kFALSE;
}
//___________________________________________________________________________________________
void AliProtonCorrectionAnalysisTask::SetAnalysisObjectFeedDown(AliProtonFeedDownAnalysis *const analysis)
{
if (analysis&&fProtonAnalysisBase)
{
Printf("Feed Down ON\n");
fIsOn_AliProtonFeedDownAnalysis=kTRUE;
fProtonFeedDownAnalysis = analysis;
fProtonFeedDownAnalysis->SetBaseAnalysis(fProtonAnalysisBase);
fProtonFeedDownAnalysis->InitAnalysisHistograms(fProtonAnalysisBase->GetNBinsX(),fProtonAnalysisBase->GetMinX(),fProtonAnalysisBase->GetMaxX(),fProtonAnalysisBase->GetNBinsY(),fProtonAnalysisBase->GetMinY(),fProtonAnalysisBase->GetMaxY());
}
else
fIsOn_AliProtonFeedDownAnalysis=kFALSE;
}
//___________________________________________________________________________________________
void AliProtonCorrectionAnalysisTask::SetAnalysisObjectSpectraCorrection(AliProtonSpectraCorrection *const analysis)
{
if (analysis&&fProtonAnalysisBase)
{
Printf("Spectra Correection ON\n");
fIsOn_AliProtonSpectraCorrection=kTRUE;
fProtonSpectraCorrection= analysis;
fProtonSpectraCorrection->SetBaseAnalysis(fProtonAnalysisBase);
fProtonSpectraCorrection->InitAnalysisHistograms(fProtonAnalysisBase->GetNBinsX(),fProtonAnalysisBase->GetMinX(),fProtonAnalysisBase->GetMaxX(),fProtonAnalysisBase->GetNBinsY(),fProtonAnalysisBase->GetMinY(),fProtonAnalysisBase->GetMaxY());
}
else
fIsOn_AliProtonSpectraCorrection=kFALSE;
}
| [
"[email protected]"
] | |
0746439f41d9665433f7edc8b5c8e52135b5f69a | c0f94940a229f7a077bd9a0a16bb9865d6778580 | /一週間で身につくC++問題/応用4/exprob4-6/main.cpp | c02c8c750e7eb313b63a006c0409511801a67dca | [] | no_license | kmichy/c-lang-practice | c8a6215d57733e8f01b87d989d2a5115fd178e5c | 5d53375ff0e97622bce0f3b87fdaa6544d4bbcd7 | refs/heads/master | 2020-03-31T20:43:33.873719 | 2018-10-26T08:14:28 | 2018-10-26T08:14:28 | 152,552,718 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 1,252 | cpp | #include <iostream>
#include <list>
using namespace std;
int main(){
list<int> li;
int tmp = -2;
list<int>::iterator itr;
int flag = 0;
while(tmp != -1){
if(tmp >= 0){
if(li.empty() == true){
li.push_back(tmp);
cout << "入力された数:" << tmp << endl << endl;
}else{
flag = 0;
itr = li.begin();
cout << "入力された数:";
while(itr != li.end()){
if(tmp <= *itr && flag == 0){
if(itr == li.begin()){
li.push_front(tmp);
}else{
li.insert(itr,tmp);
}
cout << tmp << " ";
flag = 1;
}
cout << *itr << " ";
itr++;
}
if(flag == 0){
li.push_back(tmp);
cout << tmp;
}
cout << endl << endl;
}
}
cout << "正の整数を入力:";
cin >> tmp;
if(tmp != -1){
cout << endl;
}
}
} | [
"[email protected]"
] | |
6d97da950bf869418808d0a6e38b5472ac11ed47 | b2eff346882dbda0c272e9069b405fd46ea28eab | /src/masternodeman.cpp | 381e3402c7b02bf884a71210d4d51d3217f459f6 | [
"MIT"
] | permissive | baas-io/BaaS | 6e2d33dc66e13cdb7e07314b20f7425f011784e3 | 9bf43e1dc0958f7ac61e37476bd651c5c1b0fbe5 | refs/heads/master | 2020-05-09T12:57:14.969063 | 2019-06-10T15:08:54 | 2019-06-10T15:08:54 | 173,232,149 | 0 | 0 | MIT | 2019-03-13T12:30:56 | 2019-03-01T03:59:38 | C++ | UTF-8 | C++ | false | false | 28,661 | cpp | // Copyright (c) 2014-2015 The Dash developers
// Copyright (c) 2015-2018 The PIVX developers
// Copyright (c) 2018-2019 The BaaS developers
// Distributed under the MIT/X11 software license, see the accompanying
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
#include "masternodeman.h"
#include "activemasternode.h"
#include "addrman.h"
#include "masternode.h"
#include "obfuscation.h"
#include "spork.h"
#include "util.h"
#include <boost/filesystem.hpp>
/** Masternode manager */
CMasternodeMan mnodeman;
struct CompareLastPaid {
bool operator()(const pair<int64_t, CTxIn>& t1,
const pair<int64_t, CTxIn>& t2) const
{
return t1.first < t2.first;
}
};
struct CompareScoreTxIn {
bool operator()(const pair<int64_t, CTxIn>& t1,
const pair<int64_t, CTxIn>& t2) const
{
return t1.first < t2.first;
}
};
struct CompareScoreMN {
bool operator()(const pair<int64_t, CMasternode>& t1,
const pair<int64_t, CMasternode>& t2) const
{
return t1.first < t2.first;
}
};
//
// CMasternodeDB
//
CMasternodeDB::CMasternodeDB()
{
pathMN = GetDataDir() / "mncache.dat";
strMagicMessage = "MasternodeCache";
}
bool CMasternodeDB::Write(const CMasternodeMan& mnodemanToSave)
{
int64_t nStart = GetTimeMillis();
// serialize, checksum data up to that point, then append checksum
CDataStream ssMasternodes(SER_DISK, CLIENT_VERSION);
ssMasternodes << strMagicMessage; // masternode cache file specific magic message
ssMasternodes << FLATDATA(Params().MessageStart()); // network specific magic number
ssMasternodes << mnodemanToSave;
uint256 hash = Hash(ssMasternodes.begin(), ssMasternodes.end());
ssMasternodes << hash;
// open output file, and associate with CAutoFile
FILE* file = fopen(pathMN.string().c_str(), "wb");
CAutoFile fileout(file, SER_DISK, CLIENT_VERSION);
if (fileout.IsNull())
return error("%s : Failed to open file %s", __func__, pathMN.string());
// Write and commit header, data
try {
fileout << ssMasternodes;
} catch (std::exception& e) {
return error("%s : Serialize or I/O error - %s", __func__, e.what());
}
// FileCommit(fileout);
fileout.fclose();
LogPrint("masternode","Written info to mncache.dat %dms\n", GetTimeMillis() - nStart);
LogPrint("masternode"," %s\n", mnodemanToSave.ToString());
return true;
}
CMasternodeDB::ReadResult CMasternodeDB::Read(CMasternodeMan& mnodemanToLoad, bool fDryRun)
{
int64_t nStart = GetTimeMillis();
// open input file, and associate with CAutoFile
FILE* file = fopen(pathMN.string().c_str(), "rb");
CAutoFile filein(file, SER_DISK, CLIENT_VERSION);
if (filein.IsNull()) {
error("%s : Failed to open file %s", __func__, pathMN.string());
return FileError;
}
// use file size to size memory buffer
int fileSize = boost::filesystem::file_size(pathMN);
int dataSize = fileSize - sizeof(uint256);
// Don't try to resize to a negative number if file is small
if (dataSize < 0)
dataSize = 0;
vector<unsigned char> vchData;
vchData.resize(dataSize);
uint256 hashIn;
// read data and checksum from file
try {
filein.read((char*)&vchData[0], dataSize);
filein >> hashIn;
} catch (std::exception& e) {
error("%s : Deserialize or I/O error - %s", __func__, e.what());
return HashReadError;
}
filein.fclose();
CDataStream ssMasternodes(vchData, SER_DISK, CLIENT_VERSION);
// verify stored checksum matches input data
uint256 hashTmp = Hash(ssMasternodes.begin(), ssMasternodes.end());
if (hashIn != hashTmp) {
error("%s : Checksum mismatch, data corrupted", __func__);
return IncorrectHash;
}
unsigned char pchMsgTmp[4];
std::string strMagicMessageTmp;
try {
// de-serialize file header (masternode cache file specific magic message) and ..
ssMasternodes >> strMagicMessageTmp;
// ... verify the message matches predefined one
if (strMagicMessage != strMagicMessageTmp) {
error("%s : Invalid masternode cache magic message", __func__);
return IncorrectMagicMessage;
}
// de-serialize file header (network specific magic number) and ..
ssMasternodes >> FLATDATA(pchMsgTmp);
// ... verify the network matches ours
if (memcmp(pchMsgTmp, Params().MessageStart(), sizeof(pchMsgTmp))) {
error("%s : Invalid network magic number", __func__);
return IncorrectMagicNumber;
}
// de-serialize data into CMasternodeMan object
ssMasternodes >> mnodemanToLoad;
} catch (std::exception& e) {
mnodemanToLoad.Clear();
error("%s : Deserialize or I/O error - %s", __func__, e.what());
return IncorrectFormat;
}
LogPrint("masternode","Loaded info from mncache.dat %dms\n", GetTimeMillis() - nStart);
LogPrint("masternode"," %s\n", mnodemanToLoad.ToString());
if (!fDryRun) {
LogPrint("masternode","Masternode manager - cleaning....\n");
mnodemanToLoad.CheckAndRemove(true);
LogPrint("masternode","Masternode manager - result:\n");
LogPrint("masternode"," %s\n", mnodemanToLoad.ToString());
}
return Ok;
}
void DumpMasternodes()
{
int64_t nStart = GetTimeMillis();
CMasternodeDB mndb;
CMasternodeMan tempMnodeman;
LogPrint("masternode","Verifying mncache.dat format...\n");
CMasternodeDB::ReadResult readResult = mndb.Read(tempMnodeman, true);
// there was an error and it was not an error on file opening => do not proceed
if (readResult == CMasternodeDB::FileError)
LogPrint("masternode","Missing masternode cache file - mncache.dat, will try to recreate\n");
else if (readResult != CMasternodeDB::Ok) {
LogPrint("masternode","Error reading mncache.dat: ");
if (readResult == CMasternodeDB::IncorrectFormat)
LogPrint("masternode","magic is ok but data has invalid format, will try to recreate\n");
else {
LogPrint("masternode","file format is unknown or invalid, please fix it manually\n");
return;
}
}
LogPrint("masternode","Writting info to mncache.dat...\n");
mndb.Write(mnodeman);
LogPrint("masternode","Masternode dump finished %dms\n", GetTimeMillis() - nStart);
}
CMasternodeMan::CMasternodeMan()
{
nDsqCount = 0;
}
bool CMasternodeMan::Add(CMasternode& mn)
{
LOCK(cs);
if (!mn.IsEnabled())
return false;
CMasternode* pmn = Find(mn.vin);
if (pmn == NULL) {
LogPrint("masternode", "CMasternodeMan: Adding new Masternode %s - %i now\n", mn.vin.prevout.hash.ToString(), size() + 1);
vMasternodes.push_back(mn);
return true;
}
return false;
}
void CMasternodeMan::AskForMN(CNode* pnode, CTxIn& vin)
{
std::map<COutPoint, int64_t>::iterator i = mWeAskedForMasternodeListEntry.find(vin.prevout);
if (i != mWeAskedForMasternodeListEntry.end()) {
int64_t t = (*i).second;
if (GetTime() < t) return; // we've asked recently
}
// ask for the mnb info once from the node that sent mnp
LogPrint("masternode", "CMasternodeMan::AskForMN - Asking node for missing entry, vin: %s\n", vin.prevout.hash.ToString());
pnode->PushMessage("dseg", vin);
int64_t askAgain = GetTime() + MASTERNODE_MIN_MNP_SECONDS;
mWeAskedForMasternodeListEntry[vin.prevout] = askAgain;
}
void CMasternodeMan::Check()
{
LOCK(cs);
BOOST_FOREACH (CMasternode& mn, vMasternodes) {
mn.Check();
}
}
void CMasternodeMan::CheckAndRemove(bool forceExpiredRemoval)
{
Check();
LOCK(cs);
//remove inactive and outdated
vector<CMasternode>::iterator it = vMasternodes.begin();
while (it != vMasternodes.end()) {
if ((*it).activeState == CMasternode::MASTERNODE_REMOVE ||
(*it).activeState == CMasternode::MASTERNODE_VIN_SPENT ||
(forceExpiredRemoval && (*it).activeState == CMasternode::MASTERNODE_EXPIRED) ||
(*it).protocolVersion < masternodePayments.GetMinMasternodePaymentsProto()) {
LogPrint("masternode", "CMasternodeMan: Removing inactive Masternode %s - %i now\n", (*it).vin.prevout.hash.ToString(), size() - 1);
//erase all of the broadcasts we've seen from this vin
// -- if we missed a few pings and the node was removed, this will allow is to get it back without them
// sending a brand new mnb
map<uint256, CMasternodeBroadcast>::iterator it3 = mapSeenMasternodeBroadcast.begin();
while (it3 != mapSeenMasternodeBroadcast.end()) {
if ((*it3).second.vin == (*it).vin) {
masternodeSync.mapSeenSyncMNB.erase((*it3).first);
mapSeenMasternodeBroadcast.erase(it3++);
} else {
++it3;
}
}
// allow us to ask for this masternode again if we see another ping
map<COutPoint, int64_t>::iterator it2 = mWeAskedForMasternodeListEntry.begin();
while (it2 != mWeAskedForMasternodeListEntry.end()) {
if ((*it2).first == (*it).vin.prevout) {
mWeAskedForMasternodeListEntry.erase(it2++);
} else {
++it2;
}
}
it = vMasternodes.erase(it);
} else {
++it;
}
}
// check who's asked for the Masternode list
map<CNetAddr, int64_t>::iterator it1 = mAskedUsForMasternodeList.begin();
while (it1 != mAskedUsForMasternodeList.end()) {
if ((*it1).second < GetTime()) {
mAskedUsForMasternodeList.erase(it1++);
} else {
++it1;
}
}
// check who we asked for the Masternode list
it1 = mWeAskedForMasternodeList.begin();
while (it1 != mWeAskedForMasternodeList.end()) {
if ((*it1).second < GetTime()) {
mWeAskedForMasternodeList.erase(it1++);
} else {
++it1;
}
}
// check which Masternodes we've asked for
map<COutPoint, int64_t>::iterator it2 = mWeAskedForMasternodeListEntry.begin();
while (it2 != mWeAskedForMasternodeListEntry.end()) {
if ((*it2).second < GetTime()) {
mWeAskedForMasternodeListEntry.erase(it2++);
} else {
++it2;
}
}
// remove expired mapSeenMasternodeBroadcast
map<uint256, CMasternodeBroadcast>::iterator it3 = mapSeenMasternodeBroadcast.begin();
while (it3 != mapSeenMasternodeBroadcast.end()) {
if ((*it3).second.lastPing.sigTime < GetTime() - (MASTERNODE_REMOVAL_SECONDS * 2)) {
mapSeenMasternodeBroadcast.erase(it3++);
masternodeSync.mapSeenSyncMNB.erase((*it3).second.GetHash());
} else {
++it3;
}
}
// remove expired mapSeenMasternodePing
map<uint256, CMasternodePing>::iterator it4 = mapSeenMasternodePing.begin();
while (it4 != mapSeenMasternodePing.end()) {
if ((*it4).second.sigTime < GetTime() - (MASTERNODE_REMOVAL_SECONDS * 2)) {
mapSeenMasternodePing.erase(it4++);
} else {
++it4;
}
}
}
void CMasternodeMan::Clear()
{
LOCK(cs);
vMasternodes.clear();
mAskedUsForMasternodeList.clear();
mWeAskedForMasternodeList.clear();
mWeAskedForMasternodeListEntry.clear();
mapSeenMasternodeBroadcast.clear();
mapSeenMasternodePing.clear();
nDsqCount = 0;
}
int CMasternodeMan::stable_size ()
{
int nStable_size = 0;
int nMinProtocol = ActiveProtocol();
BOOST_FOREACH (CMasternode& mn, vMasternodes) {
if (mn.protocolVersion < nMinProtocol) {
continue; // Skip obsolete versions
}
mn.Check ();
if (!mn.IsEnabled ())
continue; // Skip not-enabled masternodes
nStable_size++;
}
return nStable_size;
}
int CMasternodeMan::CountEnabled(int protocolVersion)
{
int i = 0;
protocolVersion = protocolVersion == -1 ? masternodePayments.GetMinMasternodePaymentsProto() : protocolVersion;
BOOST_FOREACH (CMasternode& mn, vMasternodes) {
mn.Check();
if (mn.protocolVersion < protocolVersion || !mn.IsEnabled()) continue;
i++;
}
return i;
}
void CMasternodeMan::CountNetworks(int protocolVersion, int& ipv4, int& ipv6, int& onion)
{
protocolVersion = protocolVersion == -1 ? masternodePayments.GetMinMasternodePaymentsProto() : protocolVersion;
BOOST_FOREACH (CMasternode& mn, vMasternodes) {
mn.Check();
std::string strHost;
int port;
SplitHostPort(mn.addr.ToString(), port, strHost);
CNetAddr node = CNetAddr(strHost, false);
int nNetwork = node.GetNetwork();
switch (nNetwork) {
case 1 :
ipv4++;
break;
case 2 :
ipv6++;
break;
case 3 :
onion++;
break;
}
}
}
void CMasternodeMan::DsegUpdate(CNode* pnode)
{
LOCK(cs);
if (Params().NetworkID() == CBaseChainParams::MAIN) {
if (!(pnode->addr.IsRFC1918() || pnode->addr.IsLocal())) {
std::map<CNetAddr, int64_t>::iterator it = mWeAskedForMasternodeList.find(pnode->addr);
if (it != mWeAskedForMasternodeList.end()) {
if (GetTime() < (*it).second) {
LogPrint("masternode", "dseg - we already asked peer %i for the list; skipping...\n", pnode->GetId());
return;
}
}
}
}
pnode->PushMessage("dseg", CTxIn());
int64_t askAgain = GetTime() + MASTERNODES_DSEG_SECONDS;
mWeAskedForMasternodeList[pnode->addr] = askAgain;
}
CMasternode* CMasternodeMan::Find(const CScript& payee)
{
LOCK(cs);
CScript payee2;
BOOST_FOREACH (CMasternode& mn, vMasternodes) {
payee2 = GetScriptForDestination(mn.pubKeyCollateralAddress.GetID());
if (payee2 == payee)
return &mn;
}
return NULL;
}
CMasternode* CMasternodeMan::Find(const CTxIn& vin)
{
LOCK(cs);
BOOST_FOREACH (CMasternode& mn, vMasternodes) {
if (mn.vin.prevout == vin.prevout)
return &mn;
}
return NULL;
}
CMasternode* CMasternodeMan::Find(const CPubKey& pubKeyMasternode)
{
LOCK(cs);
BOOST_FOREACH (CMasternode& mn, vMasternodes) {
if (mn.pubKeyMasternode == pubKeyMasternode)
return &mn;
}
return NULL;
}
//
// Deterministically select the oldest/best masternode to pay on the network
//
CMasternode* CMasternodeMan::GetNextMasternodeInQueueForPayment(int nBlockHeight, bool fFilterSigTime, int& nCount)
{
LOCK(cs);
CMasternode* pBestMasternode = NULL;
std::vector<pair<int64_t, CTxIn> > vecMasternodeLastPaid;
/*
Make a vector with all of the last paid times
*/
int nMnCount = CountEnabled();
BOOST_FOREACH (CMasternode& mn, vMasternodes) {
mn.Check();
if (!mn.IsEnabled()) continue;
// //check protocol version
if (mn.protocolVersion < masternodePayments.GetMinMasternodePaymentsProto()) continue;
//it's in the list (up to 8 entries ahead of current block to allow propagation) -- so let's skip it
if (masternodePayments.IsScheduled(mn, nBlockHeight)) continue;
//it's too new, wait for a cycle
if (fFilterSigTime && mn.sigTime + (nMnCount * 2.6 * 60) > GetAdjustedTime()) continue;
//make sure it has as many confirmations as there are masternodes
if (mn.GetMasternodeInputAge() < nMnCount) continue;
vecMasternodeLastPaid.push_back(make_pair(mn.SecondsSincePayment(), mn.vin));
}
nCount = (int)vecMasternodeLastPaid.size();
//when the network is in the process of upgrading, don't penalize nodes that recently restarted
if (fFilterSigTime && nCount < nMnCount / 3) return GetNextMasternodeInQueueForPayment(nBlockHeight, false, nCount);
// Sort them high to low
sort(vecMasternodeLastPaid.rbegin(), vecMasternodeLastPaid.rend(), CompareLastPaid());
// Look at 1/10 of the oldest nodes (by last payment), calculate their scores and pay the best one
// -- This doesn't look at who is being paid in the +8-10 blocks, allowing for double payments very rarely
// -- 1/100 payments should be a double payment on mainnet - (1/(3000/10))*2
// -- (chance per block * chances before IsScheduled will fire)
int nTenthNetwork = CountEnabled() / 10;
int nCountTenth = 0;
uint256 nHigh = 0;
BOOST_FOREACH (PAIRTYPE(int64_t, CTxIn) & s, vecMasternodeLastPaid) {
CMasternode* pmn = Find(s.second);
if (!pmn) break;
uint256 n = pmn->CalculateScore(1, nBlockHeight - 100);
if (n > nHigh) {
nHigh = n;
pBestMasternode = pmn;
}
nCountTenth++;
if (nCountTenth >= nTenthNetwork) break;
}
return pBestMasternode;
}
CMasternode* CMasternodeMan::FindRandomNotInVec(std::vector<CTxIn>& vecToExclude, int protocolVersion)
{
LOCK(cs);
protocolVersion = protocolVersion == -1 ? masternodePayments.GetMinMasternodePaymentsProto() : protocolVersion;
int nCountEnabled = CountEnabled(protocolVersion);
LogPrint("masternode", "CMasternodeMan::FindRandomNotInVec - nCountEnabled - vecToExclude.size() %d\n", nCountEnabled - vecToExclude.size());
if (nCountEnabled - vecToExclude.size() < 1) return NULL;
int rand = GetRandInt(nCountEnabled - vecToExclude.size());
LogPrint("masternode", "CMasternodeMan::FindRandomNotInVec - rand %d\n", rand);
bool found;
BOOST_FOREACH (CMasternode& mn, vMasternodes) {
if (mn.protocolVersion < protocolVersion || !mn.IsEnabled()) continue;
found = false;
BOOST_FOREACH (CTxIn& usedVin, vecToExclude) {
if (mn.vin.prevout == usedVin.prevout) {
found = true;
break;
}
}
if (found) continue;
if (--rand < 1) {
return &mn;
}
}
return NULL;
}
CMasternode* CMasternodeMan::GetCurrentMasterNode(int mod, int64_t nBlockHeight, int minProtocol)
{
int64_t score = 0;
CMasternode* winner = NULL;
// scan for winner
BOOST_FOREACH (CMasternode& mn, vMasternodes) {
mn.Check();
if (mn.protocolVersion < minProtocol || !mn.IsEnabled()) continue;
// calculate the score for each Masternode
uint256 n = mn.CalculateScore(mod, nBlockHeight);
int64_t n2 = n.GetCompact(false);
// determine the winner
if (n2 > score) {
score = n2;
winner = &mn;
}
}
return winner;
}
int CMasternodeMan::GetMasternodeRank(const CTxIn& vin, int64_t nBlockHeight, int minProtocol, bool fOnlyActive)
{
std::vector<pair<int64_t, CTxIn> > vecMasternodeScores;
//make sure we know about this block
uint256 hash = 0;
if (!GetBlockHash(hash, nBlockHeight)) return -1;
// scan for winner
BOOST_FOREACH (CMasternode& mn, vMasternodes) {
if (mn.protocolVersion < minProtocol) {
LogPrint("masternode","Skipping Masternode with obsolete version %d\n", mn.protocolVersion);
continue; // Skip obsolete versions
}
if (fOnlyActive) {
mn.Check();
if (!mn.IsEnabled()) continue;
}
uint256 n = mn.CalculateScore(1, nBlockHeight);
int64_t n2 = n.GetCompact(false);
vecMasternodeScores.push_back(make_pair(n2, mn.vin));
}
sort(vecMasternodeScores.rbegin(), vecMasternodeScores.rend(), CompareScoreTxIn());
int rank = 0;
BOOST_FOREACH (PAIRTYPE(int64_t, CTxIn) & s, vecMasternodeScores) {
rank++;
if (s.second.prevout == vin.prevout) {
return rank;
}
}
return -1;
}
std::vector<pair<int, CMasternode> > CMasternodeMan::GetMasternodeRanks(int64_t nBlockHeight, int minProtocol)
{
std::vector<pair<int64_t, CMasternode> > vecMasternodeScores;
std::vector<pair<int, CMasternode> > vecMasternodeRanks;
//make sure we know about this block
uint256 hash = 0;
if (!GetBlockHash(hash, nBlockHeight)) return vecMasternodeRanks;
// scan for winner
BOOST_FOREACH (CMasternode& mn, vMasternodes) {
mn.Check();
if (mn.protocolVersion < minProtocol) continue;
if (!mn.IsEnabled()) {
vecMasternodeScores.push_back(make_pair(9999, mn));
continue;
}
uint256 n = mn.CalculateScore(1, nBlockHeight);
int64_t n2 = n.GetCompact(false);
vecMasternodeScores.push_back(make_pair(n2, mn));
}
sort(vecMasternodeScores.rbegin(), vecMasternodeScores.rend(), CompareScoreMN());
int rank = 0;
BOOST_FOREACH (PAIRTYPE(int64_t, CMasternode) & s, vecMasternodeScores) {
rank++;
vecMasternodeRanks.push_back(make_pair(rank, s.second));
}
return vecMasternodeRanks;
}
CMasternode* CMasternodeMan::GetMasternodeByRank(int nRank, int64_t nBlockHeight, int minProtocol, bool fOnlyActive)
{
std::vector<pair<int64_t, CTxIn> > vecMasternodeScores;
// scan for winner
BOOST_FOREACH (CMasternode& mn, vMasternodes) {
if (mn.protocolVersion < minProtocol) continue;
if (fOnlyActive) {
mn.Check();
if (!mn.IsEnabled()) continue;
}
uint256 n = mn.CalculateScore(1, nBlockHeight);
int64_t n2 = n.GetCompact(false);
vecMasternodeScores.push_back(make_pair(n2, mn.vin));
}
sort(vecMasternodeScores.rbegin(), vecMasternodeScores.rend(), CompareScoreTxIn());
int rank = 0;
BOOST_FOREACH (PAIRTYPE(int64_t, CTxIn) & s, vecMasternodeScores) {
rank++;
if (rank == nRank) {
return Find(s.second);
}
}
return NULL;
}
void CMasternodeMan::ProcessMessage(CNode* pfrom, std::string& strCommand, CDataStream& vRecv)
{
if (fLiteMode) return; //disable all Obfuscation/Masternode related functionality
if (!masternodeSync.IsBlockchainSynced()) return;
LOCK(cs_process_message);
if (strCommand == "mnb") { //Masternode Broadcast
CMasternodeBroadcast mnb;
vRecv >> mnb;
if (mapSeenMasternodeBroadcast.count(mnb.GetHash())) { //seen
masternodeSync.AddedMasternodeList(mnb.GetHash());
return;
}
mapSeenMasternodeBroadcast.insert(make_pair(mnb.GetHash(), mnb));
int nDoS = 0;
if (!mnb.CheckAndUpdate(nDoS)) {
if (nDoS > 0)
Misbehaving(pfrom->GetId(), nDoS);
//failed
return;
}
// make sure the vout that was signed is related to the transaction that spawned the Masternode
// - this is expensive, so it's only done once per Masternode
if (!masternodeSigner.IsVinAssociatedWithPubkey(mnb.vin, mnb.pubKeyCollateralAddress)) {
LogPrintf("CMasternodeMan::ProcessMessage() : mnb - Got mismatched pubkey and vin\n");
Misbehaving(pfrom->GetId(), 33);
return;
}
// make sure it's still unspent
// - this is checked later by .check() in many places and by ThreadMasternodePool()
if (mnb.CheckInputsAndAdd(nDoS)) {
// use this as a peer
addrman.Add(CAddress(mnb.addr), pfrom->addr, 2 * 60 * 60);
masternodeSync.AddedMasternodeList(mnb.GetHash());
} else {
LogPrint("masternode","mnb - Rejected Masternode entry %s\n", mnb.vin.prevout.hash.ToString());
if (nDoS > 0)
Misbehaving(pfrom->GetId(), nDoS);
}
}
else if (strCommand == "mnp") { //Masternode Ping
CMasternodePing mnp;
vRecv >> mnp;
LogPrint("masternode", "mnp - Masternode ping, vin: %s\n", mnp.vin.prevout.hash.ToString());
if (mapSeenMasternodePing.count(mnp.GetHash())) return; //seen
mapSeenMasternodePing.insert(make_pair(mnp.GetHash(), mnp));
int nDoS = 0;
if (mnp.CheckAndUpdate(nDoS)) return;
if (nDoS > 0) {
// if anything significant failed, mark that node
Misbehaving(pfrom->GetId(), nDoS);
} else {
// if nothing significant failed, search existing Masternode list
CMasternode* pmn = Find(mnp.vin);
// if it's known, don't ask for the mnb, just return
if (pmn != NULL) return;
}
// something significant is broken or mn is unknown,
// we might have to ask for a masternode entry once
AskForMN(pfrom, mnp.vin);
} else if (strCommand == "dseg") { //Get Masternode list or specific entry
CTxIn vin;
vRecv >> vin;
if (vin == CTxIn()) { //only should ask for this once
//local network
bool isLocal = (pfrom->addr.IsRFC1918() || pfrom->addr.IsLocal());
if (!isLocal && Params().NetworkID() == CBaseChainParams::MAIN) {
std::map<CNetAddr, int64_t>::iterator i = mAskedUsForMasternodeList.find(pfrom->addr);
if (i != mAskedUsForMasternodeList.end()) {
int64_t t = (*i).second;
if (GetTime() < t) {
LogPrintf("CMasternodeMan::ProcessMessage() : dseg - peer already asked me for the list\n");
Misbehaving(pfrom->GetId(), 34);
return;
}
}
int64_t askAgain = GetTime() + MASTERNODES_DSEG_SECONDS;
mAskedUsForMasternodeList[pfrom->addr] = askAgain;
}
} //else, asking for a specific node which is ok
int nInvCount = 0;
BOOST_FOREACH (CMasternode& mn, vMasternodes) {
if (mn.addr.IsRFC1918()) continue; //local network
if (mn.IsEnabled()) {
LogPrint("masternode", "dseg - Sending Masternode entry - %s \n", mn.vin.prevout.hash.ToString());
if (vin == CTxIn() || vin == mn.vin) {
CMasternodeBroadcast mnb = CMasternodeBroadcast(mn);
uint256 hash = mnb.GetHash();
pfrom->PushInventory(CInv(MSG_MASTERNODE_ANNOUNCE, hash));
nInvCount++;
if (!mapSeenMasternodeBroadcast.count(hash)) mapSeenMasternodeBroadcast.insert(make_pair(hash, mnb));
if (vin == mn.vin) {
LogPrint("masternode", "dseg - Sent 1 Masternode entry to peer %i\n", pfrom->GetId());
return;
}
}
}
}
if (vin == CTxIn()) {
pfrom->PushMessage("ssc", MASTERNODE_SYNC_LIST, nInvCount);
LogPrint("masternode", "dseg - Sent %d Masternode entries to peer %i\n", nInvCount, pfrom->GetId());
}
}
}
void CMasternodeMan::Remove(CTxIn vin)
{
LOCK(cs);
vector<CMasternode>::iterator it = vMasternodes.begin();
while (it != vMasternodes.end()) {
if ((*it).vin == vin) {
LogPrint("masternode", "CMasternodeMan: Removing Masternode %s - %i now\n", (*it).vin.prevout.hash.ToString(), size() - 1);
vMasternodes.erase(it);
break;
}
++it;
}
}
void CMasternodeMan::UpdateMasternodeList(CMasternodeBroadcast mnb)
{
mapSeenMasternodePing.insert(make_pair(mnb.lastPing.GetHash(), mnb.lastPing));
mapSeenMasternodeBroadcast.insert(make_pair(mnb.GetHash(), mnb));
masternodeSync.AddedMasternodeList(mnb.GetHash());
LogPrint("masternode","CMasternodeMan::UpdateMasternodeList() -- masternode=%s\n", mnb.vin.prevout.ToString());
CMasternode* pmn = Find(mnb.vin);
if (pmn == NULL) {
CMasternode mn(mnb);
Add(mn);
} else {
pmn->UpdateFromNewBroadcast(mnb);
}
}
std::string CMasternodeMan::ToString() const
{
std::ostringstream info;
info << "Masternodes: " << (int)vMasternodes.size() << ", peers who asked us for Masternode list: " << (int)mAskedUsForMasternodeList.size() << ", peers we asked for Masternode list: " << (int)mWeAskedForMasternodeList.size() << ", entries in Masternode list we asked for: " << (int)mWeAskedForMasternodeListEntry.size() << ", nDsqCount: " << (int)nDsqCount;
return info.str();
}
| [
"[email protected]"
] | |
12383b98e8cf38f7a7c9f6c7a652ad6d68cc6e13 | e700064be70bc5faeb5c77fbbae3799517678599 | /day01/ex07/replace.hpp | dee3696ac1466cd173733837f959ef93da95fc0f | [] | no_license | dadavyde/Piscine-c- | 00425e44458596d0f28159358a53cbdbac242f7b | 9b2890260a90dcaaaba68f1c2842d4eaf8ec7166 | refs/heads/master | 2020-04-02T00:26:46.549994 | 2018-10-20T14:58:04 | 2018-10-20T14:58:04 | 153,805,296 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 1,112 | hpp | /* ************************************************************************** */
/* */
/* ::: :::::::: */
/* replace.hpp :+: :+: :+: */
/* +:+ +:+ +:+ */
/* By: dadavyde <[email protected]> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2018/10/03 20:11:25 by dadavyde #+# #+# */
/* Updated: 2018/10/03 20:11:26 by dadavyde ### ########.fr */
/* */
/* ************************************************************************** */
#ifndef REPLACE_H
# define REPLACE_H
#include <string>
#include <fstream>
#include <streambuf>
#include <sstream>
void replace(std::string filename, std::string &s1, std::string &s2);
#endif
| [
"[email protected]"
] | |
0d8ca40c645151858a7729eb4563ba07ed9f4631 | 6f98564ab3c0ca98ac675c4d9bd919f2cb08e790 | /trunk/src/linedef.cpp | 78b824bef61d91fa7db061754db2d032fc3bd740 | [] | no_license | BackupTheBerlios/godafude-svn | a0e065e786078f219e516f4225a7dded16ae4abf | c56dfe2b4ca1e7e0a3f438440f9d35c9e4f9e863 | refs/heads/master | 2021-01-22T02:40:58.866354 | 2005-05-19T19:26:55 | 2005-05-19T19:26:55 | 40,667,886 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 1,831 | cpp | // Godafude - A Map Editor for DOOM
// Copyright (c) 2005 Sascha Mueller <[email protected]>
/******************************************************************
* 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. *
******************************************************************/
#include <QDataStream>
#include "linedef.h"
namespace gamemap
{
Linedef::Linedef( QDataStream &s, bool isHexen )
{
qint16 n;
s >> n; v1_ = n;
s >> n; v2_ = n;
s >> n;
flags_.impassable = n & 0x0001 == 1;
flags_.blocksmonsters = n & 0x0002 == 1;
flags_.twosided = n & 0x0004 == 1;
flags_.upperunpegged = n & 0x0008 == 1;
flags_.lowerunpegged = n & 0x0010 == 1;
flags_.secret = n & 0x0020 == 1;
flags_.blockssound = n & 0x0040 == 1;
flags_.notonmap = n & 0x0080 == 1;
flags_.alreadyonmap = n & 0x0100 == 1;
flags_.repeatable = isHexen ? (n & 0x0200 == 1) : 1;
flags_.activation = isHexen ? (n & 0x1c00) >> 10 : 0;
if( isHexen )
{
quint8 b;
s >> b; action_ = b;
s >> b; args_[0] = b;
s >> b; args_[1] = b;
s >> b; args_[2] = b;
s >> b; args_[3] = b;
s >> b; args_[4] = b;
}
else
{
s >> n; action_ = n;
s >> n; args_[0] = n;
args_[1] = args_[2] = args_[3] = args_[4] = 0;
}
s >> n; side1_ = n;
s >> n; side2_ = n;
}
}
| [
"saschamueller@93ce3444-17f4-0310-869f-feeeb9b2a701"
] | saschamueller@93ce3444-17f4-0310-869f-feeeb9b2a701 |
253be2d3ccdfe659e8602874675d082bc42c8c46 | 77315d0f84ec16354b490e705722df39be47b7b6 | /Source/NoesisGui/Private/GeneratedClasses/NoesisInt32Animation.cpp | 61a89f54829c931b8d41d3504037edd6ceb35d0b | [] | no_license | miaohongbiao/UE4Plugin | d259f57fadf77a5b152249fe303f5947ae4f28b7 | 8ae40958c823e6a5a29f8ff3fef1ba4c4c449623 | refs/heads/master | 2021-06-21T14:26:42.443016 | 2017-02-27T19:48:27 | 2017-02-27T19:48:27 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 1,348 | cpp | ////////////////////////////////////////////////////////////////////////////////////////////////////
// Noesis Engine - http://www.noesisengine.com
// Copyright (c) 2009-2010 Noesis Technologies S.L. All Rights Reserved.
////////////////////////////////////////////////////////////////////////////////////////////////////
#include "NoesisGuiPrivatePCH.h"
#include "GeneratedClasses/NoesisInt32Animation.h"
using namespace Noesis;
using namespace Gui;
UNoesisInt32Animation::UNoesisInt32Animation(const FObjectInitializer& ObjectInitializer)
: Super(ObjectInitializer)
{
}
void UNoesisInt32Animation::SetNoesisComponent(Noesis::Core::BaseComponent* InNoesisComponent)
{
Super::SetNoesisComponent(InNoesisComponent);
Noesis::Gui::Animation<NsInt32>* NoesisInt32Animation = NsDynamicCast<Noesis::Gui::Animation<NsInt32>*>(InNoesisComponent);
check(NoesisInt32Animation);
}
void UNoesisInt32Animation::BindEvents()
{
Super::BindEvents();
Noesis::Gui::Animation<NsInt32>* NoesisInt32Animation = NsDynamicCast<Noesis::Gui::Animation<NsInt32>*>(NoesisComponent.GetPtr());
check(NoesisInt32Animation)
}
void UNoesisInt32Animation::UnbindEvents()
{
Super::UnbindEvents();
Noesis::Gui::Animation<NsInt32>* NoesisInt32Animation = NsDynamicCast<Noesis::Gui::Animation<NsInt32>*>(NoesisComponent.GetPtr());
check(NoesisInt32Animation)
}
| [
"[email protected]"
] | |
180232652d0bb435717b03179c614f3d4b4b7ef0 | 4114e01c18585e08f86c6fc7f15ac1600c5819f5 | /src/qt/qrcodedialog.cpp | 841707ed9863386213e57b647d8537b93eb6248f | [
"MIT"
] | permissive | digiwhite/IncaKoin | 30b04e70f383b14c4dca8d1d77a761a04aeee222 | 373d3fc165f4fcf66676ab0895988356468ad8c5 | refs/heads/master | 2021-01-17T20:51:14.044916 | 2014-05-06T21:53:49 | 2014-05-06T21:53:49 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 4,314 | cpp | #include "qrcodedialog.h"
#include "ui_qrcodedialog.h"
#include "IncaKoinunits.h"
#include "guiconstants.h"
#include "guiutil.h"
#include "optionsmodel.h"
#include <QPixmap>
#include <QUrl>
#include <qrencode.h>
QRCodeDialog::QRCodeDialog(const QString &addr, const QString &label, bool enableReq, QWidget *parent) :
QDialog(parent),
ui(new Ui::QRCodeDialog),
model(0),
address(addr)
{
ui->setupUi(this);
setWindowTitle(QString("%1").arg(address));
ui->chkReqPayment->setVisible(enableReq);
ui->lblAmount->setVisible(enableReq);
ui->lnReqAmount->setVisible(enableReq);
ui->lnLabel->setText(label);
ui->btnSaveAs->setEnabled(false);
genCode();
}
QRCodeDialog::~QRCodeDialog()
{
delete ui;
}
void QRCodeDialog::setModel(OptionsModel *model)
{
this->model = model;
if (model)
connect(model, SIGNAL(displayUnitChanged(int)), this, SLOT(updateDisplayUnit()));
// update the display unit, to not use the default ("BTC")
updateDisplayUnit();
}
void QRCodeDialog::genCode()
{
QString uri = getURI();
if (uri != "")
{
ui->lblQRCode->setText("");
QRcode *code = QRcode_encodeString(uri.toUtf8().constData(), 0, QR_ECLEVEL_L, QR_MODE_8, 1);
if (!code)
{
ui->lblQRCode->setText(tr("Error encoding URI into QR Code."));
return;
}
myImage = QImage(code->width + 8, code->width + 8, QImage::Format_RGB32);
myImage.fill(0xffffff);
unsigned char *p = code->data;
for (int y = 0; y < code->width; y++)
{
for (int x = 0; x < code->width; x++)
{
myImage.setPixel(x + 4, y + 4, ((*p & 1) ? 0x0 : 0xffffff));
p++;
}
}
QRcode_free(code);
ui->lblQRCode->setPixmap(QPixmap::fromImage(myImage).scaled(300, 300));
ui->outUri->setPlainText(uri);
}
}
QString QRCodeDialog::getURI()
{
QString ret = QString("IncaKoin:%1").arg(address);
int paramCount = 0;
ui->outUri->clear();
if (ui->chkReqPayment->isChecked())
{
if (ui->lnReqAmount->validate())
{
// even if we allow a non BTC unit input in lnReqAmount, we generate the URI with BTC as unit (as defined in BIP21)
ret += QString("?amount=%1").arg(IncaKoinUnits::format(IncaKoinUnits::BTC, ui->lnReqAmount->value()));
paramCount++;
}
else
{
ui->btnSaveAs->setEnabled(false);
ui->lblQRCode->setText(tr("The entered amount is invalid, please check."));
return QString("");
}
}
if (!ui->lnLabel->text().isEmpty())
{
QString lbl(QUrl::toPercentEncoding(ui->lnLabel->text()));
ret += QString("%1label=%2").arg(paramCount == 0 ? "?" : "&").arg(lbl);
paramCount++;
}
if (!ui->lnMessage->text().isEmpty())
{
QString msg(QUrl::toPercentEncoding(ui->lnMessage->text()));
ret += QString("%1message=%2").arg(paramCount == 0 ? "?" : "&").arg(msg);
paramCount++;
}
// limit URI length to prevent a DoS against the QR-Code dialog
if (ret.length() > MAX_URI_LENGTH)
{
ui->btnSaveAs->setEnabled(false);
ui->lblQRCode->setText(tr("Resulting URI too long, try to reduce the text for label / message."));
return QString("");
}
ui->btnSaveAs->setEnabled(true);
return ret;
}
void QRCodeDialog::on_lnReqAmount_textChanged()
{
genCode();
}
void QRCodeDialog::on_lnLabel_textChanged()
{
genCode();
}
void QRCodeDialog::on_lnMessage_textChanged()
{
genCode();
}
void QRCodeDialog::on_btnSaveAs_clicked()
{
QString fn = GUIUtil::getSaveFileName(this, tr("Save QR Code"), QString(), tr("PNG Images (*.png)"));
if (!fn.isEmpty())
myImage.scaled(EXPORT_IMAGE_SIZE, EXPORT_IMAGE_SIZE).save(fn);
}
void QRCodeDialog::on_chkReqPayment_toggled(bool fChecked)
{
if (!fChecked)
// if chkReqPayment is not active, don't display lnReqAmount as invalid
ui->lnReqAmount->setValid(true);
genCode();
}
void QRCodeDialog::updateDisplayUnit()
{
if (model)
{
// Update lnReqAmount with the current unit
ui->lnReqAmount->setDisplayUnit(model->getDisplayUnit());
}
}
| [
"[email protected]"
] | |
bd91fa75e57acf590d0c13a255fb1dfc5666ebe6 | 3ff1fe3888e34cd3576d91319bf0f08ca955940f | /teo/src/v20220901/model/Https.cpp | c0f4cf0e2c4a83d1b82216d2c8c0446ff8b43f89 | [
"Apache-2.0"
] | permissive | TencentCloud/tencentcloud-sdk-cpp | 9f5df8220eaaf72f7eaee07b2ede94f89313651f | 42a76b812b81d1b52ec6a217fafc8faa135e06ca | refs/heads/master | 2023-08-30T03:22:45.269556 | 2023-08-30T00:45:39 | 2023-08-30T00:45:39 | 188,991,963 | 55 | 37 | Apache-2.0 | 2023-08-17T03:13:20 | 2019-05-28T08:56:08 | C++ | UTF-8 | C++ | false | false | 8,948 | cpp | /*
* Copyright (c) 2017-2019 THL A29 Limited, a Tencent company. All Rights Reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#include <tencentcloud/teo/v20220901/model/Https.h>
using TencentCloud::CoreInternalOutcome;
using namespace TencentCloud::Teo::V20220901::Model;
using namespace std;
Https::Https() :
m_http2HasBeenSet(false),
m_ocspStaplingHasBeenSet(false),
m_tlsVersionHasBeenSet(false),
m_hstsHasBeenSet(false),
m_certInfoHasBeenSet(false),
m_applyTypeHasBeenSet(false),
m_cipherSuiteHasBeenSet(false)
{
}
CoreInternalOutcome Https::Deserialize(const rapidjson::Value &value)
{
string requestId = "";
if (value.HasMember("Http2") && !value["Http2"].IsNull())
{
if (!value["Http2"].IsString())
{
return CoreInternalOutcome(Core::Error("response `Https.Http2` IsString=false incorrectly").SetRequestId(requestId));
}
m_http2 = string(value["Http2"].GetString());
m_http2HasBeenSet = true;
}
if (value.HasMember("OcspStapling") && !value["OcspStapling"].IsNull())
{
if (!value["OcspStapling"].IsString())
{
return CoreInternalOutcome(Core::Error("response `Https.OcspStapling` IsString=false incorrectly").SetRequestId(requestId));
}
m_ocspStapling = string(value["OcspStapling"].GetString());
m_ocspStaplingHasBeenSet = true;
}
if (value.HasMember("TlsVersion") && !value["TlsVersion"].IsNull())
{
if (!value["TlsVersion"].IsArray())
return CoreInternalOutcome(Core::Error("response `Https.TlsVersion` is not array type"));
const rapidjson::Value &tmpValue = value["TlsVersion"];
for (rapidjson::Value::ConstValueIterator itr = tmpValue.Begin(); itr != tmpValue.End(); ++itr)
{
m_tlsVersion.push_back((*itr).GetString());
}
m_tlsVersionHasBeenSet = true;
}
if (value.HasMember("Hsts") && !value["Hsts"].IsNull())
{
if (!value["Hsts"].IsObject())
{
return CoreInternalOutcome(Core::Error("response `Https.Hsts` is not object type").SetRequestId(requestId));
}
CoreInternalOutcome outcome = m_hsts.Deserialize(value["Hsts"]);
if (!outcome.IsSuccess())
{
outcome.GetError().SetRequestId(requestId);
return outcome;
}
m_hstsHasBeenSet = true;
}
if (value.HasMember("CertInfo") && !value["CertInfo"].IsNull())
{
if (!value["CertInfo"].IsArray())
return CoreInternalOutcome(Core::Error("response `Https.CertInfo` is not array type"));
const rapidjson::Value &tmpValue = value["CertInfo"];
for (rapidjson::Value::ConstValueIterator itr = tmpValue.Begin(); itr != tmpValue.End(); ++itr)
{
ServerCertInfo item;
CoreInternalOutcome outcome = item.Deserialize(*itr);
if (!outcome.IsSuccess())
{
outcome.GetError().SetRequestId(requestId);
return outcome;
}
m_certInfo.push_back(item);
}
m_certInfoHasBeenSet = true;
}
if (value.HasMember("ApplyType") && !value["ApplyType"].IsNull())
{
if (!value["ApplyType"].IsString())
{
return CoreInternalOutcome(Core::Error("response `Https.ApplyType` IsString=false incorrectly").SetRequestId(requestId));
}
m_applyType = string(value["ApplyType"].GetString());
m_applyTypeHasBeenSet = true;
}
if (value.HasMember("CipherSuite") && !value["CipherSuite"].IsNull())
{
if (!value["CipherSuite"].IsString())
{
return CoreInternalOutcome(Core::Error("response `Https.CipherSuite` IsString=false incorrectly").SetRequestId(requestId));
}
m_cipherSuite = string(value["CipherSuite"].GetString());
m_cipherSuiteHasBeenSet = true;
}
return CoreInternalOutcome(true);
}
void Https::ToJsonObject(rapidjson::Value &value, rapidjson::Document::AllocatorType& allocator) const
{
if (m_http2HasBeenSet)
{
rapidjson::Value iKey(rapidjson::kStringType);
string key = "Http2";
iKey.SetString(key.c_str(), allocator);
value.AddMember(iKey, rapidjson::Value(m_http2.c_str(), allocator).Move(), allocator);
}
if (m_ocspStaplingHasBeenSet)
{
rapidjson::Value iKey(rapidjson::kStringType);
string key = "OcspStapling";
iKey.SetString(key.c_str(), allocator);
value.AddMember(iKey, rapidjson::Value(m_ocspStapling.c_str(), allocator).Move(), allocator);
}
if (m_tlsVersionHasBeenSet)
{
rapidjson::Value iKey(rapidjson::kStringType);
string key = "TlsVersion";
iKey.SetString(key.c_str(), allocator);
value.AddMember(iKey, rapidjson::Value(rapidjson::kArrayType).Move(), allocator);
for (auto itr = m_tlsVersion.begin(); itr != m_tlsVersion.end(); ++itr)
{
value[key.c_str()].PushBack(rapidjson::Value().SetString((*itr).c_str(), allocator), allocator);
}
}
if (m_hstsHasBeenSet)
{
rapidjson::Value iKey(rapidjson::kStringType);
string key = "Hsts";
iKey.SetString(key.c_str(), allocator);
value.AddMember(iKey, rapidjson::Value(rapidjson::kObjectType).Move(), allocator);
m_hsts.ToJsonObject(value[key.c_str()], allocator);
}
if (m_certInfoHasBeenSet)
{
rapidjson::Value iKey(rapidjson::kStringType);
string key = "CertInfo";
iKey.SetString(key.c_str(), allocator);
value.AddMember(iKey, rapidjson::Value(rapidjson::kArrayType).Move(), allocator);
int i=0;
for (auto itr = m_certInfo.begin(); itr != m_certInfo.end(); ++itr, ++i)
{
value[key.c_str()].PushBack(rapidjson::Value(rapidjson::kObjectType).Move(), allocator);
(*itr).ToJsonObject(value[key.c_str()][i], allocator);
}
}
if (m_applyTypeHasBeenSet)
{
rapidjson::Value iKey(rapidjson::kStringType);
string key = "ApplyType";
iKey.SetString(key.c_str(), allocator);
value.AddMember(iKey, rapidjson::Value(m_applyType.c_str(), allocator).Move(), allocator);
}
if (m_cipherSuiteHasBeenSet)
{
rapidjson::Value iKey(rapidjson::kStringType);
string key = "CipherSuite";
iKey.SetString(key.c_str(), allocator);
value.AddMember(iKey, rapidjson::Value(m_cipherSuite.c_str(), allocator).Move(), allocator);
}
}
string Https::GetHttp2() const
{
return m_http2;
}
void Https::SetHttp2(const string& _http2)
{
m_http2 = _http2;
m_http2HasBeenSet = true;
}
bool Https::Http2HasBeenSet() const
{
return m_http2HasBeenSet;
}
string Https::GetOcspStapling() const
{
return m_ocspStapling;
}
void Https::SetOcspStapling(const string& _ocspStapling)
{
m_ocspStapling = _ocspStapling;
m_ocspStaplingHasBeenSet = true;
}
bool Https::OcspStaplingHasBeenSet() const
{
return m_ocspStaplingHasBeenSet;
}
vector<string> Https::GetTlsVersion() const
{
return m_tlsVersion;
}
void Https::SetTlsVersion(const vector<string>& _tlsVersion)
{
m_tlsVersion = _tlsVersion;
m_tlsVersionHasBeenSet = true;
}
bool Https::TlsVersionHasBeenSet() const
{
return m_tlsVersionHasBeenSet;
}
Hsts Https::GetHsts() const
{
return m_hsts;
}
void Https::SetHsts(const Hsts& _hsts)
{
m_hsts = _hsts;
m_hstsHasBeenSet = true;
}
bool Https::HstsHasBeenSet() const
{
return m_hstsHasBeenSet;
}
vector<ServerCertInfo> Https::GetCertInfo() const
{
return m_certInfo;
}
void Https::SetCertInfo(const vector<ServerCertInfo>& _certInfo)
{
m_certInfo = _certInfo;
m_certInfoHasBeenSet = true;
}
bool Https::CertInfoHasBeenSet() const
{
return m_certInfoHasBeenSet;
}
string Https::GetApplyType() const
{
return m_applyType;
}
void Https::SetApplyType(const string& _applyType)
{
m_applyType = _applyType;
m_applyTypeHasBeenSet = true;
}
bool Https::ApplyTypeHasBeenSet() const
{
return m_applyTypeHasBeenSet;
}
string Https::GetCipherSuite() const
{
return m_cipherSuite;
}
void Https::SetCipherSuite(const string& _cipherSuite)
{
m_cipherSuite = _cipherSuite;
m_cipherSuiteHasBeenSet = true;
}
bool Https::CipherSuiteHasBeenSet() const
{
return m_cipherSuiteHasBeenSet;
}
| [
"[email protected]"
] | |
bc7aea90a50e747241a13ab10ac9a921117f7ccd | 84c6ab2471abe98ba15f7635200aa40c2649a4fe | /line_following_robot.ino | 0577c496b4c8f46fa0e20d7e7e5578b5bca01e95 | [] | no_license | mak8888/UNII_PROJECTS | 3fbf609cf5ca3ea8154662cafee597da727edaac | 695497aab4f39a4aaa7bae45a05f0ff5de837bc4 | refs/heads/master | 2020-03-23T15:31:03.503054 | 2018-12-17T00:17:06 | 2018-12-17T00:17:06 | 141,753,737 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 1,239 | ino | //Arduino Line Follower Code
/*-------definning Inputs------*/
#define LS 2 // left sensor
#define RS 3 // right sensor
/*-------definning Outputs------*/
#define LM1 4 // left motor
#define LM2 5 // left motor
#define RM1 6 // right motor
#define RM2 7 // right motor
void setup()
{
//declaring pinmode
pinMode(LS, INPUT);
pinMode(RS, INPUT);
pinMode(LM1, OUTPUT);
pinMode(LM2, OUTPUT);
pinMode(RM1, OUTPUT);
pinMode(RM2, OUTPUT);
}
void loop()
{
if(digitalRead(LS) && digitalRead(RS)) // Move Forward
{
digitalWrite(LM1, HIGH);
digitalWrite(LM2, LOW);
digitalWrite(RM1, HIGH);
digitalWrite(RM2, LOW);
}
if(!(digitalRead(LS)) && digitalRead(RS)) // Turn right
{
digitalWrite(LM1, LOW);
digitalWrite(LM2, LOW);
digitalWrite(RM1, HIGH);
digitalWrite(RM2, LOW);
}
if(digitalRead(LS) && !(digitalRead(RS))) // turn left
{
digitalWrite(LM1, HIGH);
digitalWrite(LM2, LOW);
digitalWrite(RM1, LOW);
digitalWrite(RM2, LOW);
}
if(!(digitalRead(LS)) && !(digitalRead(RS))) // stop
{
digitalWrite(LM1, LOW);
digitalWrite(LM2, LOW);
digitalWrite(RM1, LOW);
digitalWrite(RM2, LOW);
}
}
| [
"[email protected]"
] | |
b3b75f47ea489f196ffd89d5f286e43e0c435fa4 | eb43dfffd3a353acbe57b76d3a0e89754773825a | /validate_binary_search_tree.cpp | be57fbeec7d4a8a200a3cf79dd829214da5b876e | [] | no_license | deekookee/lintcode | d85a2bac0df10fe70ae3b755f8b9dc07d7fb90ad | f3e9ce5f981851872492ad48c86e8179824778c2 | refs/heads/master | 2021-01-15T23:50:11.831424 | 2016-01-05T04:47:54 | 2016-01-05T04:47:54 | 32,809,299 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 828 | cpp | /**
* Definition of TreeNode:
* class TreeNode {
* public:
* int val;
* TreeNode *left, *right;
* TreeNode(int val) {
* this->val = val;
* this->left = this->right = NULL;
* }
* }
*/
class Solution {
public:
/**
* @param root: The root of binary tree.
* @return: True if the binary tree is BST, or false
*/
bool isValidBST(TreeNode *root) {
// write your code here
if (root == NULL) {
return true;
}
if (root->left != NULL && root->val <= root->left->val) {
return false;
}
if (root->right != NULL && root->val >= root->right->val) {
return false;
}
return isValidBST(root->left) && isValidBST(root->right);
}
};
| [
"[email protected]"
] | |
d79564734d4232c2285457ed33a8fdc8c1d25f9c | 857de7d2b0a4d5eb7627cf71cde56371754da751 | /include/bx/inline/mutex.inl | d17855ad923a47fe5a1b1b13f5fa602e73e7d339 | [
"BSD-2-Clause",
"LicenseRef-scancode-free-unknown"
] | permissive | bkaradzic/bx | b8f1de65eb9e32efb46f53a3d7ee23c433b52622 | 198cd120e4941d8aeb677db945ef4291a1ced291 | refs/heads/master | 2023-08-17T22:28:13.507632 | 2023-07-30T17:16:30 | 2023-07-30T17:16:30 | 3,925,157 | 492 | 528 | BSD-2-Clause | 2023-09-04T16:46:05 | 2012-04-04T03:22:13 | C++ | UTF-8 | C++ | false | false | 431 | inl | /*
* Copyright 2010-2023 Branimir Karadzic. All rights reserved.
* License: https://github.com/bkaradzic/bx/blob/master/LICENSE
*/
#ifndef BX_MUTEX_H_HEADER_GUARD
# error "Must be included from bx/mutex.h!"
#endif // BX_MUTEX_H_HEADER_GUARD
namespace bx
{
inline MutexScope::MutexScope(Mutex& _mutex)
: m_mutex(_mutex)
{
m_mutex.lock();
}
inline MutexScope::~MutexScope()
{
m_mutex.unlock();
}
} // namespace bx
| [
"[email protected]"
] | |
885c4625c80194e65130703d9ac6a9c4f1b0f26e | 147173f34c70f7a430f23bd37f053c1199eaee50 | /src/xalanc/XercesParserLiaison/XercesLiaisonXalanDOMStringPool.cpp | 29e844db3b6e5aab24e7e6b19b7c77a756f31152 | [
"Apache-2.0"
] | permissive | rherardi/xml-xalan-c-src_1_10_0 | d9d741f9a962e0071f1c493cf33bddf58fec8264 | 24e6653a617a244e4def60d67b57e70a192a5d4d | refs/heads/master | 2020-06-06T05:18:17.933866 | 2015-05-12T07:49:55 | 2015-05-12T07:49:55 | 35,316,186 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 2,240 | cpp | /*
* Copyright 1999-2004 The Apache Software Foundation.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
// Class header file...
#include "XercesLiaisonXalanDOMStringPool.hpp"
XALAN_CPP_NAMESPACE_BEGIN
XercesLiaisonXalanDOMStringPool::XercesLiaisonXalanDOMStringPool(MemoryManagerType& theManager) :
ParentType(theManager),
m_mutex()
{
}
XercesLiaisonXalanDOMStringPool*
XercesLiaisonXalanDOMStringPool:: create(MemoryManagerType& theManager)
{
typedef XercesLiaisonXalanDOMStringPool ThisType;
XalanMemMgrAutoPtr<ThisType, false> theGuard( theManager , (ThisType*)theManager.allocate(sizeof(ThisType)));
ThisType* theResult = theGuard.get();
new (theResult) ThisType(theManager);
theGuard.release();
return theResult;
}
XercesLiaisonXalanDOMStringPool::~XercesLiaisonXalanDOMStringPool()
{
}
void
XercesLiaisonXalanDOMStringPool::clear()
{
XMLMutexLockType theLock(&m_mutex);
ParentType::clear();
}
size_t
XercesLiaisonXalanDOMStringPool::size() const
{
#if defined(XALAN_NO_MUTABLE)
XMLMutexLockType theLock(&((XercesLiaisonXalanDOMStringPool*)this)->m_mutex);
#else
XMLMutexLockType theLock(&m_mutex);
#endif
return ParentType::size();
}
const XalanDOMString&
XercesLiaisonXalanDOMStringPool::get(const XalanDOMString& theString)
{
XMLMutexLockType theLock(&m_mutex);
return ParentType::get(theString);
}
const XalanDOMString&
XercesLiaisonXalanDOMStringPool::get(
const XalanDOMChar* theString,
XalanDOMString::size_type theLength)
{
XMLMutexLockType theLock(&m_mutex);
return ParentType::get(theString, theLength);
}
XALAN_CPP_NAMESPACE_END
| [
"[email protected]"
] | |
8073bcd42ba6e5d2323c8a07a85098429cb3d982 | f485dad122e8f8cc9225584890b9b51673c14a13 | /utility.hxx | af833d3c09472d1a9cfe73504f91872a0e189cc9 | [] | no_license | m-renaud/cxx-utils | c48a5d638ae0a58024e312e79593cd0d4423ee2e | b9d9ae3febed361dc82cfb73dde0e52d722654f0 | refs/heads/master | 2020-04-10T00:50:30.176736 | 2013-07-25T15:12:22 | 2013-07-25T15:12:22 | 5,664,546 | 1 | 1 | null | null | null | null | UTF-8 | C++ | false | false | 1,087 | hxx | #ifndef MRR_CXX_UTILS_UTILITLY_HXX_
#define MRR_CXX_UTILS_UTILITLY_HXX_
#include <ios>
#include <sstream>
//m=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
namespace mrr {
//=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
template <typename T, typename Char, typename Traits>
auto discard(std::basic_istream<Char,Traits>& is)
-> std::basic_istream<Char,Traits>&
{
T t;
is >> t;
return is;
}
template <typename T>
std::string to_string(T const& t)
{
std::stringstream ss;
ss << t;
return ss.str();
}
template <typename Ch, typename Tr>
std::basic_istream<Ch,Tr>& discard_input(std::basic_istream<Ch,Tr>& is)
{
std::streamsize const available_chars = is.rdbuf()->in_avail();
if (available_chars > 0)
for (std::streamsize pos = 0; pos != available_chars; ++pos)
is.get();
return is;
}
//m=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
} // namespace mrr
//=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
#endif // MRR_CXX_UTILS_UTILITLY_HXX_
| [
"[email protected]"
] | |
27aa3232cd65ee3e652912d58c036ff14e43f252 | c5bed7c3300f0e25f6e6ca32b01cfcf74c0199b6 | /include/ideoengine/collector/OutputCollector.h | e30346bc4a0a16e00fdc04ff99ad63a9b8a1cf3f | [] | no_license | LeonLee8Hang/IdeoEngine | cdbcf80972ac0f07c545bc97ca77d9f9aed68a82 | 29f741a6373f41028156204ac5d6ab0e97f37145 | refs/heads/main | 2023-03-01T19:25:06.893878 | 2021-02-08T16:34:11 | 2021-02-08T16:34:11 | 337,065,523 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 645 | h |
#pragma once
#include <memory>
#include <string>
namespace ideoengine {
namespace base {
class Tuple;
}
namespace collector {
class OutputQueue;
class OutputCollector {
public:
OutputCollector();
OutputCollector(int32_t taskIndex, const std::string& taskName, std::shared_ptr<OutputQueue> queue);
void SetQueue(std::shared_ptr<OutputQueue> queue) {
_queue = queue;
}
std::shared_ptr<OutputQueue> GetQueue() const {
return _queue;
}
void Emit(const ideoengine::base::Tuple& tuple);
private:
int32_t _taskIndex;
std::string _taskName;
std::shared_ptr<OutputQueue> _queue;
};
}
}
| [
"[email protected]"
] | |
714577fa0bcfa51e0ea4dfe3dff6b915d8ac4ddd | b9bc60cca34c6b4f8a750af6062f357f18dfcae2 | /tensorflow/core/common_runtime/function.cc | 2d29f5176d03cb884e293edf5d1908d56e89d8ce | [
"Apache-2.0"
] | permissive | lidenghui1110/tensorflow-0.12.0-fpga | 7c96753aafab5fe79d5d0c500a0bae1251a3d21b | f536d3d0b91f7f07f8e4a3978d362cd21bad832c | refs/heads/master | 2022-11-20T11:42:11.461490 | 2017-07-28T09:28:37 | 2017-07-28T09:28:37 | 98,633,565 | 3 | 2 | Apache-2.0 | 2022-11-15T05:22:07 | 2017-07-28T09:29:01 | C++ | UTF-8 | C++ | false | false | 40,274 | cc | /* Copyright 2015 The TensorFlow Authors. All Rights Reserved.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
==============================================================================*/
#include "tensorflow/core/common_runtime/function.h"
#include <deque>
#include <vector>
#include "tensorflow/core/common_runtime/device.h"
#include "tensorflow/core/common_runtime/executor.h"
#include "tensorflow/core/common_runtime/graph_optimizer.h"
#include "tensorflow/core/common_runtime/memory_types.h"
#include "tensorflow/core/common_runtime/rendezvous_mgr.h"
#include "tensorflow/core/framework/function.h"
#include "tensorflow/core/framework/node_def_util.h"
#include "tensorflow/core/framework/op.h"
#include "tensorflow/core/framework/op_kernel.h"
#include "tensorflow/core/graph/algorithm.h"
#include "tensorflow/core/graph/gradients.h"
#include "tensorflow/core/graph/graph_constructor.h"
#include "tensorflow/core/graph/optimizer_cse.h"
#include "tensorflow/core/lib/gtl/map_util.h"
#include "tensorflow/core/platform/macros.h"
// See core/kernels/function_ops.cc for related kernels.
namespace tensorflow {
// A few string constant used throughout this module.
//
// TODO(zhifengc): Dedup some of these constants into
// framework/function.h
static constexpr const char* const kArgOp = "_Arg";
static constexpr const char* const kRetOp = "_Retval";
static constexpr const char* const kGradientOp =
FunctionLibraryDefinition::kGradientOp;
static constexpr const char* const kNodeLabel = "Func";
static constexpr const char* const kFuncAttr =
FunctionLibraryDefinition::kFuncAttr;
static constexpr const char* const kNoInlineAttr = "_noinline";
// Represents the index-th output of a node.
struct Endpoint {
Node* node;
int index;
// Returns the string name represents this endpoint.
string name() const {
if (index == 0) {
return node->name();
} else {
return strings::StrCat(node->name(), ":", index);
}
}
DataType dtype() const { return node->output_type(index); }
};
struct EndpointHash {
uint64 operator()(const Endpoint& x) const {
return Hash64(reinterpret_cast<const char*>(&x.node), sizeof(Node*),
x.index);
}
};
struct EndpointEq {
bool operator()(const Endpoint& x, const Endpoint& y) const {
return (x.node == y.node) && (x.index == y.index);
}
};
// The following Add* routines are used to add a few graph nodes while
// functions are transformed.
static Node* AddNoOp(Graph* g) {
NodeDef ndef;
ndef.set_name(g->NewName(kNodeLabel));
ndef.set_op("NoOp");
Status s;
Node* ret = g->AddNode(ndef, &s);
TF_CHECK_OK(s);
return ret;
}
static Node* AddIdentity(Graph* g, Endpoint input) {
DCHECK_LT(0, input.dtype());
DCHECK_LT(input.dtype(), DT_FLOAT_REF);
NodeDef ndef;
ndef.set_name(g->NewName(kNodeLabel));
ndef.set_op("Identity");
ndef.add_input(input.name());
AddNodeAttr("T", input.dtype(), &ndef);
Status s;
Node* ret = g->AddNode(ndef, &s);
TF_CHECK_OK(s);
g->AddEdge(input.node, input.index, ret, 0);
return ret;
}
static Node* AddArg(Graph* g, DataType dtype, int index) {
DCHECK_LT(0, dtype);
DCHECK_LT(dtype, DT_FLOAT_REF);
NodeDef ndef;
ndef.set_name(g->NewName(kNodeLabel));
ndef.set_op(kArgOp);
AddNodeAttr("T", dtype, &ndef);
AddNodeAttr("index", index, &ndef);
Status s;
Node* ret = g->AddNode(ndef, &s);
TF_CHECK_OK(s);
return ret;
}
static Node* AddRet(Graph* g, Endpoint input, int index) {
DCHECK_LT(0, input.dtype());
DCHECK_LT(input.dtype(), DT_FLOAT_REF);
NodeDef ndef;
ndef.set_name(g->NewName(kNodeLabel));
ndef.set_op(kRetOp);
ndef.add_input(input.name());
AddNodeAttr("T", input.dtype(), &ndef);
AddNodeAttr("index", index, &ndef);
Status s;
Node* ret = g->AddNode(ndef, &s);
TF_CHECK_OK(s);
g->AddEdge(input.node, input.index, ret, 0);
return ret;
}
static const FunctionLibraryRuntime::Handle kInvalidHandle = -1;
class FunctionLibraryRuntimeImpl : public FunctionLibraryRuntime {
public:
FunctionLibraryRuntimeImpl(const DeviceMgr* dmgr, Env* env, Device* device,
int graph_def_version,
const FunctionLibraryDefinition* lib_def,
const OptimizerOptions& optimizer_options,
CustomKernelCreator custom_kernel_creator);
~FunctionLibraryRuntimeImpl() override;
Status Instantiate(const string& function_name,
const InstantiateAttrValueMap& attrs,
Handle* handle) override;
const FunctionBody* GetFunctionBody(Handle handle) override;
Status CreateKernel(const NodeDef& ndef, OpKernel** kernel) override;
void Run(const Options& opts, Handle handle, gtl::ArraySlice<Tensor> args,
std::vector<Tensor>* rets, DoneCallback done) override;
bool IsStateful(const string& function) override;
const FunctionLibraryDefinition* GetFunctionLibraryDefinition()
const override {
return lib_def_;
}
Device* device() override { return device_; }
Env* env() override { return env_; }
int graph_def_version() override { return graph_def_version_; }
string DebugString(Handle h) override;
private:
typedef FunctionLibraryRuntimeImpl ME;
const DeviceMgr* const device_mgr_;
Device* const device_;
Env* const env_;
const int graph_def_version_;
const FunctionLibraryDefinition* const lib_def_;
GraphOptimizer optimizer_;
const CustomKernelCreator custom_kernel_creator_;
std::function<Status(const string&, const OpDef**)> get_func_sig_;
std::function<Status(const NodeDef&, OpKernel**)> create_kernel_;
mutable mutex mu_;
// Maps function instantiation to a handle. The key is a
// canonicalized representation of the function name and
// instantiation attrs. The handle is an index into the items_.
std::unordered_map<string, Handle> table_ GUARDED_BY(mu_);
// func_graphs_ never shrinks or reorders its members.
std::vector<FunctionBody*> func_graphs_ GUARDED_BY(mu_);
// The instantiated and transformed function is encoded as a Graph
// object, and an executor is created for the graph.
struct Item : public core::RefCounted {
const Graph* graph = nullptr; // Owned by exec.
Executor* exec = nullptr;
~Item() override { delete this->exec; }
};
std::vector<Item*> items_;
Status FunctionDefToBody(const FunctionDef& fdef,
const InstantiateAttrValueMap& attrs,
FunctionBody** fbody);
Status CreateItem(Handle handle, Item** item);
Status GetOrCreateItem(Handle handle, Item** item);
Status InstantiateSymbolicGradient(const NameAttrList& func,
FunctionBody** g_body);
TF_DISALLOW_COPY_AND_ASSIGN(FunctionLibraryRuntimeImpl);
};
FunctionLibraryRuntimeImpl::FunctionLibraryRuntimeImpl(
const DeviceMgr* dmgr, Env* env, Device* device, int graph_def_version,
const FunctionLibraryDefinition* lib_def,
const OptimizerOptions& optimizer_options,
CustomKernelCreator custom_kernel_creator)
: device_mgr_(dmgr),
device_(device),
env_(env),
graph_def_version_(graph_def_version),
lib_def_(lib_def),
optimizer_(optimizer_options),
custom_kernel_creator_(std::move(custom_kernel_creator)) {
get_func_sig_ = [this](const string& op, const OpDef** sig) {
return lib_def_->LookUpOpDef(op, sig);
};
create_kernel_ = [this](const NodeDef& ndef, OpKernel** kernel) {
return CreateKernel(ndef, kernel);
};
}
FunctionLibraryRuntimeImpl::~FunctionLibraryRuntimeImpl() {
for (FunctionBody* p : func_graphs_) delete p;
for (Item* item : items_)
if (item) item->Unref();
}
// An asynchronous op kernel which executes an instantiated function
// defined in a library.
class CallOp : public AsyncOpKernel {
public:
CallOp(FunctionLibraryRuntime::Handle handle, OpKernelConstruction* ctx)
: AsyncOpKernel(ctx), handle_(handle) {}
~CallOp() override {}
void ComputeAsync(OpKernelContext* ctx, DoneCallback done) override {
FunctionLibraryRuntime* lib = ctx->function_library();
OP_REQUIRES_ASYNC(ctx, lib != nullptr,
errors::Internal("No function library is provided."),
done);
FunctionLibraryRuntime::Options opts;
opts.step_id = ctx->step_id();
opts.step_resource_manager = ctx->step_resource_manager();
opts.runner = ctx->runner();
std::vector<Tensor> args;
args.reserve(ctx->num_inputs());
for (int i = 0; i < ctx->num_inputs(); ++i) {
args.push_back(ctx->input(i));
}
std::vector<Tensor>* rets = new std::vector<Tensor>;
lib->Run(opts, handle_, args, rets,
[ctx, done, rets](const Status& status) {
if (!status.ok()) {
ctx->SetStatus(status);
} else {
CHECK_EQ(rets->size(), ctx->num_outputs());
for (size_t i = 0; i < rets->size(); ++i) {
ctx->set_output(i, (*rets)[i]);
}
}
delete rets;
done();
});
}
private:
FunctionLibraryRuntime::Handle handle_;
TF_DISALLOW_COPY_AND_ASSIGN(CallOp);
};
const FunctionBody* FunctionLibraryRuntimeImpl::GetFunctionBody(Handle h) {
mutex_lock l(mu_);
CHECK_LE(static_cast<Handle>(0), h);
CHECK_LT(h, func_graphs_.size());
return func_graphs_[h];
}
Status FunctionLibraryRuntimeImpl::CreateKernel(const NodeDef& ndef,
OpKernel** kernel) {
// If a custom kernel creator is given, try that.
Status s;
if (custom_kernel_creator_) {
std::unique_ptr<OpKernel> ret;
s = custom_kernel_creator_(this, ndef, &ret);
if (s.ok()) {
*kernel = ret.release();
return s;
} else {
VLOG(2) << "Custom creator error: " << s;
// Falls through.
s = Status::OK();
}
}
if (lib_def_->Find(ndef.op()) == nullptr) {
// A primitive operation. Creates the registered kernel.
return CreateNonCachedKernel(device_, this, ndef, graph_def_version_,
kernel);
}
// Try to instantiate this function for the func/attr. Maybe its
// cached already.
Handle handle;
TF_RETURN_IF_ERROR(Instantiate(ndef.op(), ndef.attr(), &handle));
const FunctionBody* fbody = GetFunctionBody(handle);
CHECK_NOTNULL(fbody);
// TODO(zhifengc): For now, we assume int32 is always on host memory
// and other types are always on device memory. We should do type
// inference over function body to derive the correct input/output
// memory types.
MemoryTypeVector input_memory_types;
for (const auto& t : fbody->arg_types) {
input_memory_types.push_back(t == DT_INT32 ? HOST_MEMORY : DEVICE_MEMORY);
}
MemoryTypeVector output_memory_types;
for (const auto& t : fbody->ret_types) {
output_memory_types.push_back(t == DT_INT32 ? HOST_MEMORY : DEVICE_MEMORY);
}
// Constructs a CallOp kernel for running the instantiated function.
auto device_type = DeviceType(device_->attributes().device_type());
OpKernelConstruction construction(
device_type, device_, device_->GetAllocator(AllocatorAttributes()), &ndef,
&fbody->fdef.signature(), this, fbody->arg_types, input_memory_types,
fbody->ret_types, output_memory_types, graph_def_version_, &s);
*kernel = new CallOp(handle, &construction);
if (!s.ok()) {
delete *kernel;
}
return s;
}
Status FunctionLibraryRuntimeImpl::FunctionDefToBody(
const FunctionDef& fdef, const InstantiateAttrValueMap& attrs,
FunctionBody** fbody) {
// Instantiates the function template into a graph def.
InstantiationResult result;
TF_RETURN_IF_ERROR(InstantiateFunction(fdef, attrs, get_func_sig_, &result));
Graph* graph = new Graph(lib_def_);
GraphConstructorOptions opts;
opts.allow_internal_ops = true;
opts.expect_device_spec = false;
Status s = ConvertGraphDefToGraph(opts, result.gdef, graph);
if (!s.ok()) {
delete graph;
} else {
*fbody = new FunctionBody(fdef, result.arg_types, result.ret_types, graph);
}
return s;
}
Status FunctionLibraryRuntimeImpl::InstantiateSymbolicGradient(
const NameAttrList& func, FunctionBody** g_body) {
const FunctionDef* fdef = lib_def_->Find(func.name());
if (fdef == nullptr) {
// f is a primitive op.
gradient::Creator creator;
TF_RETURN_IF_ERROR(gradient::GetOpGradientCreator(func.name(), &creator));
if (creator == nullptr) {
return errors::InvalidArgument("No gradient is defined for ",
func.name());
}
FunctionDef grad_fdef;
// TODO(josh11b): Should filter out the attrs from func that aren't used
// by the gradient function.
TF_RETURN_IF_ERROR(creator(AttrSlice(&func.attr()), &grad_fdef));
TF_RETURN_IF_ERROR(FunctionDefToBody(grad_fdef, func.attr(), g_body));
} else {
// f is a user-defined function.
Handle f_handle;
TF_RETURN_IF_ERROR(Instantiate(func.name(), func.attr(), &f_handle));
const FunctionBody* f_body = GetFunctionBody(f_handle);
CHECK_NOTNULL(f_body);
*g_body = SymbolicGradient(*f_body);
}
return Status::OK();
}
Status FunctionLibraryRuntimeImpl::Instantiate(
const string& function_name, const InstantiateAttrValueMap& attrs,
Handle* handle) {
const string key = Canonicalize(function_name, attrs);
{
mutex_lock l(mu_);
*handle = gtl::FindWithDefault(table_, key, kInvalidHandle);
if (*handle != kInvalidHandle) {
return Status::OK();
}
}
Status s;
FunctionBody* fbody = nullptr;
if (function_name == kGradientOp) {
const AttrValue* f = gtl::FindOrNull(attrs, kFuncAttr);
if (f == nullptr) {
return errors::InvalidArgument("SymbolicGradient is missing attr: f");
}
const auto& func = f->func();
if (func.name() == kGradientOp) {
return errors::InvalidArgument("Can't take gradient of SymbolicGradient");
}
const string grad = lib_def_->FindGradient(func.name());
if (!grad.empty()) {
return Instantiate(grad, func.attr(), handle);
}
TF_RETURN_IF_ERROR(InstantiateSymbolicGradient(func, &fbody));
} else {
const FunctionDef* fdef = lib_def_->Find(function_name);
if (fdef == nullptr) {
return errors::NotFound("Function ", function_name, " is not defined.");
}
TF_RETURN_IF_ERROR(FunctionDefToBody(*fdef, attrs, &fbody));
}
{
mutex_lock l(mu_);
*handle = gtl::FindWithDefault(table_, key, kInvalidHandle);
if (*handle != kInvalidHandle) {
delete fbody;
} else {
*handle = func_graphs_.size();
table_.insert({key, *handle});
func_graphs_.push_back(fbody);
items_.resize(func_graphs_.size());
}
}
return Status::OK();
}
void DumpGraph(StringPiece label, const Graph* g) {
// TODO(zhifengc): Change Graph to record #nodes.
VLOG(1) << "Graph " << label << " #nodes " << g->num_nodes() << " #edges "
<< g->edges().size();
if (VLOG_IS_ON(2)) {
for (const auto& line : str_util::Split(DebugString(g), '\n')) {
VLOG(2) << "|| " << line;
}
}
}
void OptimizeGraph(FunctionLibraryRuntime* lib, Graph** g) {
OptimizerOptions opts;
opts.set_do_common_subexpression_elimination(true);
opts.set_do_function_inlining(true);
opts.set_do_constant_folding(true);
GraphOptimizer optimizer(opts);
optimizer.Optimize(lib, lib->env(), lib->device(), g);
}
Status FunctionLibraryRuntimeImpl::CreateItem(Handle handle, Item** item) {
const FunctionBody* fbody = GetFunctionBody(handle);
CHECK_NOTNULL(fbody);
Graph* g = new Graph(lib_def_);
CopyGraph(*fbody->graph, g);
optimizer_.Optimize(this, env(), device(), &g);
auto s = EnsureMemoryTypes(DeviceType(device()->device_type()),
device()->name(), g);
if (!s.ok()) {
delete g;
return Status::OK();
}
// Creates an executor based on the g. This must be done without
// holding mu_ because create_kernel_ calls back into the library.
LocalExecutorParams params;
params.device = device_;
params.function_library = this;
params.create_kernel = create_kernel_;
params.delete_kernel = [](OpKernel* kernel) {
DeleteNonCachedKernel(kernel);
};
Executor* exec;
TF_RETURN_IF_ERROR(NewLocalExecutor(params, g, &exec));
*item = new Item;
(*item)->graph = g;
(*item)->exec = exec;
return Status::OK();
}
Status FunctionLibraryRuntimeImpl::GetOrCreateItem(Handle handle, Item** item) {
{
mutex_lock l(mu_);
if (handle >= items_.size()) {
return errors::NotFound("Function handle ", handle,
" is not valid. Likely an internal error.");
}
*item = items_[handle];
if (*item != nullptr) {
(*item)->Ref();
return Status::OK();
}
}
// NOTE: We need to call CreateItem out of mu_ because creating an
// executor needs to call CreateKernel.
TF_RETURN_IF_ERROR(CreateItem(handle, item));
{
mutex_lock l(mu_);
if (items_[handle] == nullptr) {
// Install *item in items_.
items_[handle] = *item;
(*item)->Ref();
}
}
return Status::OK();
}
void FunctionLibraryRuntimeImpl::Run(const Options& opts, Handle handle,
gtl::ArraySlice<Tensor> args,
std::vector<Tensor>* rets,
DoneCallback done) {
if (opts.cancellation_manager && opts.cancellation_manager->IsCancelled()) {
return done(errors::Cancelled(""));
}
const FunctionBody* fbody = GetFunctionBody(handle);
FunctionCallFrame* frame =
new FunctionCallFrame(fbody->arg_types, fbody->ret_types);
Status s = frame->SetArgs(args);
if (!s.ok()) {
delete frame;
return done(s);
}
Item* item = nullptr;
s = GetOrCreateItem(handle, &item);
if (!s.ok()) {
delete frame;
return done(s);
}
DCHECK(opts.runner != nullptr);
Executor::Args exec_args;
// Inherit the step_id from the caller.
exec_args.step_id = opts.step_id;
exec_args.step_resource_manager = opts.step_resource_manager;
exec_args.call_frame = frame;
exec_args.cancellation_manager = opts.cancellation_manager;
exec_args.runner = *opts.runner;
// TODO(zhifengc): we can avoid creating rendez here if we know
// there is no send/recv nodes in the graph.
auto* rendez = new IntraProcessRendezvous(device_mgr_);
exec_args.rendezvous = rendez;
item->exec->RunAsync(
// Executor args
exec_args,
// Done callback.
[item, frame, rets, rendez, done](const Status& status) {
item->Unref();
rendez->Unref();
Status s = status;
if (s.ok()) {
s = frame->GetRetvals(rets);
}
delete frame;
done(s);
});
}
bool FunctionLibraryRuntimeImpl::IsStateful(const string& func) {
const OpDef* op_def;
const Status s = lib_def_->LookUpOpDef(func, &op_def);
return s.ok() && op_def->is_stateful();
}
string FunctionLibraryRuntimeImpl::DebugString(Handle handle) {
Item* item = nullptr;
Status s = GetOrCreateItem(handle, &item);
if (s.ok()) {
return tensorflow::DebugString(item->graph);
} else {
return s.ToString();
}
}
namespace {
struct CustomCreatorSingleton {
mutex mu;
CustomKernelCreator custom_creator = nullptr;
void Set(CustomKernelCreator cb) {
mutex_lock l(mu);
custom_creator = cb;
}
CustomKernelCreator Get() {
mutex_lock l(mu);
return custom_creator;
}
};
CustomCreatorSingleton* GetCustomCreatorSingleton() {
static CustomCreatorSingleton* ccs = new CustomCreatorSingleton;
return ccs;
}
} // end namespace
void RegisterDefaultCustomKernelCreator(CustomKernelCreator cb) {
GetCustomCreatorSingleton()->Set(cb);
}
FunctionLibraryRuntime* NewFunctionLibraryRuntime(
const DeviceMgr* dmgr, Env* env, Device* device, int graph_def_version,
const FunctionLibraryDefinition* lib_def,
const OptimizerOptions& optimizer_options,
CustomKernelCreator custom_kernel_creator) {
return new FunctionLibraryRuntimeImpl(dmgr, env, device, graph_def_version,
lib_def, optimizer_options,
custom_kernel_creator);
}
FunctionLibraryRuntime* NewFunctionLibraryRuntime(
const DeviceMgr* dmgr, Env* env, Device* device, int graph_def_version,
const FunctionLibraryDefinition* lib_def,
const OptimizerOptions& optimizer_options) {
return NewFunctionLibraryRuntime(dmgr, env, device, graph_def_version,
lib_def, optimizer_options,
GetCustomCreatorSingleton()->Get());
}
bool RemoveDeadNodes(Graph* g) {
VLOG(2) << "Removing dead nodes";
std::unordered_set<const Node*> nodes;
for (auto n : g->nodes()) {
if (n->IsSource() || n->IsSink() || n->IsControlFlow() ||
n->op_def().is_stateful()) {
nodes.insert(n);
}
}
return PruneForReverseReachability(g, std::move(nodes));
}
namespace {
// If 'edges' contains only 1 non-control edge, returns it. Otherwise,
// returns a nullptr.
const Edge* GetTheOnlyDataEdge(const EdgeSet& edges) {
const Edge* ret = nullptr;
for (const Edge* e : edges) {
if (e->IsControlEdge() || ret) {
// Don't touch it if there is a control edge.
return nullptr;
}
if (IsRefType(e->src()->output_type(e->src_output()))) {
// Don't touch it if the identity node is effectively de-reffing
// a ref.
return nullptr;
}
ret = e;
}
return ret;
}
} // end namespace
bool RemoveIdentityNodes(Graph* g) {
VLOG(2) << "Removing identity nodes";
bool removed_any = false;
gtl::InlinedVector<Node*, 8> matches;
for (Node* n : g->nodes()) {
if (n->IsIdentity() && GetTheOnlyDataEdge(n->in_edges())) {
matches.push_back(n);
}
}
if (!matches.empty()) {
for (Node* n : matches) {
const Edge* in = GetTheOnlyDataEdge(n->in_edges());
for (const Edge* out : n->out_edges()) {
if (out->IsControlEdge()) {
g->AddControlEdge(in->src(), out->dst());
} else {
g->AddEdge(in->src(), in->src_output(), out->dst(), out->dst_input());
}
}
VLOG(2) << "Remove Identity: " << n->DebugString();
g->RemoveNode(n);
removed_any = true;
}
}
return removed_any;
}
bool RemoveListArrayConverter(Graph* g) {
VLOG(2) << "Removing list array converter";
gtl::InlinedVector<Node*, 8> matches;
for (Node* n : g->nodes()) {
if ((n->type_string() == "_ListToArray") ||
(n->type_string() == "_ArrayToList")) {
matches.push_back(n);
}
}
bool removed_any = false;
if (!matches.empty()) {
for (Node* n : matches) {
if (n->num_inputs() != n->num_outputs()) {
continue; // Not expected. Skip.
}
gtl::InlinedVector<Node*, 8> identity_nodes(n->num_inputs(), nullptr);
// Process input edges first.
Node* input_control_node = nullptr;
for (const Edge* e : n->in_edges()) {
if (e->IsControlEdge()) {
if (input_control_node == nullptr) {
// If node "n" has any control dependencies, adds a no-op
// node (input_control_node) which the additional Identity
// nodes depends on and the input_control_node depends on
// the node "n"s control dependencies.
input_control_node = AddNoOp(g);
}
g->AddControlEdge(e->src(), input_control_node);
} else {
const int index = e->dst_input();
Node** id_node = &identity_nodes[index];
if (*id_node != nullptr) {
LOG(ERROR)
<< "RemoveListArrayConverter unexpected duplicated input: "
<< e->dst_input();
return removed_any;
}
*id_node = AddIdentity(g, {e->src(), e->src_output()});
}
}
// If node "n" has any control dependencies, the added identity
// nodes should have control dependencies on input_control_node.
if (input_control_node != nullptr) {
for (Node* id : identity_nodes) {
g->AddControlEdge(input_control_node, id);
}
}
Node* output_control_node = nullptr;
for (const Edge* e : n->out_edges()) {
if (e->IsControlEdge()) {
if (output_control_node == nullptr) {
// If node "n" is control-depended upon by other nodes,
// adds a no-op node (output_control_node) which those
// nodes will depend on and output_control_node depends on
// all Identity nodes.
output_control_node = AddNoOp(g);
}
g->AddControlEdge(output_control_node, e->dst());
} else {
Node* id_node = identity_nodes[e->src_output()];
if (id_node == nullptr) {
LOG(ERROR) << "RemoveListArrayConverter unexpected missing input: "
<< e->src_output();
return removed_any;
}
CHECK(id_node);
g->AddEdge(id_node, 0, e->dst(), e->dst_input());
}
}
// If any nodes have control dependencies on node "n", those
// nodes should have control dependencies on
// output_control_node.
if (output_control_node != nullptr) {
for (Node* id : identity_nodes) {
g->AddControlEdge(id, output_control_node);
}
}
g->RemoveNode(n);
removed_any = true;
}
}
return removed_any;
}
// Returns true iff the function '*fbody' can be inlined at 'node'
// based on the type signature of 'node' and 'fbody'.
static bool ValidateInlining(const Node* node, const FunctionBody* fbody) {
if (static_cast<size_t>(node->num_inputs()) != fbody->arg_types.size()) {
return false;
}
if (static_cast<size_t>(node->num_inputs()) != fbody->arg_nodes.size()) {
return false;
}
if (static_cast<size_t>(node->num_outputs()) != fbody->ret_types.size()) {
return false;
}
if (static_cast<size_t>(node->num_outputs()) != fbody->ret_nodes.size()) {
return false;
}
for (int i = 0; i < node->num_inputs(); ++i) {
if (node->input_type(i) != fbody->arg_types[i]) return false;
}
for (int i = 0; i < node->num_outputs(); ++i) {
if (node->output_type(i) != fbody->ret_types[i]) return false;
}
return true;
}
// Given a "caller" in "graph", which is a function call of a function
// to "fbody". Replaces the "caller" with fbody->graph and connects
// edges properly.
static void InlineFunctionBody(Graph* g, Node* caller,
const FunctionBody* fbody) {
if (!ValidateInlining(caller, fbody)) {
LOG(WARNING) << "Inlining mismatch: " << caller->DebugString() << " vs. "
<< DebugString(fbody->graph);
return;
}
// Duplicate fbody->graph into 'g'. First, we copy the nodes of
// fbody->graph into 'g' except the source and sink nodes. We copy
// edges among nodes in 'fbody->graph'.
//
// If 'x' is a node in fbody->graph and its copy in 'g' is 'y', we
// remember 'y' in node_map[x->id()].
std::vector<Node*> node_map(fbody->graph->num_node_ids());
Status s;
for (Node* n : fbody->graph->nodes()) {
if (n->IsSource() || n->IsSink()) continue;
CHECK(n->IsOp());
NodeDef ndef = n->def();
ndef.set_name(strings::StrCat(caller->name(), "/", ndef.name()));
node_map[n->id()] = g->AddNode(ndef, &s);
TF_CHECK_OK(s);
}
for (const Edge* e : fbody->graph->edges()) {
if (e->src()->IsSource() || e->src()->IsSink() || e->dst()->IsSource() ||
e->dst()->IsSink()) {
continue;
}
Node* src_copy = node_map[e->src()->id()];
Node* dst_copy = node_map[e->dst()->id()];
g->AddEdge(src_copy, e->src_output(), dst_copy, e->dst_input());
}
// Connect input edges.
//
// For data edges coming into "caller", we first compute the
// <src>:<src_output> for the i-th input in "inputs". We create one
// Identity node for each input. Then, we connect inputs[i] to to
// the i-th identity node added. The nodes that previously connects
// to the j-th output of i-th arg node are reconnected to th i-th
// identity node.
//
// If "caller" has any input control dependencies, we add a NoOp
// node "input_control_node". This "input_control_node" depends on
// what "caller" depends on, and the added identity nodes depend on
// "input_control_node".
std::vector<Endpoint> inputs(caller->num_inputs());
Node* input_control_node = nullptr;
for (const Edge* e : caller->in_edges()) {
if (e->IsControlEdge()) {
if (input_control_node == nullptr) {
input_control_node = AddNoOp(g);
}
g->AddControlEdge(e->src(), input_control_node);
} else {
inputs[e->dst_input()] = {e->src(), e->src_output()};
}
}
for (std::size_t i = 0; i < fbody->arg_nodes.size(); ++i) {
Node* arg = node_map[fbody->arg_nodes[i]->id()];
Node* n = AddIdentity(g, inputs[i]);
if (input_control_node) {
g->AddControlEdge(input_control_node, n);
}
for (const Edge* e : arg->out_edges()) {
if (e->IsControlEdge()) {
g->AddControlEdge(n, e->dst());
} else {
g->AddEdge(n, 0, e->dst(), e->dst_input());
}
}
node_map[fbody->arg_nodes[i]->id()] = n;
g->RemoveNode(arg); // 'arg' is disconnected.
}
// Connect output edges.
//
// For i-th return node in fbody->graph, we add in "g" an identity
// node (outputs[i-th]). We then reconnect every incoming edge into
// the i-th return node to the added identity node.
//
// For every data edge coming out of "callee"s i-th output, we
// reconnect it to the i-th identity added above.
//
// If "callee" is control-depended upon by any other nodes, we add a
// NoOp node "output_control_node". "output_control_node" depends on
// all identity nodes added above. And nodes previously depend on
// "callee" is changed to depend on "output_control_node".
std::vector<Node*> outputs(caller->num_outputs());
for (std::size_t i = 0; i < fbody->ret_nodes.size(); ++i) {
Node* ret = node_map[fbody->ret_nodes[i]->id()];
Endpoint data; // Data input for the ret node.
for (const Edge* e : ret->in_edges()) {
if (!e->IsControlEdge()) {
data = {e->src(), e->src_output()};
break;
}
}
CHECK(data.node != nullptr);
Node* n = AddIdentity(g, data);
outputs[i] = n;
for (const Edge* e : ret->in_edges()) {
if (e->IsControlEdge()) {
g->AddControlEdge(e->src(), n);
}
}
g->RemoveNode(ret); // 'ret' is disconnected.
}
Node* output_control_node = nullptr;
for (const Edge* e : caller->out_edges()) {
if (e->IsControlEdge()) {
if (output_control_node == nullptr) {
output_control_node = AddNoOp(g);
for (Node* n : outputs) {
g->AddControlEdge(n, output_control_node);
}
}
g->AddControlEdge(output_control_node, e->dst());
} else {
g->AddEdge(outputs[e->src_output()], 0, e->dst(), e->dst_input());
}
}
g->RemoveNode(caller); // 'caller' is replaced with inlined nodes.
}
bool ExpandInlineFunctions(FunctionLibraryRuntime* lib, Graph* graph) {
std::vector<std::pair<Node*, const FunctionBody*>> candidates;
const FunctionLibraryDefinition* fld = lib->GetFunctionLibraryDefinition();
for (Node* node : graph->nodes()) {
VLOG(3) << "Expanding " << node->DebugString();
bool noinline;
if (fld->GetAttr(node->def(), kNoInlineAttr, &noinline).ok() && noinline) {
VLOG(3) << "noinline: " << node->DebugString();
continue;
}
FunctionLibraryRuntime::Handle handle;
Status s =
lib->Instantiate(node->type_string(), node->def().attr(), &handle);
if (!s.ok()) {
// Either "node" is a primitive op, or the instantiation failed.
if (errors::IsNotFound(s)) {
VLOG(3) << "ExpandInlineFunctions " << s;
} else {
LOG(ERROR) << "ExpandInlineFunctions " << s;
}
continue;
}
const FunctionBody* fbody = lib->GetFunctionBody(handle);
CHECK_NOTNULL(fbody);
candidates.push_back({node, fbody});
}
for (const auto& p : candidates) {
InlineFunctionBody(graph, p.first, p.second);
}
return !candidates.empty();
}
string NewName(const Node* n, bool pretty) {
if (pretty) {
return strings::StrCat(n->type_string(), n->id());
} else {
return strings::StrCat("n", n->id());
}
}
// TODO(zhifengc): Maybe this should be the default Graph::AsGraphDef.
// and stash the original NodeDef name as an attr for documentation
// purpose.
void ToGraphDef(const Graph* g, GraphDef* gdef, bool pretty) {
// We visit nodes in forward topological sort order, which is a
// possible execution order of the graph.
std::vector<int> pending(g->num_node_ids());
std::deque<const Node*> ready;
for (const Node* n : g->nodes()) {
pending[n->id()] = n->in_edges().size();
if (pending[n->id()] == 0) ready.push_back(n);
}
gtl::InlinedVector<const Edge*, 4> inputs;
gdef->Clear();
gdef->mutable_versions()->CopyFrom(g->versions());
while (!ready.empty()) {
const Node* n = ready.front();
ready.pop_front();
for (const Edge* e : n->out_edges()) {
const Node* next = e->dst();
if (--pending[next->id()] == 0) {
ready.push_back(next);
}
}
if (!n->IsOp()) continue;
NodeDef* ndef = gdef->add_node();
ndef->set_name(NewName(n, pretty));
ndef->set_op(n->type_string());
*(ndef->mutable_attr()) = n->def().attr();
inputs.clear();
inputs.resize(n->num_inputs());
for (const Edge* e : n->in_edges()) {
if (e->IsControlEdge()) {
inputs.push_back(e);
} else {
if (inputs[e->dst_input()] == nullptr) {
inputs[e->dst_input()] = e;
} else {
LOG(WARNING) << "Malformed graph node. multiple input edges: "
<< n->DebugString();
}
}
}
// node->name() is merely NodeDef::name, which are not guaranteed
// to be unique and stable after optimization rewrites. Therefore,
// we use "n<node id>" instead.
for (const Edge* e : inputs) {
const string srcname = NewName(e->src(), pretty);
if (e == nullptr) {
ndef->add_input("unknown");
} else if (!e->src()->IsOp()) {
} else if (e->IsControlEdge()) {
ndef->add_input(strings::StrCat("^", srcname));
} else if (e->src_output() == 0) {
ndef->add_input(srcname);
} else {
ndef->add_input(strings::StrCat(srcname, ":", e->src_output()));
}
}
}
}
string DebugString(const Graph* g) {
GraphDef gdef;
ToGraphDef(g, &gdef);
return DebugString(gdef);
}
FunctionBody::FunctionBody(const FunctionDef& f, DataTypeSlice arg_t,
DataTypeSlice ret_t, Graph* g)
: fdef(f),
graph(g),
arg_types(arg_t.begin(), arg_t.end()),
ret_types(ret_t.begin(), ret_t.end()) {
this->arg_nodes.resize(arg_types.size());
this->ret_nodes.resize(ret_types.size());
for (Node* n : this->graph->nodes()) {
gtl::InlinedVector<Node*, 4>* node_vec;
if (n->type_string() == kRetOp) {
node_vec = &this->ret_nodes;
} else if (n->type_string() == kArgOp) {
node_vec = &this->arg_nodes;
} else {
continue;
}
int index;
TF_CHECK_OK(GetNodeAttr(n->def(), "index", &index));
CHECK_LE(0, index);
CHECK_LT(index, node_vec->size());
(*node_vec)[index] = n;
}
}
FunctionBody::~FunctionBody() { delete this->graph; }
class SymbolicGradientHelper {
public:
explicit SymbolicGradientHelper(const FunctionBody& f) : fbody_(&f) {}
~SymbolicGradientHelper() { delete gbody_; }
FunctionBody* Compute();
private:
const FunctionBody* fbody_;
FunctionBody* gbody_ = nullptr;
// Makes a copy of fbody_ in gbody_.
void Copy();
TF_DISALLOW_COPY_AND_ASSIGN(SymbolicGradientHelper);
};
void SymbolicGradientHelper::Copy() {
const Graph& src = *(fbody_->graph);
gbody_->graph = new Graph(src.op_registry());
Graph* dst = gbody_->graph;
std::vector<Node*> node_map(src.num_node_ids());
// Copy the nodes.
node_map[src.source_node()->id()] = dst->source_node();
node_map[src.sink_node()->id()] = dst->sink_node();
for (Node* n : src.nodes()) {
if (n->IsSource() || n->IsSink()) continue;
CHECK(n->IsOp());
node_map[n->id()] = dst->CopyNode(n);
}
// Copy the edges.
for (const Edge* e : src.edges()) {
Node* src_copy = node_map[e->src()->id()];
Node* dst_copy = node_map[e->dst()->id()];
dst->AddEdge(src_copy, e->src_output(), dst_copy, e->dst_input());
}
// Save inputs in copied graph.
CHECK_EQ(fbody_->arg_types.size(), fbody_->arg_nodes.size());
gbody_->arg_types = fbody_->arg_types;
for (std::size_t i = 0; i < fbody_->arg_nodes.size(); ++i) {
gbody_->arg_nodes.push_back(node_map[fbody_->arg_nodes[i]->id()]);
}
// Save outputs in copied graph.
CHECK_EQ(fbody_->ret_types.size(), fbody_->ret_nodes.size());
gbody_->ret_types = fbody_->ret_types;
for (std::size_t i = 0; i < fbody_->ret_nodes.size(); ++i) {
gbody_->ret_nodes.push_back(node_map[fbody_->ret_nodes[i]->id()]);
}
}
FunctionBody* SymbolicGradientHelper::Compute() {
CHECK(gbody_ == nullptr);
gbody_ = new FunctionBody;
// Copy fbody_ into gbody_.
Copy();
Graph* g = gbody_->graph;
const int num_y = gbody_->ret_nodes.size();
// Populate 'y_node_outputs_' with node function body outputs.
// Populate 'y_grad_nodes' with initial gradient nodes for each return node of
// the original function body (these will be 'arg' nodes in the function
// gradient body).
std::vector<NodeOut> y_node_outputs;
y_node_outputs.reserve(num_y);
std::vector<NodeOut> y_grad_node_outputs;
y_grad_node_outputs.reserve(num_y);
for (int i = 0; i < num_y; ++i) {
Node* y = gbody_->ret_nodes[i];
y_node_outputs.push_back({y, 0});
DCHECK_EQ(y->type_string(), kRetOp);
const DataType dtype = y->input_type(0);
const int index = gbody_->arg_nodes.size();
Node* dy = AddArg(g, dtype, index);
gbody_->arg_types.push_back(dtype);
gbody_->arg_nodes.push_back(dy);
y_grad_node_outputs.push_back({dy, 0});
}
// Populate 'x_nodes' with function args (excluding 'y_grad_node_outputs').
const int num_x = fbody_->arg_nodes.size();
std::vector<NodeOut> x_node_outputs;
x_node_outputs.reserve(num_x);
for (size_t i = 0; i < fbody_->arg_nodes.size(); ++i) {
x_node_outputs.push_back({gbody_->arg_nodes[i], 0});
}
// Call AddSymbolicGradients which will add nodes to graph 'g' that
// compute the function gradient (adding an entry in 'x_grad_node_outputs' for
// each node in 'x_node_outputs').
std::vector<NodeOut> x_grad_node_outputs;
TF_CHECK_OK(AddSymbolicGradients(y_node_outputs, x_node_outputs,
y_grad_node_outputs, &x_grad_node_outputs,
g));
// Remove the old return nodes from the function body.
for (Node* n : gbody_->ret_nodes) {
g->RemoveNode(n);
}
gbody_->ret_types = fbody_->arg_types;
gbody_->ret_nodes.clear();
// Add new return nodes to the function gradient body for each node
// in 'x_grad_nodes'.
for (size_t i = 0; i < fbody_->arg_types.size(); ++i) {
Endpoint grad = {x_grad_node_outputs[i].node, x_grad_node_outputs[i].index};
Node* ret = AddRet(g, grad, i);
gbody_->ret_nodes.push_back(ret);
}
auto ret = gbody_;
gbody_ = nullptr;
return ret;
}
FunctionBody* SymbolicGradient(const FunctionBody& f) {
return SymbolicGradientHelper(f).Compute();
}
} // end namespace tensorflow
| [
"[email protected]"
] | |
9a38aa2eccb3ff15892272da8b139e65635817ee | 1af05ed3593f813afb0973401736aad836318e61 | /RaiseTheGameJame2020/Source/RaiseTheGameJame2020/Public/RunFromKillerAgentTask.h | 00f07b851dda2974c7d161a45a2955a2fc08f8e0 | [] | no_license | OverAHill/-raisethegamejam-2020 | ae6db2082f9eddc9fb5cf04827b78cf7733997ba | 74acf6514f170c8b9314dc88c0c8156b143341c0 | refs/heads/main | 2023-01-14T08:22:43.372473 | 2020-11-20T11:06:26 | 2020-11-20T11:06:26 | 313,878,460 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 699 | h | // Fill out your copyright notice in the Description page of Project Settings.
#pragma once
#include "CoreMinimal.h"
#include "IAgentTask.h"
/**
*
*/
class RAISETHEGAMEJAME2020_API RunFromKillerAgentTask : public IAgentTask
{
private:
AActor* ParentReference;
FVector* PointerPosForPathfinding;
AActor* KillerReference;
float fleeTime = 0;
float escapeTime = 30;
bool CanSeeKiller();
FVector GetDirectionToKiller();
float GetDistanceToKiller();
public:
RunFromKillerAgentTask(AActor* parentReference, FVector* pointerPosForPathfinding, AActor* killerReference);
~RunFromKillerAgentTask();
virtual bool CanRun();
virtual void Run(float DeltaTime);
virtual bool IsFinished();
};
| [
"[email protected]"
] | |
3f7554073c48c8e55128a42c3b9d52e96eb456e8 | aa518ca6e354ef98929275a0f4f3675f8fb4bd07 | /src/uniforms.h | 2f3eb3e7564313a9f574fb662a6622bb01c85222 | [] | no_license | YangZhongLou/Renderer | 94631e8bf7415ce3ca8e3034a58d15d5c6cb6f13 | 3901f0594b991d25d473dff24ca941cde5a6a686 | refs/heads/master | 2021-05-15T07:14:11.277490 | 2018-04-11T05:58:52 | 2018-04-11T05:58:52 | 111,370,281 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 631 | h | /**
* Author ZhongLou Yang, 2018-2-5
*/
#pragma once
#include <glm/glm.hpp>
#include <glm/gtc/matrix_transform.hpp>
#include <vulkan/vulkan.h>
namespace Concise
{
class Uniforms
{
private:
struct
{
glm::mat4 projectionMatrix;
glm::mat4 modelMatrix;
glm::mat4 viewMatrix;
} m_vsData;
struct
{
VkDeviceMemory memory;
VkBuffer buffer;
VkDescriptorBufferInfo descriptor;
} m_vsBuffer;
public:
Uniforms();
~Uniforms();
public:
void UpdateVS(UInt32 width, UInt32 height);
public:
const VkDescriptorBufferInfo & GetDescriptorBufferInfo() { return m_vsBuffer.descriptor; }
};
} | [
"[email protected]"
] | |
4f320c1cc2847fd9b1513c2ae64f3f22018295cd | 544d81c99743fafe64b7724d81fc6cd660a9ea22 | /Source/Clockpunk/Private/Monster.cpp | adf2da108a59b9c704d2cca482f852bc126686dc | [] | no_license | axandros/Clockpunk-Shooter-RPG | 2a517928fcac1d173da94a733650453ca9417f27 | a75aaf1ea1cef4d663ee272ec0b680f3714b87f8 | refs/heads/main | 2022-12-30T14:48:54.062711 | 2020-10-17T01:12:30 | 2020-10-17T01:12:30 | 300,431,656 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 1,004 | cpp | // Copyright 2020 Tristan "Axandros" Brumagin.
#include "Monster.h"
#include "QueryPerceptionComponent.h"
#include "HealthComponent.h"
// Sets default values
AMonster::AMonster()
{
// Set this character to call Tick() every frame. You can turn this off to improve performance if you don't need it.
PrimaryActorTick.bCanEverTick = true;
PerceptionComponent = CreateDefaultSubobject<UQueryPerceptionComponent>(TEXT("PerceptionComponent"));
HealthComponent = CreateDefaultSubobject<UHealthComponent>(TEXT("CombatComponent"));
HealthComponent->OnZeroHealth.AddDynamic(this, &AMonster::Death);
}
// Called when the game starts or when spawned
void AMonster::BeginPlay()
{
Super::BeginPlay();
}
// Called every frame
void AMonster::Tick(float DeltaTime)
{
Super::Tick(DeltaTime);
}
// Called to bind functionality to input
void AMonster::SetupPlayerInputComponent(UInputComponent* PlayerInputComponent)
{
Super::SetupPlayerInputComponent(PlayerInputComponent);
}
void AMonster::Death()
{
}
| [
"[email protected]"
] | |
c4c0b48d44f7b39d9ffe7aea07fbe471ca51d941 | f3bff538925787d41be01428618f322476afd4b2 | /Scheduler.cc | 5684bcc48cf90fe3d7931397096bb31727490b13 | [] | no_license | joeyleeeeeee97/MicoThread | 0937c81d6e178bfef1e6957eac06dbbd3d9b7532 | 0a57186399985545fd55ae81cff090f61328d119 | refs/heads/master | 2020-03-21T01:50:32.625078 | 2018-06-20T01:48:08 | 2018-06-20T01:48:08 | 137,965,877 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 677 | cc | #include"Scheduler.h"
using namespace mt;
void Scheduler::yield(){
if(curthread_idx == -1){
return ;
}
mthread* t = threads[curthread_idx];
t->state = State::SUSPEND;
curthread_idx = -1;
swapcontext(&(t->context), &main);
}
void Scheduler::resume(int id){
if(id < 0 || id >= threads.size()){
return ;
}
mthread* t = threads[id];
if(t->state == State::SUSPEND){
curthread_idx = id;
swapcontext(&main, &(t->context));
}
}
int Scheduler::finished(){
for(auto& mt : threads){
if(mt->state != State::FREE){
return 0;
}
}
return 1;
}
| [
"[email protected]"
] | |
638b0123229d6e1d00c440327e4e3106f0a46d25 | 2d361696ad060b82065ee116685aa4bb93d0b701 | /src/sra/readers/sra/sraread.cpp | 43241682aba67aaf42abe9e74f59830bb8f9b34f | [
"LicenseRef-scancode-public-domain"
] | permissive | AaronNGray/GenomeWorkbench | 5151714257ce73bdfb57aec47ea3c02f941602e0 | 7156b83ec589e0de8f7b0a85699d2a657f3e1c47 | refs/heads/master | 2022-11-16T12:45:40.377330 | 2020-07-10T00:54:19 | 2020-07-10T00:54:19 | 278,501,064 | 1 | 1 | null | null | null | null | UTF-8 | C++ | false | false | 17,112 | cpp | /* $Id: sraread.cpp 519877 2016-11-18 20:51:27Z vasilche $
* ===========================================================================
*
* PUBLIC DOMAIN NOTICE
* National Center for Biotechnology Information
*
* This software/database is a "United States Government Work" under the
* terms of the United States Copyright Act. It was written as part of
* the author's official duties as a United States Government employee and
* thus cannot be copyrighted. This software/database is freely available
* to the public for use. The National Library of Medicine and the U.S.
* Government have not placed any restriction on its use or reproduction.
*
* Although all reasonable efforts have been taken to ensure the accuracy
* and reliability of the software and data, the NLM and the U.S.
* Government do not and cannot warrant the performance or results that
* may be obtained by using this software or data. The NLM and the U.S.
* Government disclaim all warranties, express or implied, including
* warranties of performance, merchantability or fitness for any particular
* purpose.
*
* Please cite the author in any work or product based on this material.
*
* ===========================================================================
*
* Authors: Eugene Vasilchenko
*
* File Description:
* Access to SRA files
*
*/
#include <ncbi_pch.hpp>
#include <sra/readers/sra/sraread.hpp>
#include <klib/rc.h>
#include <klib/writer.h>
#include <sra/types.h>
#include <sra/impl.h>
#include <sra/sradb.h>
#include <sra/sradb-priv.h>
#include <vfs/manager.h>
#include <vfs/resolver.h>
#include <vfs/path.h>
#include <corelib/ncbimtx.hpp>
#include <corelib/ncbi_param.hpp>
#include <sra/readers/ncbi_traces_path.hpp>
#include <objects/general/general__.hpp>
#include <objects/seq/seq__.hpp>
#include <objects/seqset/seqset__.hpp>
#include <objects/seqres/seqres__.hpp>
#include <sra/error_codes.hpp>
#include <cstring>
BEGIN_NCBI_SCOPE
#define NCBI_USE_ERRCODE_X SRAReader
NCBI_DEFINE_ERR_SUBCODE_X(1);
BEGIN_SCOPE(objects)
class CSeq_entry;
DEFINE_SRA_REF_TRAITS(SRAMgr, const);
DEFINE_SRA_REF_TRAITS(SRAColumn, const);
DEFINE_SRA_REF_TRAITS(SRATable, const);
CSraException::CSraException(void)
: m_RC(0)
{
}
CSraException::CSraException(const CDiagCompileInfo& info,
const CException* prev_exc,
EErrCode err_code,
const string& message,
EDiagSev severity)
: CException(info, prev_exc, CException::EErrCode(err_code), message),
m_RC(0)
{
this->x_Init(info, message, prev_exc, severity);
this->x_InitErrCode(CException::EErrCode(err_code));
}
CSraException::CSraException(const CDiagCompileInfo& info,
const CException* prev_exc,
EErrCode err_code,
const string& message,
rc_t rc,
EDiagSev severity)
: CException(info, prev_exc, CException::EErrCode(err_code), message),
m_RC(rc)
{
this->x_Init(info, message, prev_exc, severity);
this->x_InitErrCode(CException::EErrCode(err_code));
}
CSraException::CSraException(const CDiagCompileInfo& info,
const CException* prev_exc,
EErrCode err_code,
const string& message,
rc_t rc,
const string& param,
EDiagSev severity)
: CException(info, prev_exc, CException::EErrCode(err_code), message),
m_RC(rc),
m_Param(param)
{
this->x_Init(info, message, prev_exc, severity);
this->x_InitErrCode(CException::EErrCode(err_code));
}
CSraException::CSraException(const CDiagCompileInfo& info,
const CException* prev_exc,
EErrCode err_code,
const string& message,
rc_t rc,
int64_t param,
EDiagSev severity)
: CException(info, prev_exc, CException::EErrCode(err_code), message),
m_RC(rc),
m_Param(NStr::Int8ToString(param))
{
this->x_Init(info, message, prev_exc, severity);
this->x_InitErrCode(CException::EErrCode(err_code));
}
CSraException::CSraException(const CSraException& other)
: CException( other),
m_RC(other.m_RC),
m_Param(other.m_Param)
{
x_Assign(other);
}
CSraException::~CSraException(void) throw()
{
}
const CException* CSraException::x_Clone(void) const
{
return new CSraException(*this);
}
const char* CSraException::GetType(void) const
{
return "CSraException";
}
CSraException::TErrCode CSraException::GetErrCode(void) const
{
return typeid(*this) == typeid(CSraException) ?
x_GetErrCode() : CException::GetErrCode();
}
const char* CSraException::GetErrCodeString(void) const
{
switch (GetErrCode()) {
case eOtherError: return "eOtherError";
case eNullPtr: return "eNullPtr";
case eAddRefFailed: return "eAddRefFailed";
case eInvalidArg: return "eInvalidArg";
case eInitFailed: return "eInitFailed";
case eNotFound: return "eNotFound";
case eInvalidState: return "eInvalidState";
case eInvalidIndex: return "eInvalidIndex";
case eNotFoundDb: return "eNotFoundDb";
case eNotFoundTable: return "eNotFoundTable";
case eNotFoundColumn: return "eNotFoundColumn";
case eNotFoundValue: return "eNotFoundValue";
case eDataError: return "eDataError";
case eNotFoundIndex: return "eNotFoundIndex";
case eProtectedDb: return "eProtectedDb";
default: return CException::GetErrCodeString();
}
}
ostream& operator<<(ostream& out, const CSraRcFormatter& rc)
{
char buffer[1024];
size_t error_len;
RCExplain(rc.GetRC(), buffer, sizeof(buffer), &error_len);
out << "0x" << hex << rc.GetRC() << dec << ": " << buffer;
return out;
}
void CSraException::ReportExtra(ostream& out) const
{
if ( m_RC ) {
out << CSraRcFormatter(m_RC);
}
if ( !m_Param.empty() ) {
if ( m_RC ) {
out << ": ";
}
out << m_Param;
}
}
void CSraException::ReportError(const char* msg, rc_t rc)
{
ERR_POST_X(1, msg<<": "<<CSraRcFormatter(rc));
}
CSraPath::CSraPath(void)
{
}
CSraPath::CSraPath(const string& /*rep_path*/, const string& /*vol_path*/)
{
}
NCBI_PARAM_DECL(string, SRA, REP_PATH);
NCBI_PARAM_DEF(string, SRA, REP_PATH, "");
NCBI_PARAM_DECL(string, SRA, VOL_PATH);
NCBI_PARAM_DEF(string, SRA, VOL_PATH, "");
string CSraPath::GetDefaultRepPath(void)
{
return NCBI_PARAM_TYPE(SRA, REP_PATH)::GetDefault();
}
string CSraPath::GetDefaultVolPath(void)
{
return NCBI_PARAM_TYPE(SRA, VOL_PATH)::GetDefault();
}
DEFINE_STATIC_FAST_MUTEX(sx_PathMutex);
void CSraPath::AddRepPath(const string& rep_path)
{
}
void CSraPath::AddVolPath(const string& vol_path)
{
}
string CSraPath::FindAccPath(const string& acc) const
{
string ret;
ret.resize(128);
rc_t rc;
{{
CFastMutexGuard guard(sx_PathMutex);
//rc = SRAPathFind(*this, acc.c_str(), &ret[0], ret.size());
VFSManager* mgr;
rc = VFSManagerMake(&mgr);
if (rc == 0) {
rc_t rc2;
VResolver* res;
rc = VFSManagerGetResolver(mgr, &res);
if (rc == 0) {
VPath* accPath;
rc = VFSManagerMakePath(mgr, &accPath, acc.c_str());
if (rc == 0)
{
const VPath* resolvedPath;
rc = VResolverQuery(res, eProtocolHttp, accPath, &resolvedPath, NULL, NULL);
if (rc == 0)
{
String s;
VPathGetPath(resolvedPath, &s);
ret.assign(s.addr, s.len);
rc2 = VPathRelease(resolvedPath);
if (rc == 0)
rc = rc2;
}
rc2 = VPathRelease(accPath);
if (rc == 0)
rc = rc2;
}
rc2 = VResolverRelease(res);
if (rc == 0)
rc = rc2;
}
rc2 = VFSManagerRelease(mgr);
if (rc == 0)
rc = rc2;
}
}}
if ( rc ) {
NCBI_THROW3(CSraException, eNotFound,
"Cannot find acc path", rc, acc);
}
SIZE_TYPE eol_pos = ret.find('\0');
if ( eol_pos != NPOS ) {
ret.resize(eol_pos);
}
return ret;
}
CSraMgr::CSraMgr(ETrim trim)
: m_Path(null),
m_Trim(trim == eTrim)
{
x_Init();
}
CSraMgr::CSraMgr(const string& /*rep_path*/, const string& /*vol_path*/,
ETrim trim)
: m_Path(null),
m_Trim(trim == eTrim)
{
x_Init();
}
void CSraMgr::RegisterFunctions(void)
{
}
void CSraMgr::x_Init(void)
{
if ( rc_t rc = SRAMgrMakeRead(x_InitPtr()) ) {
*x_InitPtr() = 0;
NCBI_THROW2(CSraException, eInitFailed,
"Cannot open SRAMgr", rc);
}
}
CSraPath& CSraMgr::GetPath(void) const
{
if ( !m_Path ) {
CFastMutexGuard guard(sx_PathMutex);
if ( !m_Path ) {
m_Path = CSraPath();
}
}
return m_Path;
}
string CSraMgr::FindAccPath(const string& acc) const
{
return GetPath().FindAccPath(acc);
}
spotid_t CSraMgr::GetSpotInfo(const string& sra, CSraRun& run)
{
SIZE_TYPE dot = sra.find('.');
string acc;
spotid_t spot_id = 0;
if ( dot == NPOS ) {
NCBI_THROW3(CSraException, eInvalidArg,
"No spot id specified",
RC(rcApp, rcFunctParam, rcDecoding, rcParam, rcIncomplete),
sra);
}
else {
acc = sra.substr(0, dot);
spot_id = NStr::StringToUInt(sra.substr(dot+1));
}
if ( !run || run.GetAccession() != acc ) {
run = CSraRun(*this, acc);
}
return spot_id;
}
CRef<CSeq_entry> CSraMgr::GetSpotEntry(const string& sra,
CSraRun& run)
{
return run.GetSpotEntry(GetSpotInfo(sra, run));
}
CRef<CSeq_entry> CSraMgr::GetSpotEntry(const string& sra)
{
CSraRun run;
return GetSpotEntry(sra, run);
}
CSraValue::CSraValue(const CSraColumn& col, spotid_t id, ECheckRc check_rc)
: m_Error(0), m_Data(0), m_Bitoffset(0), m_Bitlen(0), m_Len(0)
{
m_Error = SRAColumnRead(col, id, &m_Data, &m_Bitoffset, &m_Bitlen);
if ( !m_Error ) {
if ( m_Bitoffset ) {
m_Error = RC(rcApp, rcColumn, rcDecoding, rcOffset, rcUnsupported);
}
else {
uint64_t len = (m_Bitlen+7)>>3;
#if SIZEOF_SIZE_T == 4
m_Len = size_t(len);
if ( m_Len != len ) {
m_Error = RC(rcApp, rcColumn, rcDecoding, rcSize, rcUnsupported);
}
#else
m_Len = len;
#endif
}
}
if ( m_Error && check_rc == eCheckRc ) {
NCBI_THROW3(CSraException, eNotFoundValue, "Cannot read value",
m_Error, NStr::NumericToString(id));
}
}
void CSraRun::Init(CSraMgr& mgr, const string& acc)
{
m_Acc = acc;
m_Trim = mgr.GetTrim();
x_DoInit(mgr, acc);
}
void CSraRun::x_DoInit(CSraMgr& mgr, const string& acc)
{
if ( rc_t rc = SRAMgrOpenTableRead(mgr, x_InitPtr(), "%.*s",
int(acc.size()), acc.data()) ) {
*x_InitPtr() = 0;
NCBI_THROW3(CSraException, eNotFoundDb,
"Cannot open run read", rc, acc);
}
m_Name.Init(*this, "NAME", vdb_ascii_t);
m_Read.Init(*this, "READ", insdc_fasta_t);
m_Qual.Init(*this, "QUALITY", ncbi_qual1_t);
m_SDesc.Init(*this, "SPOT_DESC", sra_spot_desc_t);
m_RDesc.Init(*this, "READ_DESC", sra_read_desc_t);
m_TrimStart.TryInitRc(*this, "TRIM_START", "INSDC:coord:zero");
}
rc_t CSraColumn::TryInitRc(const CSraRun& run,
const char* name, const char* type)
{
return SRATableOpenColumnRead(run, x_InitPtr(), name, type);
}
void CSraColumn::Init(const CSraRun& run,
const char* name, const char* type)
{
if ( rc_t rc = TryInitRc(run, name, type) ) {
*x_InitPtr() = 0;
NCBI_THROW3(CSraException, eInitFailed,
"Cannot get SRA column", rc, name);
}
}
CRef<CSeq_entry> CSraRun::GetSpotEntry(spotid_t spot_id) const
{
CRef<CSeq_entry> entry;
CSraStringValue name(m_Name, spot_id);
entry = new CSeq_entry();
CBioseq_set& seqset = entry->SetSet();
seqset.SetLevel(0);
seqset.SetClass(seqset.eClass_other);
CSraValueFor<SRASpotDesc> sdesc(m_SDesc, spot_id);
TSeqPos trim_start = m_Trim && m_TrimStart?
CSraValueFor<INSDC_coord_zero>(m_TrimStart, spot_id).Value(): 0;
TSeqPos trim_end = sdesc->clip_qual_right;
CSraValueFor<SRAReadDesc> rdesc(m_RDesc, spot_id);
CSraStringValue read(m_Read, spot_id);
CSraBytesValue qual(m_Qual, spot_id);
int seq_count = 0;
string id_start = GetAccession()+'.'+NStr::NumericToString(spot_id)+'.';
for ( int r = 0; r < sdesc->num_reads; ++r ) {
if ( rdesc[r].type != SRA_READ_TYPE_BIOLOGICAL ) {
continue;
}
TSeqPos len = rdesc[r].seg.len;
if ( len == 0 ) {
continue;
}
TSeqPos start = rdesc[r].seg.start;
TSeqPos end = start + len;
if ( m_Trim ) {
start = max(start, trim_start);
end = min(end, trim_end);
if ( start >= end ) {
continue;
}
len = end - start;
}
CRef<CSeq_entry> seq_entry(new CSeq_entry);
CBioseq& seq = seq_entry->SetSeq();
CRef<CSeq_id> id(new CSeq_id);
id->SetGeneral().SetDb("SRA");
id->SetGeneral().SetTag().SetStr(id_start+NStr::UIntToString(r+1));
seq.SetId().push_back(id);
{{
CRef<CSeqdesc> desc(new CSeqdesc);
desc->SetTitle(name.Value());
seq.SetDescr().Set().push_back(desc);
}}
{{
CSeq_inst& inst = seq.SetInst();
inst.SetRepr(inst.eRepr_raw);
inst.SetMol(inst.eMol_na);
inst.SetLength(len);
inst.SetSeq_data().SetIupacna().Set()
.assign(read.data()+start, len);
}}
{{
CRef<CSeq_annot> annot(new CSeq_annot);
CRef<CSeq_graph> graph(new CSeq_graph);
annot->SetData().SetGraph().push_back(graph);
graph->SetTitle("Phred Quality");
graph->SetLoc().SetWhole(*id);
graph->SetNumval(len);
CByte_graph& bytes = graph->SetGraph().SetByte();
bytes.SetAxis(0);
CByte_graph::TValues& values = bytes.SetValues();
values.reserve(len);
int min = kMax_Int;
int max = kMin_Int;
for ( size_t i = 0; i < len; ++i ) {
int v = qual[start+i];
values.push_back(v);
if ( v < min ) {
min = v;
}
if ( v > max ) {
max = v;
}
}
bytes.SetMin(min);
bytes.SetMax(max);
seq.SetAnnot().push_back(annot);
}}
seqset.SetSeq_set().push_back(seq_entry);
++seq_count;
}
switch ( seq_count ) {
case 0:
entry.Reset();
break;
case 1:
entry = seqset.GetSeq_set().front();
break;
}
return entry;
}
CSeq_inst::TMol CSraRun::GetSequenceType(spotid_t spot_id,
uint8_t read_id) const
{
CSraValueFor<SRASpotDesc> sdesc(m_SDesc, spot_id);
if ( read_id == 0 || read_id > sdesc->num_reads ) {
return CSeq_inst::eMol_not_set;
}
return CSeq_inst::eMol_na;
}
TSeqPos CSraRun::GetSequenceLength(spotid_t spot_id,
uint8_t read_id) const
{
CSraValueFor<SRASpotDesc> sdesc(m_SDesc, spot_id);
if ( read_id == 0 || read_id > sdesc->num_reads ) {
return kInvalidSeqPos;
}
TSeqPos trim_start = m_Trim && m_TrimStart?
CSraValueFor<INSDC_coord_zero>(m_TrimStart, spot_id).Value(): 0;
TSeqPos trim_end = sdesc->clip_qual_right;
CSraValueFor<SRAReadDesc> rdesc(m_RDesc, spot_id);
size_t r = read_id-1;
TSeqPos len = rdesc[r].seg.len;
if ( len == 0 ) {
return kInvalidSeqPos;
}
TSeqPos start = rdesc[r].seg.start;
TSeqPos end = start + len;
if ( m_Trim ) {
start = max(start, trim_start);
end = min(end, trim_end);
if ( start >= end ) {
return kInvalidSeqPos;
}
len = end - start;
}
return len;
}
END_SCOPE(objects)
END_NCBI_SCOPE
| [
"[email protected]"
] | |
d9a53ba3b9d9bb1e4234d31605bb408db740c27c | 6cecdbbe6eb721a0e43c07ed2b31bdcc9e553c55 | /Sail2D/Runs/first_flatplate_300_4/case/1000/nut | b411e38f8ec8dbfd26add933da18ce95d207af6e | [] | no_license | kiranhegde/Gmsh | 799d8cbefb7dd3f3d35ded15b40292fd3ede6468 | fefa906dabfddd9b87cc1f0256df81b4735420e1 | refs/heads/master | 2021-01-19T23:21:57.414954 | 2015-01-21T02:02:37 | 2015-01-21T02:02:37 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 391,404 | /*--------------------------------*- C++ -*----------------------------------*\
| ========= | |
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
| \\ / O peration | Version: 2.3.0 |
| \\ / A nd | Web: www.OpenFOAM.org |
| \\/ M anipulation | |
\*---------------------------------------------------------------------------*/
FoamFile
{
version 2.0;
format ascii;
class volScalarField;
location "1000";
object nut;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
dimensions [0 2 -1 0 0 0 0];
internalField nonuniform List<scalar>
37234
(
0.0679169
0.066363
0.0648068
0.0632489
0.06169
0.0601304
0.0585711
0.0570125
0.0554555
0.0539006
0.0523487
0.0508001
0.0492556
0.0477154
0.0461802
0.0446506
0.043127
0.0416096
0.0400992
0.0385956
0.0371003
0.0356131
0.0341348
0.0326664
0.0312091
0.0297634
0.02833
0.0269111
0.0255077
0.0241217
0.0227549
0.0214103
0.0200902
0.0187996
0.0175429
0.0163279
0.0151631
0.0140589
0.0130225
0.0120542
0.0110943
0.00983606
0.00822558
0.0691617
0.0677886
0.0664146
0.06504
0.0636647
0.062289
0.0609134
0.0595381
0.0581637
0.0567905
0.0554191
0.0540498
0.0526829
0.0513187
0.0499576
0.0486001
0.0472466
0.0458972
0.0445519
0.0432121
0.0418778
0.0405497
0.0392282
0.0379141
0.0366097
0.0353161
0.0340347
0.0327671
0.0315175
0.0302875
0.0290823
0.0279051
0.0267634
0.025664
0.0246161
0.0236315
0.0227243
0.0219108
0.0212073
0.0206337
0.0202076
0.0199425
0.0198518
0.0703117
0.0690923
0.0678736
0.0666543
0.065434
0.064213
0.0629911
0.0617685
0.0605459
0.0593232
0.0581006
0.0568785
0.0556573
0.0544371
0.053218
0.0520006
0.0507852
0.0495718
0.0483613
0.0471537
0.0459501
0.0447507
0.0435563
0.0423679
0.0411869
0.0400155
0.0388562
0.0377107
0.0365827
0.035476
0.034395
0.0333453
0.0323332
0.0313666
0.030455
0.0296076
0.0288375
0.028158
0.0275811
0.027121
0.0267898
0.0265959
0.0265451
0.0713628
0.0702814
0.0691969
0.0681106
0.0670226
0.0659328
0.0648409
0.0637471
0.0626516
0.0615546
0.0604562
0.0593567
0.0582562
0.0571549
0.056053
0.0549508
0.0538485
0.0527466
0.0516458
0.0505467
0.0494492
0.0483547
0.0472639
0.0461773
0.0450967
0.0440241
0.0429615
0.0419123
0.0408794
0.0398675
0.0388807
0.0379248
0.0370065
0.036133
0.0353132
0.0345563
0.0338723
0.0332722
0.0327673
0.0323681
0.032084
0.0319212
0.0318837
0.0723352
0.0713662
0.0703959
0.0694235
0.0684486
0.0674707
0.0664893
0.0655042
0.0645157
0.0635242
0.0625299
0.0615326
0.0605323
0.0595298
0.0585248
0.0575178
0.0565086
0.055498
0.0544867
0.0534756
0.0524652
0.0514559
0.0504489
0.0494453
0.0484458
0.0474526
0.0464682
0.0454947
0.0445363
0.0435971
0.0426821
0.0417967
0.0409473
0.0401409
0.0393857
0.0386904
0.0380636
0.0375156
0.0370558
0.0366937
0.0364371
0.0362918
0.0362608
0.0732188
0.0723515
0.0714803
0.0706058
0.0697279
0.0688459
0.0679587
0.0670659
0.0661676
0.0652649
0.064358
0.0634465
0.0625301
0.0616097
0.0606854
0.0597573
0.0588252
0.0578898
0.0569518
0.0560124
0.0550726
0.0541331
0.0531946
0.0522583
0.0513256
0.0503974
0.0494761
0.0485641
0.0476647
0.0467827
0.045923
0.0450917
0.0442947
0.043539
0.0428314
0.0421803
0.0415942
0.0410822
0.0406536
0.040316
0.0400769
0.0399416
0.0399137
0.0740278
0.0732461
0.07246
0.0716696
0.0708751
0.070075
0.0692693
0.0684554
0.0676341
0.0668056
0.0659719
0.065133
0.0642876
0.0634353
0.0625783
0.0617163
0.0608491
0.0599762
0.0590985
0.0582177
0.0573355
0.0564528
0.0555707
0.0546895
0.0538111
0.0529367
0.0520682
0.0512074
0.0503564
0.0495198
0.0487035
0.047914
0.0471581
0.046442
0.0457713
0.0451538
0.0445983
0.0441126
0.0437053
0.0433848
0.0431578
0.0430297
0.0430036
0.0747606
0.074057
0.0733445
0.0726255
0.0719038
0.0711726
0.0704395
0.0696926
0.0689383
0.0681715
0.0673983
0.0666208
0.0658376
0.0650416
0.0642401
0.0634335
0.0626214
0.0618022
0.0609748
0.0601418
0.0593062
0.0584699
0.0576338
0.0567981
0.0559643
0.0551341
0.0543091
0.053493
0.0526837
0.0518842
0.0511023
0.0503451
0.0496217
0.0489377
0.0482974
0.0477063
0.0471748
0.0467089
0.0463181
0.0460087
0.0457906
0.0456689
0.0456453
0.0754354
0.0747935
0.0741425
0.0734816
0.0728302
0.0721478
0.0714865
0.0707911
0.0701023
0.0693848
0.0686607
0.0679248
0.0672014
0.0664536
0.0656982
0.064935
0.0641675
0.0633947
0.0626117
0.0618161
0.061017
0.0602152
0.0594141
0.0586147
0.0578171
0.0570241
0.0562318
0.0554536
0.0546879
0.053921
0.0531701
0.0524354
0.0517375
0.0510809
0.0504713
0.0499003
0.0493915
0.0489421
0.0485681
0.0482658
0.0480552
0.0479407
0.0479251
0.00880456
0.0108841
0.0120774
0.0131954
0.0143783
0.0156386
0.0169617
0.0183298
0.019731
0.0211565
0.0226001
0.0240575
0.0255261
0.0270034
0.028488
0.0299788
0.0314755
0.0329769
0.0344828
0.0359933
0.0375074
0.0390251
0.0405464
0.0420709
0.0435983
0.0451287
0.0466617
0.048197
0.0497345
0.0512735
0.052814
0.0543557
0.0558982
0.057441
0.0589837
0.0605257
0.0620667
0.0636064
0.0651442
0.0666792
0.068211
0.0697388
0.0712629
0.0199419
0.0202226
0.0206911
0.0213331
0.022125
0.0230435
0.0240641
0.0251654
0.0263312
0.0275464
0.0287997
0.030083
0.0313891
0.0327125
0.0340489
0.0353959
0.0367505
0.0381107
0.0394758
0.0408443
0.0422151
0.0435879
0.0449618
0.0463365
0.0477123
0.0490882
0.0504645
0.0518405
0.0532163
0.0545917
0.0559662
0.0573402
0.0587132
0.0600851
0.0614558
0.0628251
0.0641925
0.0655583
0.0669222
0.0682837
0.0696427
0.0709993
0.0723543
0.0266362
0.0268701
0.0272515
0.0277734
0.0284231
0.0291856
0.030045
0.0309861
0.0319949
0.0330586
0.0341661
0.0353087
0.0364792
0.0376712
0.0388799
0.0401012
0.0413317
0.0425689
0.0438108
0.0450558
0.0463026
0.0475503
0.0487978
0.0500451
0.0512915
0.0525366
0.05378
0.0550214
0.0562609
0.0574981
0.058733
0.0599656
0.0611958
0.0624235
0.0636487
0.0648716
0.066092
0.0673099
0.0685254
0.0697383
0.070949
0.0721579
0.0733683
0.0319698
0.032181
0.0325187
0.0329776
0.0335493
0.0342223
0.0349853
0.0358257
0.0367317
0.0376921
0.0386966
0.0397371
0.0408062
0.0418978
0.0430071
0.0441296
0.045261
0.0463985
0.0475405
0.0486845
0.0498294
0.0509739
0.0521174
0.0532592
0.0543987
0.0555351
0.0566681
0.0577977
0.0589235
0.0600453
0.061163
0.062277
0.0633872
0.0644936
0.0655961
0.0666951
0.0677906
0.0688825
0.0699712
0.0710563
0.0721384
0.073218
0.0742992
0.0363424
0.0365387
0.0368497
0.0372701
0.0377931
0.0384096
0.0391095
0.0398818
0.0407163
0.0416029
0.0425324
0.0434969
0.0444898
0.045505
0.0465367
0.0475807
0.0486329
0.0496904
0.0507511
0.0518127
0.0528738
0.0539341
0.0549921
0.056047
0.0570982
0.0581447
0.0591863
0.0602226
0.0612537
0.0622791
0.0632989
0.0643134
0.0653228
0.0663269
0.0673258
0.0683199
0.0693093
0.0702938
0.0712737
0.072249
0.0732198
0.0741856
0.0751469
0.0399922
0.0401775
0.0404692
0.0408628
0.0413525
0.0419299
0.0425857
0.0433094
0.0440916
0.0449236
0.0457969
0.0467036
0.0476376
0.0485929
0.0495639
0.0505456
0.0515338
0.052526
0.0535202
0.0545144
0.0555074
0.0564985
0.0574863
0.0584698
0.0594481
0.06042
0.0613852
0.0623439
0.0632956
0.0642404
0.065178
0.0661091
0.0670335
0.0679513
0.0688627
0.0697678
0.0706666
0.0715593
0.0724462
0.0733274
0.0742025
0.0750711
0.0759343
0.0430789
0.0432558
0.0435328
0.0439069
0.0443719
0.0449207
0.0455435
0.0462308
0.0469737
0.0477637
0.0485933
0.049455
0.0503425
0.0512509
0.052174
0.0531045
0.0540399
0.0549783
0.0559172
0.0568556
0.0577923
0.0587267
0.0596574
0.060582
0.0614992
0.0624081
0.0633098
0.0642037
0.0650884
0.0659649
0.0668337
0.0676947
0.0685472
0.0693916
0.070229
0.0710586
0.07188
0.0726941
0.0735014
0.0743017
0.0750945
0.0758785
0.0766542
0.0457166
0.0458864
0.0461512
0.0465115
0.0469556
0.0474831
0.048081
0.04874
0.0494518
0.0502085
0.0510027
0.0518286
0.0526801
0.0535515
0.0544377
0.0553218
0.0562133
0.0571065
0.0579988
0.0588908
0.0597818
0.0606703
0.0615547
0.0624292
0.0632941
0.0641487
0.0649992
0.0658378
0.0666648
0.0674839
0.0682958
0.0690974
0.0698887
0.0706695
0.0714455
0.07221
0.0729648
0.0737119
0.0744512
0.0751818
0.0759044
0.0766148
0.0773164
0.0479895
0.0481564
0.0484065
0.048763
0.0491822
0.0496937
0.0502685
0.0509037
0.0515891
0.0523185
0.0530849
0.0538839
0.0547095
0.0555504
0.0564075
0.0572353
0.0580975
0.0589484
0.0598023
0.0606583
0.0615135
0.0623661
0.0632149
0.0640417
0.0648656
0.0656701
0.0664829
0.067268
0.0680472
0.0688197
0.069587
0.0703353
0.0710775
0.0718018
0.0725302
0.0732342
0.0739333
0.0746259
0.0753094
0.075978
0.07664
0.0772867
0.0779272
0.0271349
0.0262825
0.0254242
0.0245612
0.0236947
0.022826
0.0219565
0.0210874
0.0202204
0.0193566
0.0184976
0.0176448
0.0167996
0.0159637
0.0151384
0.0143251
0.0135254
0.0127408
0.0119723
0.0112216
0.0104897
0.00977778
0.0090869
0.00841795
0.0077717
0.00714883
0.00654972
0.00597488
0.0054246
0.00489896
0.00439808
0.00392192
0.0034704
0.00304331
0.00264033
0.00226111
0.00190511
0.00157176
0.00126062
0.000971237
0.000703408
0.000455374
0.000250656
0.0271411
0.0263546
0.0255623
0.0247652
0.0239642
0.0231602
0.0223544
0.0215475
0.0207405
0.0199345
0.0191306
0.0183296
0.0175327
0.016741
0.0159555
0.0151775
0.0144079
0.0136481
0.012899
0.012162
0.0114382
0.0107285
0.0100342
0.00935603
0.00869527
0.0080527
0.00742915
0.00682527
0.00624184
0.00567937
0.00513832
0.00461904
0.00412188
0.00364706
0.00319465
0.00276474
0.00235734
0.00197236
0.00160981
0.00126952
0.00095061
0.000647996
0.000418651
0.0271486
0.0264262
0.0256972
0.0249629
0.0242239
0.0234811
0.022735
0.0219863
0.0212356
0.0204836
0.019731
0.0189785
0.0182268
0.0174768
0.0167291
0.0159846
0.0152443
0.0145091
0.0137798
0.0130576
0.0123434
0.0116382
0.0109431
0.0102591
0.00958738
0.00892881
0.00828447
0.00765527
0.00704218
0.00644597
0.00586746
0.00530735
0.00476632
0.00424497
0.0037438
0.0032634
0.00280429
0.00236694
0.00195182
0.00155915
0.00118702
0.000828011
0.000566586
0.0271587
0.0264934
0.0258218
0.0251442
0.0244613
0.0237733
0.0230809
0.0223842
0.0216838
0.02098
0.0202732
0.019564
0.0188529
0.0181402
0.0174268
0.0167131
0.0159998
0.0152877
0.0145774
0.0138699
0.013166
0.0124667
0.0117729
0.0110857
0.0104061
0.0097351
0.00907391
0.00842345
0.00778491
0.00715928
0.00654765
0.00595091
0.00537013
0.00480621
0.00426007
0.00373273
0.00322514
0.00273832
0.00227329
0.0018303
0.00140659
0.000993574
0.000698985
0.0271709
0.0265564
0.0259359
0.0253092
0.0246763
0.0240373
0.0233925
0.022742
0.0220861
0.0214249
0.0207588
0.0200879
0.0194127
0.0187335
0.0180506
0.0173645
0.0166756
0.0159846
0.015292
0.0145985
0.0139049
0.013212
0.0125206
0.0118319
0.0111466
0.010466
0.00979101
0.00912284
0.00846271
0.00781173
0.00717117
0.00654221
0.00592611
0.00532407
0.00473738
0.00416736
0.00361542
0.00308306
0.00257162
0.00208151
0.00160868
0.00114042
0.000816749
0.0271831
0.0266149
0.0260404
0.0254591
0.0248707
0.0242754
0.0236729
0.0230635
0.0224471
0.0218238
0.0211935
0.0205566
0.0199132
0.0192634
0.0186077
0.0179462
0.0172793
0.0166075
0.015931
0.0152506
0.0145668
0.0138803
0.0131919
0.0125027
0.0118133
0.011125
0.0104388
0.00975585
0.00907734
0.00840455
0.00773877
0.00708152
0.00643419
0.00579827
0.00517524
0.00456688
0.00397479
0.00340084
0.00284686
0.00231311
0.00179468
0.00128119
0.000923209
0.0271941
0.0266687
0.0261357
0.0255949
0.0250463
0.0244898
0.0239252
0.0233524
0.0227712
0.0221816
0.0215835
0.0209765
0.0203611
0.0197375
0.0191057
0.0184663
0.0178193
0.017165
0.0165034
0.0158352
0.0151608
0.0144804
0.0137953
0.0131061
0.0124138
0.0117194
0.0110239
0.0103285
0.00963423
0.00894253
0.00825471
0.0075725
0.00689746
0.00623122
0.00557573
0.00493277
0.00430438
0.00369285
0.00310012
0.00252643
0.00196657
0.00141315
0.0010208
0.0272048
0.0267182
0.0262225
0.0257176
0.025204
0.0246822
0.0241518
0.0236117
0.0230623
0.0225035
0.0219346
0.0213545
0.0207641
0.0201631
0.0195523
0.0189321
0.0183036
0.0176661
0.0170185
0.0163626
0.0156979
0.015024
0.0143419
0.0136532
0.012959
0.0122599
0.0115571
0.0108514
0.0101443
0.00943677
0.00872908
0.00802384
0.00732356
0.00662994
0.00594463
0.00526989
0.00460816
0.00396148
0.00333202
0.00272049
0.00212125
0.00153022
0.00110685
0.0272186
0.0267642
0.0263012
0.0258273
0.0253433
0.0248521
0.0243539
0.0238438
0.0233224
0.0227926
0.0222539
0.0216979
0.0211305
0.0205488
0.0199557
0.0193506
0.0187376
0.0181217
0.0174865
0.0168438
0.0161932
0.0155283
0.0148494
0.0141614
0.0134667
0.0127647
0.0120583
0.0113463
0.0106298
0.00991676
0.00919461
0.00846572
0.00774339
0.00702628
0.00631581
0.00561369
0.00492304
0.00425061
0.00358842
0.00293739
0.00230064
0.00167368
0.0012015
0.000326023
0.000511742
0.000751251
0.000980216
0.00119919
0.00140864
0.00160949
0.00180274
0.00198965
0.00217151
0.00234975
0.00252591
0.0027016
0.00287874
0.00305948
0.00324671
0.00344422
0.0036575
0.0038945
0.00416555
0.00447814
0.00483128
0.0052206
0.00564272
0.00609575
0.0065787
0.00709133
0.00763369
0.00820619
0.0088094
0.009444
0.0101104
0.0108091
0.0115406
0.0123058
0.0131056
0.0139408
0.0148126
0.0157218
0.0166694
0.0176563
0.0186837
0.0197525
0.000464791
0.000674866
0.000922264
0.0011625
0.00139155
0.00160942
0.00181727
0.00201658
0.00220905
0.00239647
0.00258066
0.00276368
0.00294782
0.00313586
0.00333116
0.00353807
0.00376212
0.0040104
0.0042913
0.00461121
0.00496709
0.00535455
0.00577056
0.00621321
0.00668147
0.00717501
0.00769373
0.00823785
0.00880772
0.00940381
0.0100264
0.0106758
0.0113524
0.0120569
0.0127897
0.013552
0.0143443
0.0151673
0.016022
0.016909
0.0178294
0.0187836
0.0197712
0.000594362
0.000815886
0.00107217
0.00132335
0.00156242
0.00178885
0.00200407
0.0022101
0.00240917
0.00260363
0.00279595
0.00298899
0.00318598
0.00339082
0.00360803
0.00384286
0.00410132
0.00439015
0.00471588
0.00507634
0.00546552
0.0058798
0.00631714
0.00677647
0.00725726
0.00775927
0.00828253
0.00882725
0.00939358
0.0099818
0.010592
0.0112244
0.0118793
0.0125574
0.0132589
0.0139848
0.0147355
0.0155116
0.0163138
0.0171427
0.0179988
0.0188827
0.0197949
0.00071018
0.000936406
0.00120077
0.00146169
0.00170982
0.00194428
0.0021668
0.00237993
0.00258651
0.00278958
0.00299247
0.00319895
0.00341325
0.00364013
0.00388457
0.00415168
0.00444673
0.00477549
0.00513937
0.00553105
0.00594574
0.00638083
0.006835
0.00730759
0.00779818
0.00830658
0.00883286
0.00937704
0.0099391
0.010519
0.0111169
0.0117329
0.0123674
0.0130206
0.0136931
0.0143852
0.0150973
0.01583
0.0165837
0.0173588
0.018156
0.0189761
0.0198195
0.000812407
0.00104019
0.00131158
0.00158101
0.00183727
0.00207918
0.00230887
0.00252945
0.00274448
0.00295778
0.00317363
0.00339669
0.00363189
0.00388423
0.00415828
0.00445825
0.00478849
0.00515331
0.00554722
0.00596339
0.00639834
0.00685023
0.00731815
0.00780151
0.00829995
0.00881325
0.0093414
0.00988414
0.0104414
0.011013
0.011599
0.0121995
0.0128147
0.013445
0.0140906
0.0147516
0.0154283
0.0161213
0.0168309
0.0175573
0.0183014
0.0190646
0.0198511
0.000902708
0.00113041
0.00140783
0.00168475
0.0019483
0.0021972
0.00243394
0.00266238
0.00288677
0.00311187
0.00334281
0.00358487
0.00384321
0.00412239
0.00442605
0.00475732
0.00512004
0.0055147
0.00593268
0.00636879
0.00682047
0.0072864
0.00776575
0.00825804
0.00876285
0.00927992
0.00980903
0.0103498
0.010902
0.0114654
0.0120403
0.0126263
0.0132238
0.0138328
0.0144536
0.015086
0.0157306
0.0163874
0.0170568
0.0177391
0.018435
0.0191454
0.0198705
0.00098244
0.00120902
0.00149184
0.00177543
0.00204563
0.00230111
0.00254496
0.00278168
0.0030164
0.00325468
0.00350221
0.00376472
0.00404698
0.0043527
0.00468434
0.00504432
0.00543623
0.00585505
0.00629282
0.00674568
0.00721159
0.00768953
0.00817865
0.00867855
0.00918873
0.00970881
0.0102382
0.0107767
0.0113239
0.0118796
0.0124439
0.0130167
0.0135977
0.0141872
0.014785
0.0153916
0.0160068
0.0166306
0.0172634
0.0179054
0.0185572
0.019219
0.0198906
0.00105504
0.00128088
0.00156747
0.00185635
0.00213235
0.00239407
0.0026449
0.00288998
0.00313531
0.00338716
0.003652
0.00393555
0.00424168
0.0045727
0.0049301
0.0053161
0.00573311
0.00617263
0.00662792
0.0070952
0.00757326
0.00806161
0.00855937
0.0090661
0.00958125
0.0101038
0.0106332
0.0111691
0.0117113
0.0122596
0.0128141
0.0133745
0.0139403
0.0145112
0.0150881
0.0156716
0.0162603
0.0168537
0.0174524
0.0180573
0.0186685
0.019286
0.0199098
0.00111099
0.00132935
0.00162321
0.00192065
0.0022039
0.00247178
0.00272961
0.00298481
0.00324326
0.00351317
0.00380133
0.00410887
0.00443687
0.00479036
0.00517117
0.00558228
0.0060248
0.00648654
0.00695548
0.00742808
0.00791547
0.00841316
0.00891898
0.00943338
0.00995472
0.0104774
0.0110054
0.0115375
0.0120729
0.0126134
0.0131593
0.0137085
0.0142577
0.0148089
0.0153663
0.0159328
0.0164972
0.0170597
0.017625
0.0181945
0.0187685
0.0193453
0.0199237
0.000605215
0.0021441
0.00385091
0.00547887
0.00698462
0.0083731
0.00966913
0.0109377
0.0122686
0.0136658
0.015107
0.0165769
0.0180666
0.0195711
0.021089
0.0226198
0.024163
0.0257182
0.0272843
0.0288605
0.0304467
0.0320421
0.033646
0.0352576
0.0368768
0.0385028
0.0401354
0.0417741
0.0434184
0.045068
0.0467223
0.0483809
0.0500431
0.0517084
0.0533764
0.0550462
0.056717
0.0583879
0.0600585
0.0617277
0.0633951
0.0650606
0.0667253
0.000369455
0.0018795
0.0031302
0.00431495
0.00549352
0.00666855
0.00783994
0.00902054
0.0102289
0.011463
0.0127025
0.0139355
0.0152386
0.0166667
0.0181743
0.0197296
0.0213164
0.0229261
0.0245538
0.0261965
0.0278522
0.0295191
0.0311957
0.0328812
0.0345742
0.0362743
0.0379806
0.0396923
0.0414088
0.0431295
0.044854
0.0465817
0.0483118
0.0500437
0.051777
0.0535108
0.0552441
0.0569766
0.0587073
0.0604353
0.0621602
0.0638814
0.0655988
0.000270226
0.00138485
0.00293088
0.00429338
0.00544851
0.00650004
0.00751129
0.00851931
0.00954388
0.0105925
0.0116641
0.0127594
0.0138932
0.0150738
0.0163086
0.0176932
0.0191943
0.0207676
0.0223879
0.0240414
0.0257195
0.0274167
0.0291299
0.0308564
0.0325939
0.0343409
0.0360958
0.0378575
0.039625
0.041397
0.0431733
0.0449528
0.0467346
0.0485181
0.0503023
0.0520863
0.0538697
0.0556515
0.0574307
0.0592064
0.060978
0.0627445
0.0645044
0.000243916
0.0012619
0.0026967
0.00420416
0.00550582
0.00663141
0.00763885
0.00857823
0.00948846
0.0103977
0.0113247
0.0122812
0.0132738
0.0143067
0.0153881
0.0165367
0.017769
0.0191681
0.0206895
0.0222892
0.0239411
0.0256304
0.0273478
0.0290871
0.0308442
0.0326157
0.0343993
0.036193
0.0379949
0.0398039
0.0416185
0.0434374
0.0452597
0.0470843
0.0489102
0.0507363
0.0525618
0.0543857
0.0562067
0.0580242
0.0598369
0.0616437
0.0634426
0.000213988
0.00113496
0.00242233
0.00393135
0.00537282
0.00663505
0.0077392
0.00872425
0.00962867
0.0104875
0.0113312
0.0121834
0.013061
0.0139754
0.0149351
0.0159467
0.0170204
0.0181792
0.0194695
0.020925
0.0224907
0.0241292
0.025818
0.0275439
0.0292982
0.0310749
0.0328699
0.03468
0.0365026
0.0383355
0.0401767
0.0420245
0.0438775
0.0457345
0.0475939
0.0494546
0.0513155
0.0531752
0.0550326
0.0568866
0.0587359
0.060579
0.062414
0.000195322
0.00105679
0.00225462
0.00369502
0.00517569
0.00653053
0.00773164
0.00879748
0.0097549
0.0106327
0.0114599
0.0122641
0.0130694
0.0138954
0.0147568
0.0156637
0.0166248
0.0176485
0.0187517
0.0199685
0.0213686
0.0229025
0.0245257
0.0262105
0.0279404
0.0297044
0.0314954
0.0333082
0.0351388
0.0369841
0.0388414
0.0407086
0.0425837
0.0444648
0.0463504
0.048239
0.0501289
0.0520188
0.0539074
0.0557932
0.0576747
0.0595504
0.0614175
0.000177404
0.000986907
0.00210499
0.00346384
0.00493973
0.00635495
0.00763674
0.00878243
0.00980897
0.0107376
0.0115914
0.0123949
0.0131729
0.0139482
0.014741
0.0155669
0.0164381
0.0173634
0.0183517
0.0194172
0.0205946
0.0219552
0.0234654
0.0250771
0.0267593
0.0284926
0.0302649
0.0320677
0.0338951
0.0357427
0.0376069
0.0394849
0.0413741
0.0432721
0.0451771
0.0470871
0.0490003
0.0509151
0.05283
0.0547431
0.0566531
0.0585588
0.0604603
0.000162684
0.000930902
0.00198518
0.00327089
0.00470861
0.00614813
0.0074875
0.00870064
0.00979343
0.0107807
0.0116799
0.0125107
0.0132944
0.0140533
0.0148086
0.0155798
0.016383
0.0172308
0.0181329
0.0190988
0.0201434
0.021301
0.0226416
0.0241402
0.0257473
0.0274303
0.0291687
0.0309495
0.0327634
0.0346042
0.0364671
0.0383484
0.0402445
0.042153
0.0440711
0.0459968
0.047928
0.0498628
0.0517993
0.0537355
0.0556701
0.0576016
0.0595289
0.000149434
0.000882116
0.00188111
0.00310126
0.00448886
0.00592784
0.00730473
0.00857193
0.00972325
0.0107671
0.0117166
0.0125872
0.0133961
0.0141625
0.0149067
0.0156484
0.0164062
0.0171957
0.01803
0.0189193
0.0198738
0.0209092
0.0220618
0.0234015
0.0249008
0.0265109
0.0281994
0.0299457
0.0317362
0.0335619
0.035416
0.0372936
0.0391905
0.0411033
0.0430292
0.0449656
0.0469099
0.04886
0.0508137
0.0527692
0.0547246
0.0566784
0.0586284
0.000137646
0.000839792
0.00179096
0.00295355
0.00428773
0.00570763
0.00710373
0.0084116
0.0096123
0.0107074
0.0117062
0.0126202
0.0134636
0.0142522
0.0150035
0.0157362
0.0164691
0.0172194
0.0180025
0.018831
0.0197157
0.0206673
0.0217032
0.022865
0.0242201
0.025731
0.0273512
0.0290499
0.030807
0.0326094
0.0344478
0.0363156
0.0382075
0.0401195
0.0420483
0.0439906
0.0459436
0.0479049
0.049872
0.0518431
0.053816
0.0557898
0.0577647
0.000127011
0.000802229
0.00171126
0.00282279
0.00410513
0.00549474
0.00689469
0.00823084
0.00947174
0.0106119
0.0116561
0.0126133
0.0134946
0.0143127
0.0150828
0.0158212
0.0165456
0.0172734
0.018021
0.0188032
0.0196322
0.0205188
0.021475
0.0225214
0.0237077
0.0250902
0.0266213
0.0282575
0.0299704
0.0317412
0.0335571
0.0354093
0.0372913
0.0391978
0.0411249
0.043069
0.0450267
0.0469954
0.0489725
0.0509556
0.0529426
0.0549316
0.0569203
0.00011739
0.000768773
0.00164013
0.00270606
0.00393963
0.00529327
0.00668519
0.00803812
0.00931051
0.0104891
0.0115743
0.0125722
0.0134914
0.0143424
0.0151377
0.0158915
0.0166194
0.0173383
0.0180644
0.0188135
0.0195993
0.0204339
0.0213283
0.0222962
0.0233633
0.0245902
0.0260082
0.0275653
0.0292222
0.0309526
0.0327392
0.0345704
0.0364375
0.0383344
0.0402559
0.0421978
0.0441567
0.0461296
0.0481133
0.0501054
0.0521033
0.0541048
0.0561078
0.000108636
0.000738615
0.00157614
0.00260098
0.00378943
0.00510483
0.00647998
0.00783992
0.00913547
0.0103461
0.0114673
0.0125027
0.0134584
0.0143429
0.0151666
0.0159415
0.0166814
0.0174015
0.0181175
0.0188452
0.0195993
0.0203928
0.0212376
0.0221452
0.0231318
0.0242306
0.0255121
0.0269714
0.028559
0.0302396
0.0319902
0.0337948
0.0356426
0.0375257
0.0394379
0.0413745
0.0433315
0.0453053
0.0472926
0.0492906
0.0512967
0.053308
0.0553225
0.000100686
0.000711271
0.00151813
0.00250568
0.00365261
0.00492961
0.0062821
0.00764078
0.00895203
0.0101884
0.011341
0.01241
0.0133999
0.0143172
0.0151705
0.0159697
0.0167269
0.0174556
0.0181704
0.0188865
0.0196187
0.0203811
0.021186
0.0220452
0.0229712
0.0239845
0.0251306
0.0264743
0.0279786
0.0295995
0.0313065
0.0330789
0.0349029
0.0367684
0.0386681
0.0405964
0.0425485
0.0445204
0.0465086
0.0485101
0.0505215
0.0525405
0.0545636
9.34166e-05
0.000686313
0.00146526
0.00241883
0.00352752
0.00476709
0.00609332
0.00744406
0.00876411
0.0100206
0.0111999
0.0122989
0.0133201
0.0142686
0.0151512
0.0159762
0.016754
0.0174964
0.0182166
0.018929
0.0196481
0.0203879
0.0211617
0.0219816
0.0228594
0.02381
0.0248608
0.0260738
0.0274799
0.02903
0.0306854
0.0324198
0.0342154
0.0360597
0.0379438
0.0398608
0.0418054
0.0437729
0.0457597
0.0477622
0.049777
0.051801
0.0538302
8.67348e-05
0.000663404
0.0014168
0.00233924
0.00341257
0.00461636
0.00591444
0.00725218
0.00857506
0.00984634
0.0110478
0.0121732
0.013223
0.0142006
0.0151115
0.0159627
0.0167628
0.0175222
0.0182526
0.0189673
0.0196802
0.020405
0.0211554
0.0219438
0.0227823
0.0236836
0.0246663
0.0257688
0.0270619
0.0285293
0.0301246
0.0318148
0.0335774
0.0353968
0.0372622
0.0391654
0.0410999
0.043061
0.0450442
0.0470457
0.0490619
0.0510892
0.0531223
8.08453e-05
0.000642264
0.00137214
0.00226594
0.00330655
0.0044764
0.00574553
0.00706657
0.00838733
0.00966851
0.0108879
0.0120362
0.0131117
0.0141162
0.0150541
0.0159309
0.016754
0.0175324
0.0182764
0.018998
0.0197103
0.0204265
0.0211602
0.0219241
0.0227306
0.0235916
0.024522
0.0255471
0.026723
0.0280961
0.0296224
0.0312618
0.0329865
0.0347775
0.0366212
0.0385078
0.0404303
0.0423828
0.0443605
0.0463593
0.0483759
0.0504079
0.0524578
7.62004e-05
0.000622696
0.00133085
0.00219814
0.00320848
0.00434634
0.0055865
0.00688822
0.00820282
0.0094895
0.0107228
0.0118907
0.012989
0.0140183
0.0149813
0.0158828
0.016729
0.0175274
0.0182872
0.0190191
0.0197351
0.020448
0.0211707
0.0219162
0.022697
0.023525
0.0244132
0.0253803
0.0264624
0.02773
0.0291776
0.0307592
0.0324409
0.0341994
0.0360184
0.0378862
0.0397945
0.0417365
0.0437069
0.0457014
0.0477163
0.0497485
0.0517933
7.19077e-05
0.000604635
0.00129266
0.0021353
0.00311748
0.00422517
0.00543697
0.00671771
0.00802277
0.00931103
0.0105549
0.011739
0.0128574
0.0139091
0.0148956
0.0158207
0.0166893
0.0175081
0.0182851
0.0190297
0.0197528
0.0204664
0.0211831
0.0219155
0.022676
0.0234769
0.0243305
0.0252519
0.0262664
0.0274288
0.0287889
0.0303055
0.0319388
0.033661
0.0354522
0.0372988
0.0391908
0.0411205
0.0430819
0.0450706
0.0470825
0.0491153
0.0511709
6.79074e-05
0.0005877
0.0012571
0.0020769
0.00303276
0.00411199
0.00529615
0.00655501
0.0078478
0.00913453
0.0103854
0.011583
0.012719
0.0137907
0.0147989
0.0157462
0.0166366
0.0174757
0.0182705
0.0190294
0.0197621
0.0204798
0.0211944
0.0219182
0.0226635
0.0234425
0.0242673
0.0251513
0.0261138
0.0271921
0.0284557
0.0298995
0.0314789
0.0331605
0.0349209
0.0367438
0.0386175
0.0405331
0.0424842
0.0444653
0.0464719
0.0485001
0.0505425
6.41577e-05
0.000571878
0.00122381
0.00202228
0.00295358
0.00400607
0.00516368
0.0064001
0.00767874
0.00896105
0.0102161
0.0114243
0.0125753
0.0136651
0.0146932
0.0156612
0.0165724
0.0174315
0.0182443
0.0190184
0.0197626
0.020487
0.0212027
0.0219217
0.022656
0.0234177
0.0242187
0.0250717
0.0259927
0.0270086
0.0281762
0.0295404
0.03106
0.0326966
0.034423
0.0362198
0.038073
0.0399731
0.0419121
0.0438841
0.045884
0.0479072
0.0499496
6.06956e-05
0.000557103
0.00119271
0.00197122
0.00287947
0.00390675
0.00503885
0.00625287
0.00751588
0.00879142
0.0100479
0.0112642
0.0124281
0.0135338
0.01458
0.0155672
0.0164981
0.0173764
0.0182073
0.0189972
0.019754
0.0204871
0.0212067
0.021924
0.0226509
0.0233993
0.0241809
0.025008
0.0258948
0.0268619
0.0279499
0.0292273
0.030681
0.0322684
0.0339573
0.0357252
0.0375563
0.039439
0.0413645
0.043326
0.0453179
0.0473349
0.0493711
5.75004e-05
0.000543261
0.00116354
0.00192326
0.00280992
0.00381345
0.00492113
0.00611292
0.00735946
0.00862608
0.0098818
0.0111038
0.0122783
0.0133982
0.0144607
0.0154657
0.0164151
0.0173119
0.0181604
0.0189664
0.0197367
0.0204798
0.0212053
0.0219237
0.0226463
0.0233849
0.0241509
0.0249564
0.0258145
0.0267424
0.0277701
0.0289591
0.0303413
0.0318746
0.0335225
0.0352591
0.0370659
0.0389296
0.0408402
0.0427901
0.0447731
0.0467838
0.0488173
5.45028e-05
0.000530272
0.00113619
0.00187824
0.00274452
0.00372557
0.00480998
0.00597994
0.0072092
0.00846559
0.0097185
0.010944
0.0121271
0.0132592
0.0143364
0.0153579
0.0163247
0.017239
0.0181047
0.0189266
0.0197109
0.0204651
0.0211981
0.0219198
0.0226408
0.0233725
0.0241263
0.024914
0.025748
0.0266434
0.0276237
0.0287347
0.0300399
0.0315144
0.0331179
0.0348204
0.0366009
0.0384439
0.0403383
0.0422756
0.0442491
0.0462537
0.0482861
5.17251e-05
0.00051799
0.00111042
0.00183586
0.00268301
0.00364273
0.00470481
0.00585354
0.00706515
0.00831006
0.00955832
0.0107856
0.0119754
0.013118
0.0142084
0.0152449
0.0162278
0.0171589
0.0180411
0.0188787
0.0196772
0.0204432
0.021185
0.0219115
0.0226332
0.0233606
0.0241052
0.0248783
0.025692
0.0265602
0.0275019
0.0285517
0.0297762
0.0311872
0.0327424
0.0344082
0.0361602
0.0379809
0.0398579
0.0417815
0.0437446
0.0457418
0.0477692
4.91226e-05
0.000506438
0.00108607
0.00179585
0.00262481
0.00356445
0.00460531
0.00573327
0.0069272
0.00815966
0.0094018
0.0106291
0.0118239
0.0129753
0.0140775
0.0151277
0.0161256
0.0170724
0.0179705
0.0188234
0.019636
0.0204144
0.0211657
0.0218986
0.0226227
0.0233482
0.024086
0.0248475
0.0256443
0.0264893
0.0273991
0.0284009
0.0295488
0.0308921
0.0323955
0.0340215
0.0357428
0.0375397
0.039398
0.0413068
0.0432584
0.0452462
0.0472642
4.66975e-05
0.000495533
0.00106308
0.00175805
0.00256984
0.00349038
0.00451096
0.00561892
0.00679515
0.00801449
0.00924921
0.010475
0.0116733
0.0128321
0.0139444
0.015007
0.0160188
0.0169804
0.0178936
0.0187614
0.019588
0.0203788
0.0211405
0.0218808
0.0226088
0.0233342
0.0240677
0.02482
0.0256027
0.0264281
0.027311
0.0282736
0.0293573
0.0306286
0.0320763
0.0336597
0.0353483
0.0371196
0.0389577
0.0408506
0.0427895
0.0447671
0.0467773
4.44501e-05
0.00048522
0.00104131
0.0017222
0.00251774
0.00342015
0.00442138
0.00551
0.0066688
0.00787438
0.00910083
0.0103236
0.0115239
0.0126887
0.01381
0.0148838
0.0159083
0.0168837
0.0178112
0.0186934
0.0195337
0.0203371
0.0211095
0.0218581
0.0225912
0.0233182
0.0240491
0.0247946
0.0255658
0.0263745
0.0272345
0.0281646
0.0291975
0.0303961
0.0317843
0.0333222
0.0349757
0.0367197
0.0385363
0.0404122
0.0423374
0.0443042
0.0463061
4.2335e-05
0.000475484
0.00102074
0.00168827
0.00246838
0.00335354
0.00433626
0.00540617
0.00654766
0.00773935
0.00895655
0.0101753
0.0113763
0.0125456
0.0136747
0.0147585
0.0157948
0.016783
0.0177241
0.01862
0.0194738
0.0202897
0.021073
0.0218305
0.0225698
0.0232996
0.0240296
0.0247702
0.0255322
0.0263269
0.0271674
0.0280701
0.0290617
0.0301934
0.031519
0.0330084
0.0346245
0.0363393
0.0381331
0.0399909
0.0419016
0.0438567
0.0458486
4.03711e-05
0.000466184
0.00100117
0.00165605
0.00242145
0.00329019
0.00425528
0.00530715
0.00643162
0.00760921
0.00881649
0.0100302
0.0112306
0.0124034
0.013539
0.0146318
0.0156788
0.0166791
0.017633
0.018542
0.0194087
0.0202369
0.0210314
0.0217981
0.0225443
0.0232781
0.0240088
0.0247462
0.0255008
0.0262839
0.0271076
0.027987
0.0289442
0.0300199
0.0312798
0.0327177
0.0342939
0.035978
0.0377476
0.0395861
0.0414816
0.0434246
0.0454082
3.85164e-05
0.000457423
0.000982551
0.0016254
0.00237679
0.00322987
0.00417805
0.00521252
0.00632044
0.00748382
0.00868064
0.00988839
0.0110874
0.0122624
0.0134035
0.0145042
0.015561
0.0165723
0.0175382
0.0184598
0.0193391
0.0201793
0.0209849
0.0217612
0.0225149
0.0232536
0.0239861
0.0247218
0.025471
0.0262444
0.0270538
0.0279131
0.0288415
0.0298718
0.0310662
0.0324496
0.0339837
0.0356351
0.037379
0.0391973
0.0410767
0.043007
0.0449808
3.68162e-05
0.00044913
0.000964844
0.00159618
0.00233426
0.00317243
0.00410441
0.00512218
0.0062139
0.0073631
0.00854902
0.00975011
0.0109465
0.012123
0.0132685
0.014376
0.0154417
0.0164633
0.0174405
0.0183738
0.0192652
0.0201172
0.0209338
0.0217199
0.0224815
0.0232259
0.0239612
0.0246966
0.0254418
0.0262074
0.0270047
0.0278467
0.0287505
0.0297434
0.0308772
0.0322036
0.0336933
0.0353102
0.037027
0.0388239
0.0406862
0.0426028
0.0445653
3.52364e-05
0.000441345
0.000948057
0.00156838
0.00229375
0.00311763
0.00403415
0.00503577
0.00611183
0.00724681
0.00842169
0.0096153
0.0108084
0.0119853
0.0131342
0.0142479
0.0153214
0.0163525
0.0173402
0.0182848
0.0191877
0.0200512
0.0208786
0.0216745
0.0224444
0.023195
0.023934
0.0246702
0.0254128
0.0261722
0.0269593
0.0277864
0.0286691
0.0296303
0.0307124
0.0319795
0.0334223
0.0350027
0.036691
0.0384654
0.0403098
0.042212
0.0441627
3.37689e-05
0.000433935
0.00093206
0.00154196
0.00225513
0.00306533
0.00396692
0.00495306
0.00601369
0.0071348
0.00829828
0.00948408
0.0106731
0.0118494
0.013001
0.0141198
0.0152005
0.0162402
0.0172378
0.018193
0.0191069
0.0199814
0.0208195
0.0216253
0.0224037
0.0231609
0.0239044
0.0246422
0.0253836
0.0261382
0.0269168
0.0277311
0.0285953
0.0295298
0.0305692
0.0317767
0.0331702
0.0347122
0.0363706
0.0381214
0.0399468
0.0418338
0.0437717
3.23977e-05
0.000426963
0.000916748
0.00151665
0.00221819
0.00301531
0.00390267
0.00487378
0.00591951
0.00702684
0.00817884
0.00935639
0.0105407
0.0117157
0.0128691
0.0139922
0.0150793
0.016127
0.0171337
0.0180989
0.0190233
0.0199085
0.020757
0.0215724
0.0223595
0.0231238
0.0238723
0.0246127
0.0253537
0.0261048
0.0268764
0.0276797
0.028528
0.0294395
0.0304434
0.0315944
0.0329366
0.0344385
0.0360654
0.0377913
0.039597
0.0414679
0.0433926
3.11335e-05
0.000420406
0.000902132
0.00149247
0.00218285
0.00296743
0.00384109
0.00479781
0.00582904
0.00692285
0.00806325
0.00923224
0.0104112
0.0115843
0.0127387
0.0138653
0.014958
0.016013
0.0170281
0.0180027
0.0189372
0.0198326
0.0206913
0.0215163
0.022312
0.0230837
0.0238376
0.0245813
0.0253229
0.0260717
0.0268376
0.0276315
0.028466
0.0293575
0.030331
0.0314323
0.0327214
0.0341811
0.035775
0.0374749
0.03926
0.0411146
0.0430273
2.99941e-05
0.000414268
0.000888155
0.00146928
0.00214899
0.00292156
0.00378206
0.00472486
0.00574213
0.00682251
0.00795141
0.00911141
0.0102847
0.0114552
0.0126099
0.0137394
0.0148369
0.0158984
0.0169215
0.017905
0.0188488
0.0197541
0.0206226
0.0214571
0.0222615
0.0230407
0.0238005
0.024548
0.025291
0.0260385
0.0267999
0.0275859
0.0284084
0.0292824
0.03023
0.0312892
0.0325241
0.0339397
0.035499
0.0371719
0.0389355
0.0407733
0.0426735
2.8967e-05
0.000408589
0.000874856
0.00144714
0.00211656
0.00287757
0.00372545
0.00465481
0.00565841
0.0067258
0.00784323
0.008994
0.0101611
0.0113284
0.0124828
0.0136145
0.0147163
0.0157837
0.016814
0.0178058
0.0187587
0.0196733
0.0205513
0.0213951
0.0222081
0.0229948
0.0237608
0.0245127
0.0252579
0.0260048
0.0267629
0.0275423
0.0283544
0.0292133
0.0301383
0.0311622
0.0323441
0.033714
0.0352373
0.0368818
0.038623
0.0404427
0.0423269
2.80716e-05
0.000403277
0.000862137
0.00142597
0.00208558
0.00283542
0.00367106
0.00458751
0.00557782
0.00663246
0.0077384
0.00887995
0.0100404
0.0112041
0.0123576
0.0134908
0.0145963
0.0156691
0.016706
0.0177055
0.0186669
0.0195905
0.0204777
0.0213304
0.022152
0.0229464
0.0237188
0.0244754
0.0252233
0.0259706
0.0267263
0.0275001
0.0283033
0.0291488
0.0300544
0.031048
0.0321811
0.0335036
0.0349894
0.0366044
0.0383222
0.0401231
0.0419924
2.7286e-05
0.000398373
0.00084996
0.00140565
0.00205574
0.00279491
0.00361883
0.00452272
0.00550023
0.00654236
0.00763694
0.00876911
0.00992271
0.0110822
0.0122344
0.0133686
0.0144771
0.0155546
0.0165977
0.0176044
0.0185738
0.019506
0.0204019
0.0212635
0.0220935
0.0228956
0.0236745
0.0244362
0.0251873
0.0259356
0.0266897
0.0274592
0.0282546
0.0290885
0.0299769
0.0309444
0.0320346
0.0333084
0.0347552
0.0363394
0.0380328
0.0398144
0.0416685
2.66285e-05
0.000393791
0.000838284
0.00138612
0.00202708
0.00275599
0.00356859
0.00446042
0.00542545
0.00645539
0.00753868
0.00866144
0.00980789
0.0109629
0.0121131
0.0132478
0.0143587
0.0154405
0.0164892
0.0175026
0.0184795
0.0194199
0.0203243
0.0211944
0.0220326
0.0228424
0.0236281
0.024395
0.0251498
0.0258997
0.026653
0.027419
0.0282079
0.0290316
0.0299049
0.0308496
0.0319033
0.033128
0.0345343
0.0360864
0.0377546
0.039516
0.0413537
2.61361e-05
0.000389538
0.000827113
0.00136737
0.00199954
0.00271851
0.0035202
0.00440037
0.00535341
0.00637131
0.00744358
0.00855676
0.00969591
0.0108461
0.011994
0.0131285
0.0142415
0.0153268
0.0163806
0.0174003
0.0183843
0.0193324
0.020245
0.0211234
0.0219696
0.022787
0.0235794
0.024352
0.0251107
0.0258628
0.026616
0.0273794
0.0281628
0.0289775
0.0298376
0.0307625
0.0317847
0.0329621
0.0343264
0.0358454
0.0374872
0.0392279
0.0410496
2.58048e-05
0.000385625
0.000816467
0.00134944
0.00197311
0.00268252
0.00347365
0.0043425
0.00528378
0.00629008
0.00735143
0.00845504
0.0095867
0.0107317
0.0118768
0.0130108
0.0141253
0.0152139
0.0162723
0.0172977
0.0182885
0.0192439
0.0201643
0.0210506
0.0219048
0.0227296
0.0235288
0.0243071
0.0250702
0.0258248
0.0265786
0.0273401
0.0281189
0.0289259
0.0297742
0.0306817
0.0316767
0.0328102
0.0341314
0.0356159
0.0372304
0.0389489
0.040751
2.56552e-05
0.000381948
0.000806265
0.00133219
0.00194771
0.0026478
0.00342881
0.00428672
0.00521656
0.00621154
0.00726211
0.00835629
0.00948027
0.0106198
0.0117618
0.0128949
0.0140104
0.0151017
0.0161643
0.017195
0.018192
0.0191544
0.0200823
0.0209763
0.0218382
0.0226704
0.0234763
0.0242605
0.0250281
0.0257857
0.0265405
0.0273008
0.0280759
0.0288762
0.0297142
0.0306062
0.0315774
0.032672
0.0339491
0.0353978
0.0369839
0.0386797
0.0404646
2.56565e-05
0.000378529
0.000796494
0.00131562
0.0019232
0.00261441
0.00338555
0.00423286
0.00515166
0.00613555
0.00717553
0.00826031
0.00937655
0.0105104
0.0116489
0.0127806
0.0138967
0.0149904
0.0160567
0.0170923
0.0180952
0.0190642
0.0199992
0.0209006
0.0217699
0.0226094
0.0234221
0.0242121
0.0249846
0.0257454
0.0265018
0.0272616
0.0280336
0.0288282
0.029657
0.0305354
0.0314857
0.0325464
0.033779
0.0351908
0.0367475
0.0384197
0.0401849
2.583e-05
0.000375297
0.000787142
0.00129968
0.00189963
0.00258222
0.00334381
0.00418085
0.00508897
0.006062
0.00709159
0.00816697
0.00927539
0.0104034
0.0115381
0.0126681
0.0137845
0.01488
0.0159496
0.0169897
0.0179981
0.0189734
0.0199151
0.0208237
0.0217003
0.0225468
0.0233662
0.0241622
0.0249396
0.0257041
0.0264623
0.0272221
0.0279919
0.0287815
0.0296023
0.0304685
0.0314004
0.0324318
0.033621
0.0349948
0.0365209
0.0381683
0.0399122
2.61577e-05
0.000372259
0.000778197
0.00128435
0.00187691
0.00255113
0.0033035
0.00413064
0.00502834
0.0059908
0.0070102
0.00807625
0.00917679
0.0102988
0.0114294
0.0125574
0.0136736
0.0147706
0.0158431
0.0168874
0.0179008
0.018882
0.0198302
0.0207457
0.0216293
0.0224828
0.0233088
0.0241107
0.0248932
0.0256615
0.0264221
0.0271823
0.0279504
0.0287359
0.0295496
0.0304051
0.0313207
0.0323264
0.0334748
0.0348096
0.0363043
0.0379269
0.0396524
2.66232e-05
0.000369396
0.000769647
0.00126962
0.00185501
0.00252113
0.00326458
0.00408207
0.00496961
0.00592181
0.00693118
0.00798801
0.00908066
0.0101964
0.0113228
0.0124485
0.0135642
0.0146623
0.0157374
0.0167854
0.0178036
0.0187903
0.0197447
0.0206667
0.0215571
0.0224174
0.0232499
0.0240578
0.0248454
0.0256178
0.026381
0.0271421
0.0279091
0.0286912
0.0294988
0.0303446
0.0312457
0.0322287
0.0333402
0.0346351
0.0360976
0.0376949
0.0394009
2.72089e-05
0.000366686
0.000761472
0.00125544
0.0018339
0.00249219
0.00322696
0.00403508
0.00491278
0.00585494
0.00685449
0.00790224
0.00898698
0.0100964
0.0112183
0.0123414
0.0134562
0.0145551
0.0156324
0.0166838
0.0177064
0.0186984
0.0196586
0.020587
0.0214839
0.0223508
0.0231897
0.0240036
0.0247964
0.0255729
0.026339
0.0271014
0.0278678
0.0286471
0.0294494
0.0302866
0.0311748
0.0321378
0.0332166
0.0344711
0.0359006
0.0374719
0.0391582
2.79025e-05
0.000364115
0.000753658
0.00124181
0.00181352
0.00246423
0.00319061
0.00398965
0.00485779
0.00579014
0.00678005
0.00781882
0.00889565
0.00999866
0.0111159
0.0122361
0.0133498
0.0144492
0.0155283
0.0165827
0.0176094
0.0186063
0.0195721
0.0205065
0.0214098
0.0222831
0.0231283
0.0239481
0.0247461
0.025527
0.0262962
0.0270602
0.0278265
0.0286036
0.0294012
0.0302309
0.0311075
0.0320527
0.0331028
0.0343174
0.0357128
0.0372565
0.0389198
2.86836e-05
0.00036168
0.000746195
0.00122868
0.00179387
0.00243721
0.00315545
0.00394569
0.00480452
0.0057273
0.00670778
0.00773763
0.00880657
0.00990312
0.0110155
0.0121326
0.0132449
0.0143444
0.015425
0.0164823
0.0175127
0.0185142
0.0194853
0.0204254
0.0213348
0.0222144
0.0230657
0.0238914
0.0246947
0.02548
0.0262525
0.0270185
0.0277851
0.0285605
0.0293541
0.0301771
0.0310433
0.0319727
0.0329975
0.0341736
0.0355335
0.0370479
0.0386839
2.95423e-05
0.000359364
0.000739066
0.00121605
0.0017749
0.00241108
0.00312142
0.00390311
0.00475285
0.00566632
0.00663757
0.00765862
0.00871972
0.00980972
0.0109171
0.0120309
0.0131415
0.0142409
0.0153228
0.0163824
0.0174163
0.0184221
0.0193982
0.0203439
0.0212592
0.0221448
0.0230021
0.0238335
0.0246421
0.025432
0.026208
0.0269762
0.0277434
0.0285177
0.0293079
0.0301249
0.0309819
0.031897
0.0328994
0.0340394
0.0353633
0.0368483
0.0384621
3.04613e-05
0.000357161
0.000732258
0.00120389
0.00175658
0.00238581
0.00308848
0.00386183
0.00470274
0.00560712
0.00656931
0.00758171
0.008635
0.00971839
0.0108206
0.011931
0.0130397
0.0141386
0.0152215
0.0162833
0.0173204
0.0183302
0.019311
0.020262
0.0211829
0.0220744
0.0229376
0.0237747
0.0245885
0.0253829
0.0261626
0.0269332
0.0277015
0.0284749
0.0292624
0.0300742
0.0309228
0.0318252
0.0328075
0.0339149
0.0352023
0.036658
0.0382506
3.14309e-05
0.00035506
0.000725756
0.00119219
0.00173888
0.00236136
0.00305656
0.00382181
0.00465413
0.00554965
0.00650293
0.00750685
0.00855239
0.00962915
0.0107262
0.0118328
0.0129394
0.0140377
0.0151213
0.0161849
0.0172249
0.0182384
0.0192237
0.0201797
0.0211061
0.0220032
0.0228722
0.0237149
0.0245339
0.025333
0.0261164
0.0268897
0.0276592
0.0284323
0.0292175
0.0300247
0.0308658
0.0317567
0.0327211
0.0337994
0.0350502
0.0364756
0.0380443
3.24412e-05
0.000353059
0.000719547
0.00118092
0.00172178
0.00233769
0.00302563
0.00378301
0.00460699
0.00549382
0.0064384
0.00743393
0.00847176
0.00954192
0.0106336
0.0117364
0.0128406
0.0139381
0.0150221
0.0160873
0.0171299
0.0181469
0.0191364
0.0200972
0.0210288
0.0219315
0.022806
0.0236542
0.0244784
0.0252821
0.0260694
0.0268455
0.0276165
0.0283897
0.0291731
0.0299762
0.0308106
0.0316912
0.0326395
0.0336919
0.0349061
0.036299
0.0378367
3.34878e-05
0.000351155
0.000713621
0.00117006
0.00170525
0.00231478
0.00299566
0.00374539
0.00456122
0.00543959
0.00637566
0.00736291
0.00839313
0.00945665
0.0105429
0.0116417
0.0127434
0.0138398
0.0149239
0.0159905
0.0170355
0.0180557
0.0190492
0.0200146
0.0209512
0.0218591
0.0227391
0.0235927
0.024422
0.0252303
0.0260216
0.0268007
0.0275735
0.028347
0.029129
0.0299287
0.0307571
0.0316283
0.0325622
0.0335913
0.0347703
0.0361306
0.0376447
3.45579e-05
0.000349338
0.000707962
0.0011596
0.00168927
0.00229258
0.00296659
0.00370883
0.00451671
0.00538684
0.00631457
0.00729369
0.00831636
0.00937322
0.0104541
0.0115488
0.0126478
0.0137428
0.0148269
0.0158946
0.0169417
0.0179649
0.0189621
0.0199319
0.0208733
0.0217863
0.0226716
0.0235304
0.0243648
0.0251778
0.025973
0.0267552
0.0275301
0.0283041
0.0290851
0.0298819
0.0307049
0.0315676
0.0324885
0.0334967
0.0346423
0.0359687
0.0374504
3.56456e-05
0.000347604
0.000702553
0.00114953
0.00167382
0.00227109
0.0029384
0.00367338
0.0044735
0.00533557
0.00625512
0.00722627
0.00824146
0.00929166
0.010367
0.0114575
0.0125536
0.0136471
0.014731
0.0157996
0.0168486
0.0178746
0.0188753
0.0198491
0.0207951
0.0217131
0.0226035
0.0234675
0.0243069
0.0251245
0.0259237
0.0267092
0.0274862
0.0282611
0.0290414
0.0298357
0.030654
0.031509
0.032418
0.0334074
0.0345229
0.0358169
0.0372776
3.67426e-05
0.000345944
0.000697386
0.00113982
0.00165888
0.00225025
0.00291104
0.00363894
0.00443151
0.00528567
0.00619723
0.00716055
0.00816835
0.00921194
0.0102818
0.0113679
0.012461
0.0135528
0.0146362
0.0157055
0.0167561
0.0177847
0.0187887
0.0197664
0.0207168
0.0216396
0.022535
0.0234039
0.0242483
0.0250704
0.0258737
0.0266625
0.0274419
0.0282179
0.0289979
0.02979
0.0306041
0.0314522
0.0323504
0.0333231
0.0344117
0.0356737
0.0371091
3.78486e-05
0.000344361
0.000692447
0.00113046
0.00164441
0.00223004
0.00288449
0.00360548
0.00439069
0.00523714
0.00614084
0.00709643
0.00809693
0.00913397
0.0101982
0.0112799
0.0123699
0.0134599
0.0145426
0.0156123
0.0166643
0.0176953
0.0187023
0.0196838
0.0206384
0.0215657
0.022466
0.0233398
0.024189
0.0250157
0.0258231
0.0266153
0.0273971
0.0281745
0.0289544
0.0297449
0.0305552
0.0313971
0.0322857
0.0332435
0.0343083
0.0355386
0.036948
3.89546e-05
0.000342848
0.000687727
0.00112144
0.00163042
0.00221045
0.0028587
0.00357296
0.00435097
0.0051899
0.00608595
0.00703393
0.00802721
0.00905773
0.0101163
0.0111935
0.0122803
0.0133682
0.0144501
0.01552
0.0165734
0.0176064
0.0186163
0.0196013
0.0205599
0.0214917
0.0223965
0.0232752
0.0241291
0.0249603
0.0257718
0.0265674
0.0273519
0.0281308
0.028911
0.0297001
0.0305072
0.0313435
0.0322235
0.033168
0.0342117
0.0354115
0.0367953
4.00602e-05
0.000341405
0.000683209
0.00111274
0.00161686
0.00219144
0.00283365
0.00354134
0.00431232
0.0051439
0.00603241
0.00697292
0.00795908
0.00898307
0.010036
0.0111087
0.0121921
0.0132778
0.0143587
0.0154288
0.0164832
0.0175181
0.0185307
0.019519
0.0204814
0.0214174
0.0223268
0.0232102
0.0240687
0.0249043
0.0257199
0.026519
0.0273062
0.0280869
0.0288675
0.0296556
0.03046
0.0312914
0.0321635
0.0330961
0.0341206
0.03529
0.036642
4.11559e-05
0.000340021
0.000678886
0.00110434
0.00160374
0.00217299
0.00280931
0.00351059
0.00427471
0.00509907
0.00598021
0.00691343
0.00789255
0.00891005
0.00995742
0.0110255
0.0121054
0.0131888
0.0142686
0.0153385
0.0163938
0.0174304
0.0184455
0.0194369
0.020403
0.0213431
0.0222568
0.0231447
0.0240078
0.0248478
0.0256675
0.0264701
0.0272601
0.0280427
0.028824
0.0296114
0.0304134
0.0312405
0.0321056
0.0330272
0.0340341
0.0351744
0.036494
4.22397e-05
0.000338694
0.000674743
0.00109625
0.00159103
0.00215508
0.00278566
0.00348068
0.0042381
0.00505542
0.00592934
0.00685537
0.00782755
0.00883864
0.00988037
0.0109438
0.0120201
0.0131011
0.0141795
0.0152492
0.0163051
0.0173433
0.0183607
0.019355
0.0203246
0.0212686
0.0221866
0.0230789
0.0239464
0.0247908
0.0256145
0.0264207
0.0272136
0.0279982
0.0287804
0.0295674
0.0303675
0.0311906
0.0320494
0.0329609
0.0339515
0.0350649
0.0363531
4.33133e-05
0.000337429
0.00067077
0.00108843
0.00157872
0.0021377
0.00276266
0.00345157
0.00420244
0.00501288
0.00587973
0.00679865
0.00776399
0.00876875
0.00980482
0.0108635
0.0119362
0.0130146
0.0140916
0.0151609
0.0162173
0.0172569
0.0182764
0.0192735
0.0202464
0.0211941
0.0221162
0.0230128
0.0238846
0.0247333
0.025561
0.0263708
0.0271667
0.0279534
0.0287368
0.0295237
0.0303221
0.0311418
0.0319946
0.0328969
0.0338727
0.0349617
0.036219
4.43736e-05
0.000336212
0.000666963
0.00108088
0.00156678
0.00212082
0.0027403
0.00342323
0.0041677
0.00497141
0.00583134
0.00674329
0.00770187
0.00870032
0.00973076
0.0107848
0.0118537
0.0129295
0.0140049
0.0150736
0.0161304
0.0171711
0.0181926
0.0191923
0.0201683
0.0211196
0.0220457
0.0229464
0.0238225
0.0246754
0.0255071
0.0263205
0.0271194
0.0279084
0.028693
0.02948
0.0302772
0.0310937
0.0319413
0.032835
0.0337973
0.0348644
0.0360916
4.54158e-05
0.00033505
0.00066331
0.00107359
0.00155521
0.00210441
0.00271854
0.00339564
0.00413385
0.00493096
0.00578407
0.0066892
0.00764113
0.00863332
0.00965819
0.0107074
0.0117726
0.0128456
0.0139193
0.0149873
0.0160443
0.0170861
0.0181093
0.0191114
0.0200904
0.0210452
0.021975
0.0228798
0.0237601
0.024617
0.0254527
0.0262697
0.0270717
0.027863
0.0286492
0.0294365
0.0302326
0.0310464
0.0318891
0.0327751
0.0337251
0.0347725
0.0359713
4.64418e-05
0.000333936
0.000659802
0.00106655
0.00154399
0.00208847
0.00269737
0.00336876
0.00410085
0.00489153
0.00573796
0.00663638
0.00758174
0.00856775
0.00958705
0.0106315
0.0116928
0.012763
0.0138348
0.0149019
0.015959
0.0170017
0.0180265
0.0190309
0.0200128
0.0209709
0.0219043
0.022813
0.0236973
0.0245584
0.0253979
0.0262185
0.0270236
0.0278174
0.0286051
0.029393
0.0301883
0.0309998
0.0318381
0.032717
0.0336558
0.0346856
0.0358573
4.74508e-05
0.000332867
0.00065643
0.00105974
0.00153311
0.00207297
0.00267676
0.00334258
0.00406868
0.00485304
0.00569294
0.00658474
0.00752364
0.00850354
0.00951727
0.0105569
0.0116143
0.0126816
0.0137515
0.0148176
0.0158746
0.016918
0.0179443
0.0189508
0.0199354
0.0208966
0.0218336
0.0227461
0.0236344
0.0244994
0.0253428
0.026167
0.0269752
0.0277715
0.028561
0.0293495
0.0301443
0.0309537
0.0317881
0.0326605
0.0335892
0.034603
0.0357496
4.84392e-05
0.00033184
0.000653188
0.00105316
0.00152256
0.00205791
0.0026567
0.00331706
0.00403731
0.00481548
0.00564897
0.00653429
0.00746682
0.00844068
0.00944886
0.0104837
0.0115372
0.0126014
0.0136692
0.0147343
0.015791
0.016835
0.0178627
0.0188712
0.0198583
0.0208225
0.0217629
0.022679
0.0235712
0.0244401
0.0252873
0.0261151
0.0269265
0.0277254
0.0285166
0.029306
0.0301005
0.0309082
0.031739
0.0326056
0.0335251
0.0345242
0.0356472
4.94068e-05
0.000330856
0.000650069
0.0010468
0.00151231
0.00204326
0.00263716
0.00329219
0.0040067
0.0047788
0.00560601
0.00648496
0.00741119
0.00837904
0.00938176
0.0104118
0.0114613
0.0125224
0.0135881
0.0146519
0.0157083
0.0167528
0.0177817
0.018792
0.0197815
0.0207486
0.0216922
0.0226119
0.0235078
0.0243805
0.0252315
0.0260628
0.0268774
0.027679
0.0284721
0.0292626
0.0300569
0.0308632
0.0316908
0.032552
0.0334632
0.034449
0.0355507
5.03554e-05
0.000329909
0.000647065
0.00104064
0.00150237
0.00202901
0.00261813
0.00326794
0.00397684
0.004743
0.00556405
0.00643675
0.00735678
0.00831869
0.00931595
0.0103412
0.0113866
0.0124447
0.0135081
0.0145706
0.0156266
0.0166713
0.0177012
0.0187132
0.019705
0.0206749
0.0216216
0.0225448
0.0234443
0.0243208
0.0251754
0.0260103
0.026828
0.0276323
0.0284275
0.0292191
0.0300135
0.0308185
0.0316434
0.0324998
0.0334032
0.0343769
0.0354593
5.1284e-05
0.000329
0.000644172
0.00103468
0.00149271
0.00201514
0.00259958
0.00324429
0.00394769
0.00470804
0.00552303
0.00638959
0.00730352
0.00825957
0.00925142
0.0102718
0.0113132
0.0123681
0.0134292
0.0144902
0.0155456
0.0165906
0.0176214
0.018635
0.0196289
0.0206014
0.0215512
0.0224776
0.0233807
0.0242608
0.0251191
0.0259574
0.0267784
0.0275853
0.0283826
0.0291755
0.0299702
0.0307743
0.0315967
0.0324486
0.0333449
0.0343072
0.0353705
5.21928e-05
0.000328128
0.000641384
0.00102891
0.00148333
0.00200164
0.00258151
0.00322121
0.00391924
0.00467388
0.00548293
0.00634343
0.00725137
0.00820164
0.00918808
0.0102037
0.011241
0.0122926
0.0133514
0.0144108
0.0154655
0.0165106
0.0175422
0.0185572
0.0195531
0.0205281
0.0214808
0.0224105
0.023317
0.0242007
0.0250625
0.0259043
0.0267284
0.0275382
0.0283376
0.0291319
0.0299271
0.0307304
0.0315506
0.0323984
0.033288
0.0342394
0.0352847
5.30822e-05
0.000327289
0.000638695
0.00102331
0.00147422
0.0019885
0.00256389
0.0031987
0.00389145
0.0046405
0.00544373
0.00629828
0.0072003
0.00814484
0.00912592
0.0101367
0.01117
0.0122183
0.0132746
0.0143324
0.0153863
0.0164314
0.0174637
0.01848
0.0194777
0.0204551
0.0214105
0.0223434
0.0232532
0.0241404
0.0250058
0.0258509
0.0266782
0.0274908
0.0282925
0.0290882
0.029884
0.0306867
0.031505
0.032349
0.0332323
0.0341738
0.0352028
5.3951e-05
0.000326482
0.000636102
0.0010179
0.00146536
0.0019757
0.00254671
0.00317672
0.0038643
0.00460787
0.00540539
0.00625409
0.00715027
0.00808915
0.00906495
0.010071
0.0111001
0.0121451
0.0131988
0.014255
0.015308
0.0163529
0.0173857
0.0184032
0.0194028
0.0203823
0.0213405
0.0222763
0.0231894
0.02408
0.0249488
0.0257974
0.0266278
0.0274431
0.0282471
0.0290444
0.0298409
0.0306433
0.0314598
0.0323004
0.0331779
0.0341101
0.0351245
5.48002e-05
0.000325705
0.000633596
0.00101265
0.00145675
0.00196324
0.00252995
0.00315527
0.00383779
0.00457598
0.00536789
0.00621085
0.00710127
0.00803457
0.00900513
0.0100064
0.0110314
0.012073
0.0131242
0.0141786
0.0152305
0.0162752
0.0173085
0.018327
0.0193282
0.0203099
0.0212706
0.0222093
0.0231256
0.0240195
0.0248917
0.0257436
0.0265771
0.0273953
0.0282015
0.0290006
0.0297979
0.0306
0.031415
0.0322524
0.0331244
0.0340475
0.0350459
5.56293e-05
0.000324958
0.000631176
0.00100755
0.00144838
0.0019511
0.00251361
0.00313432
0.00381188
0.0045448
0.00533119
0.0061685
0.00705327
0.00798106
0.00894642
0.00994296
0.0109638
0.012002
0.0130505
0.014103
0.0151539
0.0161982
0.0172319
0.0182514
0.0192541
0.0202378
0.021201
0.0221425
0.0230618
0.0239589
0.0248344
0.0256896
0.0265263
0.0273472
0.0281558
0.0289566
0.0297548
0.0305569
0.0313705
0.0322049
0.0330717
0.0339864
0.034972
5.64407e-05
0.000324239
0.000628839
0.00100262
0.00144024
0.00193927
0.00249766
0.00311386
0.00378655
0.0045143
0.00529529
0.00612704
0.00700624
0.00792859
0.00888876
0.00988058
0.0108973
0.011932
0.0129778
0.0140284
0.0150781
0.016122
0.0171559
0.0181763
0.0191804
0.020166
0.0211315
0.0220757
0.022998
0.0238983
0.024777
0.0256354
0.0264752
0.027299
0.02811
0.0289125
0.0297118
0.0305139
0.0313263
0.0321578
0.0330196
0.0339259
0.0348971
5.72306e-05
0.000323544
0.000626576
0.000997826
0.00143232
0.00192775
0.0024821
0.00309388
0.0037618
0.00448447
0.00526013
0.00608642
0.00696013
0.00787708
0.00883213
0.00981926
0.0108319
0.0118631
0.0129061
0.0139548
0.0150032
0.0160466
0.0170806
0.0181017
0.0191072
0.0200946
0.0210623
0.0220091
0.0229342
0.0238376
0.0247196
0.0255811
0.026424
0.0272505
0.0280639
0.0288683
0.0296686
0.0304709
0.0312822
0.0321112
0.0329682
0.0338665
0.0348234
5.80047e-05
0.000322874
0.000624386
0.000993174
0.00142461
0.0019165
0.00246691
0.00307435
0.00373758
0.00445527
0.00522572
0.00604664
0.00691494
0.00782657
0.00877656
0.00975902
0.0107675
0.0117952
0.0128355
0.0138821
0.0149292
0.0159719
0.017006
0.0180278
0.0190344
0.0200235
0.0209934
0.0219426
0.0228706
0.0237769
0.024662
0.0255267
0.0263725
0.0272019
0.0280177
0.0288239
0.0296254
0.030428
0.0312384
0.0320652
0.0329184
0.0338123
0.0347715
5.87593e-05
0.000322231
0.000622268
0.000988655
0.00141711
0.00190554
0.00245207
0.00305526
0.00371391
0.00442671
0.00519203
0.00600767
0.00687063
0.00777703
0.008722
0.00969982
0.0107041
0.0117283
0.0127658
0.0138102
0.0148559
0.015898
0.016932
0.0179543
0.0189621
0.0199528
0.0209247
0.0218764
0.022807
0.0237163
0.0246044
0.0254721
0.0263209
0.027153
0.0279713
0.0287795
0.0295822
0.0303851
0.0311949
0.0320196
0.0328692
0.0337562
0.0346956
5.94988e-05
0.000321611
0.00062022
0.000984271
0.00140981
0.00189485
0.00243758
0.00303661
0.00369075
0.00439874
0.00515903
0.00596947
0.00682718
0.00772839
0.00866839
0.00964159
0.0106418
0.0116625
0.012697
0.0137393
0.0147835
0.0158248
0.0168587
0.0178815
0.0188902
0.0198825
0.0208563
0.0218103
0.0227436
0.0236556
0.0245467
0.0254174
0.0262692
0.027104
0.0279247
0.0287348
0.0295389
0.0303423
0.0311516
0.0319748
0.0328215
0.0337053
0.0346491
6.02205e-05
0.000321013
0.000618237
0.000980011
0.0014027
0.00188442
0.00242343
0.00301837
0.00366809
0.00437137
0.00512671
0.00593203
0.00678458
0.00768068
0.00861574
0.00958437
0.0105804
0.0115975
0.0126292
0.0136693
0.014712
0.0157524
0.016786
0.0178092
0.0188189
0.0198125
0.0207882
0.0217444
0.0226802
0.023595
0.024489
0.0253627
0.0262174
0.0270549
0.027878
0.0286901
0.0294956
0.0302996
0.0311087
0.0319305
0.0327745
0.0336531
0.0345807
6.09256e-05
0.000320435
0.000616312
0.00097587
0.00139577
0.00187425
0.00240961
0.00300053
0.00364591
0.00434457
0.00509504
0.00589534
0.00674278
0.00763383
0.00856402
0.00952809
0.0105201
0.0115336
0.0125623
0.0136001
0.0146413
0.0156807
0.016714
0.0177375
0.018748
0.019743
0.0207204
0.0216787
0.0226169
0.0235344
0.0244312
0.0253078
0.0261654
0.0270056
0.0278312
0.0286453
0.0294522
0.0302571
0.0310661
0.0318868
0.0327288
0.033605
0.0345364
6.16171e-05
0.000319878
0.000614446
0.000971842
0.00138902
0.00186432
0.0023961
0.00298309
0.00362421
0.00431832
0.005064
0.00585935
0.00670178
0.00758784
0.00851323
0.00947276
0.0104606
0.0114706
0.0124964
0.0135319
0.0145714
0.0156098
0.0166427
0.0176664
0.0186777
0.0196739
0.0206529
0.0216133
0.0225538
0.0234739
0.0243735
0.0252529
0.0261133
0.0269562
0.0277842
0.0286004
0.0294089
0.0302146
0.0310237
0.0318436
0.0326835
0.0335549
0.0344706
6.22931e-05
0.000319339
0.000612636
0.000967926
0.00138244
0.00185462
0.00238289
0.00296602
0.00360296
0.0042926
0.00503358
0.00582407
0.00666154
0.00754268
0.0084633
0.00941835
0.0104022
0.0114086
0.0124313
0.0134644
0.0145022
0.0155396
0.0165721
0.0175959
0.0186078
0.0196052
0.0205858
0.0215481
0.0224909
0.0234135
0.0243157
0.025198
0.0260611
0.0269067
0.0277371
0.0285554
0.0293655
0.0301722
0.0309816
0.0318009
0.032639
0.0335078
0.0344256
6.29483e-05
0.000318815
0.000610879
0.000964114
0.00137603
0.00184516
0.00236999
0.00294933
0.00358215
0.0042674
0.00500377
0.00578946
0.00662205
0.00749834
0.00841423
0.00936483
0.0103446
0.0113474
0.0123671
0.0133978
0.0144339
0.0154701
0.0165021
0.017526
0.0185384
0.0195368
0.020519
0.0214831
0.0224281
0.0233532
0.024258
0.025143
0.0260088
0.0268571
0.02769
0.0285104
0.0293221
0.03013
0.0309397
0.0317584
0.0325946
0.0334592
0.0343639
6.35876e-05
0.000318309
0.000609171
0.000960405
0.00136978
0.00183591
0.00235737
0.00293299
0.00356178
0.00424272
0.00497453
0.00575551
0.0065833
0.00745478
0.00836601
0.00931218
0.0102878
0.0112871
0.0123038
0.0133321
0.0143663
0.0154014
0.0164328
0.0174566
0.0184696
0.0194689
0.0204525
0.0214184
0.0223655
0.023293
0.0242004
0.025088
0.0259565
0.0268074
0.0276427
0.0284653
0.0292787
0.0300878
0.0308979
0.0317161
0.0325507
0.0334121
0.0343145
6.42154e-05
0.000317819
0.000607512
0.000956792
0.00136368
0.00182688
0.00234503
0.00291699
0.00354182
0.00421852
0.00494586
0.00572219
0.00654525
0.007412
0.00831861
0.00926039
0.010232
0.0112277
0.0122414
0.0132672
0.0142996
0.0153334
0.0163641
0.0173878
0.0184012
0.0194015
0.0203863
0.021354
0.0223031
0.0232328
0.0241427
0.025033
0.0259042
0.0267576
0.0275954
0.0284201
0.0292353
0.0300456
0.0308562
0.031674
0.032507
0.033365
0.034261
6.48295e-05
0.000317347
0.000605901
0.000953277
0.00135773
0.00181806
0.00233296
0.00290133
0.00352226
0.0041948
0.00491774
0.00568951
0.0065079
0.00736998
0.00827201
0.00920945
0.0101771
0.0111692
0.0121798
0.0132031
0.0142336
0.0152661
0.0162961
0.0173196
0.0183334
0.0193344
0.0203205
0.0212898
0.0222409
0.0231729
0.0240852
0.024978
0.0258518
0.0267078
0.027548
0.0283749
0.0291919
0.0300034
0.0308146
0.0316321
0.0324635
0.0333184
0.0342086
6.543e-05
0.00031689
0.000604337
0.000949852
0.00135192
0.00180944
0.00232115
0.002886
0.0035031
0.00417154
0.00489016
0.00565743
0.00647121
0.00732868
0.00822619
0.00915932
0.0101229
0.0111115
0.012119
0.0131398
0.0141683
0.0151995
0.0162287
0.017252
0.018266
0.0192678
0.0202551
0.021226
0.0221789
0.023113
0.0240277
0.024923
0.0257994
0.0266579
0.0275005
0.0283296
0.0291484
0.0299612
0.0307731
0.0315903
0.0324205
0.033273
0.0341609
6.60164e-05
0.000316451
0.000602819
0.000946515
0.00134625
0.00180101
0.00230959
0.00287098
0.00348433
0.00414873
0.0048631
0.00562594
0.00643519
0.0072881
0.00818115
0.00910999
0.0100696
0.0110546
0.012059
0.0130773
0.0141038
0.0151336
0.0161619
0.017185
0.0181992
0.0192017
0.02019
0.0211624
0.0221171
0.0230533
0.0239703
0.0248681
0.025747
0.026608
0.027453
0.0282842
0.0291049
0.029919
0.0307316
0.0315487
0.0323777
0.0332278
0.0341105
6.65903e-05
0.000316025
0.000601344
0.000943266
0.00134073
0.00179278
0.00229828
0.00285628
0.00346593
0.00412637
0.00483655
0.00559502
0.00639981
0.00724822
0.00813685
0.00906146
0.0100171
0.0109985
0.0119999
0.0130156
0.0140401
0.0150684
0.0160958
0.0171185
0.0181329
0.0191359
0.0201253
0.0210991
0.0220556
0.0229938
0.023913
0.0248132
0.0256945
0.0265581
0.0274054
0.0282388
0.0290613
0.0298768
0.0306901
0.0315071
0.0323349
0.0331822
0.0340593
6.71515e-05
0.000315609
0.000599905
0.000940098
0.00133533
0.00178473
0.00228722
0.00284187
0.00344789
0.00410443
0.00481049
0.00556467
0.00636504
0.00720902
0.00809327
0.00901368
0.00996546
0.0109433
0.0119415
0.0129546
0.0139771
0.0150039
0.0160304
0.0170526
0.018067
0.0190707
0.020061
0.0210361
0.0219943
0.0229344
0.0238559
0.0247583
0.0256421
0.0265081
0.0273578
0.0281933
0.0290176
0.0298345
0.0306485
0.0314655
0.0322921
0.0331364
0.0340085
6.77012e-05
0.000315205
0.000598503
0.000937007
0.00133005
0.00177685
0.00227638
0.00282775
0.0034302
0.00408292
0.00478492
0.00553486
0.00633089
0.00717049
0.00805041
0.00896666
0.00991453
0.0108888
0.011884
0.0128944
0.0139148
0.0149401
0.0159656
0.0169873
0.0180017
0.0190059
0.0199971
0.0209734
0.0219332
0.0228753
0.0237988
0.0247035
0.0255897
0.0264581
0.0273101
0.0281477
0.0289739
0.0297921
0.0306069
0.0314237
0.0322491
0.0330906
0.0339579
6.82386e-05
0.000314815
0.000597139
0.00093399
0.0013249
0.00176915
0.00226577
0.00281392
0.00341285
0.0040618
0.00475981
0.00550558
0.00629732
0.0071326
0.00800824
0.00892035
0.00986435
0.0108351
0.0118271
0.0128349
0.0138532
0.0148769
0.0159014
0.0169226
0.017937
0.0189415
0.0199336
0.0209111
0.0218724
0.0228163
0.0237418
0.0246488
0.0255373
0.0264081
0.0272623
0.0281021
0.02893
0.0297496
0.0305651
0.0313818
0.0322059
0.0330447
0.0339075
6.8764e-05
0.000314437
0.000595812
0.00093105
0.00131986
0.00176161
0.00225537
0.00280036
0.00339583
0.00404107
0.00473515
0.00547682
0.00626434
0.00709534
0.00796676
0.00887478
0.00981491
0.0107821
0.011771
0.0127762
0.0137924
0.0148144
0.0158378
0.0168584
0.0178727
0.0188775
0.0198704
0.020849
0.0218118
0.0227574
0.023685
0.0245942
0.025485
0.026358
0.0272145
0.0280563
0.028886
0.029707
0.0305232
0.0313397
0.0321624
0.0329979
0.0338528
6.92808e-05
0.000314073
0.000594521
0.00092818
0.00131494
0.00175423
0.0022452
0.00278706
0.00337915
0.00402073
0.00471095
0.00544856
0.00623192
0.0070587
0.00792594
0.00882991
0.00976621
0.0107299
0.0117157
0.0127183
0.0137322
0.0147526
0.0157748
0.0167948
0.0178089
0.018814
0.0198076
0.0207873
0.0217515
0.0226988
0.0236284
0.0245396
0.0254326
0.0263079
0.0271666
0.0280105
0.0288419
0.0296642
0.0304811
0.0312976
0.0321191
0.0329527
0.033808
6.97841e-05
0.000313719
0.000593265
0.000925379
0.00131013
0.00174702
0.00223523
0.00277403
0.00336277
0.00400077
0.00468717
0.0054208
0.00620005
0.00702267
0.00788577
0.00878572
0.00971822
0.0106784
0.0116611
0.012661
0.0136728
0.0146915
0.0157125
0.0167318
0.0177457
0.018751
0.0197452
0.0207259
0.0216915
0.0226404
0.0235718
0.0244851
0.0253803
0.0262578
0.0271187
0.0279645
0.0287977
0.0296212
0.0304389
0.0312553
0.0320758
0.0329068
0.0337549
7.02743e-05
0.000313372
0.000592038
0.000922646
0.00130543
0.00173996
0.00222546
0.00276126
0.00334671
0.00398117
0.00466381
0.00539352
0.00616871
0.00698722
0.00784623
0.0087422
0.00967092
0.0106276
0.0116072
0.0126044
0.0136139
0.0146309
0.0156508
0.0166693
0.0176829
0.0186884
0.0196832
0.0206649
0.0216317
0.0225822
0.0235154
0.0244307
0.025328
0.0262077
0.0270707
0.0279185
0.0287534
0.0295782
0.0303966
0.031213
0.0320327
0.0328622
0.03371
7.0756e-05
0.000313037
0.00059084
0.000919975
0.00130084
0.00173304
0.00221589
0.00274872
0.00333094
0.00396192
0.00464087
0.00536671
0.00613789
0.00695235
0.00780732
0.00869934
0.00962432
0.0105776
0.011554
0.0125485
0.0135558
0.0145711
0.0155896
0.0166074
0.0176206
0.0186263
0.0196215
0.0206041
0.0215722
0.0225242
0.0234591
0.0243764
0.0252758
0.0261575
0.0270226
0.0278723
0.0287089
0.0295351
0.0303543
0.0311709
0.0319901
0.0328185
0.0336643
7.1226e-05
0.000312709
0.000589672
0.000917365
0.00129634
0.00172627
0.00220651
0.00273643
0.00331547
0.00394302
0.00461833
0.00534034
0.00610759
0.00691804
0.007769
0.00865713
0.00957838
0.0105282
0.0115015
0.0124933
0.0134984
0.0145118
0.0155291
0.016546
0.0175589
0.0185646
0.0195603
0.0205437
0.0215129
0.0224664
0.023403
0.0243222
0.0252235
0.0261074
0.0269744
0.0278261
0.0286644
0.0294919
0.030312
0.031129
0.0319482
0.0327763
0.0336229
7.16888e-05
0.000312392
0.000588531
0.000914813
0.00129193
0.00171963
0.00219731
0.00272437
0.00330027
0.00392445
0.00459618
0.00531443
0.00607779
0.00688428
0.00773129
0.00861555
0.00953309
0.0104795
0.0114497
0.0124388
0.0134416
0.0144532
0.0154691
0.0164852
0.0174977
0.0185033
0.0194995
0.0204836
0.0214539
0.0224088
0.0233471
0.024268
0.0251713
0.0260572
0.0269263
0.0277798
0.0286198
0.0294486
0.0302698
0.0310874
0.0319067
0.0327348
0.0335814
7.21454e-05
0.000312089
0.000587422
0.000912321
0.00128763
0.00171314
0.00218829
0.00271252
0.00328535
0.0039062
0.0045744
0.00528894
0.00604846
0.00685105
0.00769415
0.00857457
0.00948845
0.0104314
0.0113986
0.0123849
0.0133854
0.0143952
0.0154098
0.0164249
0.0174369
0.0184425
0.019439
0.0204239
0.0213952
0.0223514
0.0232913
0.024214
0.0251192
0.026007
0.0268781
0.0277335
0.0285751
0.0294054
0.0302276
0.0310458
0.0318651
0.0326915
0.0335305
7.25819e-05
0.000311781
0.000586332
0.000909879
0.00128341
0.00170677
0.00217944
0.00270093
0.00327069
0.00388828
0.00455299
0.00526391
0.00601963
0.00681832
0.00765757
0.0085342
0.00944444
0.010384
0.011348
0.0123317
0.0133299
0.0143378
0.0153509
0.0163651
0.0173766
0.0183822
0.0193789
0.0203645
0.0213368
0.0222943
0.0232356
0.0241601
0.0250671
0.0259569
0.0268299
0.0276871
0.0285305
0.0293622
0.0301855
0.0310043
0.0318237
0.0326497
0.0334914
7.3006e-05
0.00031148
0.000585263
0.00090749
0.00127928
0.00170052
0.00217076
0.00268952
0.00325635
0.00387069
0.00453194
0.00523925
0.00599126
0.00678618
0.00762157
0.00849445
0.00940107
0.0103372
0.0112982
0.0122791
0.0132749
0.014281
0.0152927
0.0163059
0.0173168
0.0183223
0.0193192
0.0203054
0.0212786
0.0222373
0.0231802
0.0241063
0.0250152
0.0259067
0.0267816
0.0276408
0.0284858
0.029319
0.0301434
0.0309629
0.0317821
0.0326067
0.0334421
7.34267e-05
0.000311214
0.000584246
0.000905175
0.00127524
0.00169441
0.00216227
0.00267832
0.00324221
0.00385339
0.0045113
0.005215
0.00596333
0.00675447
0.0075861
0.00845525
0.0093583
0.0102911
0.0112489
0.0122271
0.0132207
0.0142248
0.015235
0.0162472
0.0172576
0.0182627
0.0192599
0.0202466
0.0212208
0.0221806
0.0231249
0.0240525
0.0249632
0.0258567
0.0267334
0.0275944
0.0284411
0.0292758
0.0301013
0.0309215
0.031741
0.0325656
0.0334032
7.3864e-05
0.000310944
0.000583244
0.00090291
0.00127132
0.00168844
0.00215391
0.00266735
0.00322832
0.00383639
0.00449095
0.00519117
0.00593584
0.00672326
0.00755116
0.00841662
0.00931611
0.0102456
0.0112003
0.0121758
0.013167
0.0141692
0.015178
0.016189
0.0171987
0.0182037
0.019201
0.0201882
0.0211632
0.0221241
0.0230697
0.023999
0.0249113
0.0258066
0.0266852
0.027548
0.0283964
0.0292325
0.0300593
0.0308804
0.0317005
0.0325255
0.0333637
7.42895e-05
0.000310692
0.000582265
0.000900683
0.00126744
0.00168257
0.00214574
0.00265657
0.00321468
0.00381966
0.00447095
0.00516771
0.00590879
0.00669253
0.00751673
0.00837854
0.0092745
0.0102006
0.0111524
0.012125
0.0131139
0.0141142
0.0151214
0.0161314
0.0171404
0.0181451
0.0191425
0.0201301
0.0211059
0.0220679
0.0230148
0.0239455
0.0248595
0.0257566
0.0266371
0.0275016
0.0283517
0.0291894
0.0300175
0.0308396
0.0316604
0.0324862
0.0333258
7.46799e-05
0.000310416
0.000581294
0.000898494
0.00126364
0.00167681
0.0021377
0.002646
0.00320128
0.00380326
0.00445127
0.00514466
0.00588218
0.0066623
0.0074828
0.008341
0.00923346
0.0101562
0.011105
0.0120749
0.0130614
0.0140597
0.0150654
0.0160742
0.0170825
0.0180869
0.0190844
0.0200724
0.0210488
0.0220118
0.02296
0.0238922
0.0248078
0.0257067
0.0265889
0.0274552
0.0283071
0.0291463
0.0299757
0.0307989
0.0316204
0.0324459
0.0332815
7.50549e-05
0.000310142
0.000580335
0.000896344
0.00125991
0.00167115
0.0021298
0.00263558
0.00318815
0.00378708
0.00443193
0.00512192
0.00585597
0.0066325
0.00744944
0.00830403
0.009193
0.0101125
0.0110582
0.0120254
0.0130095
0.0140058
0.0150099
0.0160176
0.0170251
0.0180291
0.0190266
0.020015
0.0209921
0.021956
0.0229054
0.0238391
0.0247563
0.0256568
0.0265408
0.0274089
0.0282625
0.0291033
0.0299341
0.0307583
0.0315804
0.032406
0.0332419
7.5428e-05
0.000309907
0.000579427
0.00089427
0.00125628
0.00166562
0.00212208
0.00262535
0.0031752
0.00377121
0.00441292
0.00509955
0.00583016
0.00660314
0.00741649
0.00826755
0.00915308
0.0100693
0.0110119
0.0119764
0.0129582
0.0139525
0.014955
0.0159615
0.0169682
0.0179717
0.0189692
0.0199579
0.0209356
0.0219005
0.022851
0.0237861
0.0247049
0.0256071
0.0264928
0.0273626
0.0282179
0.0290603
0.0298925
0.0307178
0.0315404
0.0323655
0.0331988
7.58235e-05
0.000309672
0.000578531
0.00089223
0.00125272
0.00166019
0.00211448
0.00261533
0.00316248
0.00375558
0.00439417
0.00507757
0.00580473
0.00657422
0.00738403
0.00823158
0.0091137
0.0100267
0.0109663
0.011928
0.0129074
0.0138997
0.0149006
0.0159058
0.0169117
0.0179149
0.0189122
0.0199012
0.0208795
0.0218452
0.0227968
0.0237332
0.0246535
0.0255574
0.0264448
0.0273164
0.0281734
0.0290173
0.0298509
0.0306771
0.0315002
0.0323248
0.033156
7.61911e-05
0.000309433
0.000577642
0.000890218
0.00124921
0.00165486
0.00210702
0.00260549
0.00314996
0.0037402
0.00437574
0.0050559
0.00577973
0.00654571
0.00735203
0.0081961
0.00907483
0.00998456
0.0109212
0.0118802
0.0128572
0.0138475
0.0148467
0.0158507
0.0168557
0.0178584
0.0188556
0.0198448
0.0208236
0.0217901
0.0227429
0.0236805
0.0246023
0.0255078
0.0263969
0.0272702
0.0281288
0.0289744
0.0298093
0.0306365
0.0314601
0.0322849
0.0331169
7.65426e-05
0.000309187
0.000576766
0.000888242
0.00124576
0.0016496
0.00209967
0.00259577
0.00313767
0.0037251
0.00435758
0.00503459
0.00575505
0.00651769
0.00732048
0.00816112
0.00903651
0.00994299
0.0108766
0.011833
0.0128075
0.0137957
0.0147933
0.015796
0.0168001
0.0178023
0.0187993
0.0197887
0.020768
0.0217353
0.0226891
0.023628
0.0245512
0.0254583
0.0263491
0.0272241
0.0280844
0.0289315
0.0297677
0.030596
0.0314203
0.032245
0.0330763
7.68923e-05
0.000308979
0.000575935
0.000886309
0.00124239
0.00164446
0.00209249
0.00258625
0.00312561
0.00371021
0.00433978
0.00501357
0.00573079
0.00649002
0.00728945
0.00812664
0.00899865
0.00990198
0.0108326
0.0117863
0.0127584
0.0137445
0.0147404
0.0157419
0.016745
0.0177466
0.0187435
0.019733
0.0207127
0.0216808
0.0226355
0.0235757
0.0245003
0.0254089
0.0263013
0.027178
0.02804
0.0288886
0.0297262
0.0305556
0.0313804
0.0322054
0.0330361
7.72593e-05
0.000308769
0.000575121
0.00088446
0.00123911
0.00163944
0.00208541
0.0025769
0.0031137
0.00369559
0.00432219
0.00499292
0.00570686
0.00646275
0.00725879
0.00809262
0.00896133
0.00986147
0.0107891
0.01174
0.0127098
0.0136939
0.014688
0.0156881
0.0166904
0.0176914
0.018688
0.0196776
0.0206577
0.0216265
0.0225822
0.0235235
0.0244495
0.0253596
0.0262536
0.027132
0.0279956
0.0288457
0.0296847
0.0305151
0.0313408
0.0321664
0.0329986
7.76026e-05
0.000308553
0.000574306
0.000882602
0.00123587
0.0016345
0.00207847
0.00256769
0.003102
0.00368119
0.00430489
0.00497254
0.00568329
0.00643588
0.00722856
0.00805905
0.00892449
0.00982151
0.0107462
0.0116944
0.0126617
0.0136438
0.0146362
0.0156349
0.0166362
0.0176366
0.0186329
0.0196225
0.0206031
0.0215725
0.0225291
0.0234715
0.0243988
0.0253104
0.0262061
0.0270861
0.0279512
0.0288029
0.0296432
0.0304747
0.0313009
0.0321259
0.0329532
7.7929e-05
0.000308342
0.000573506
0.000880782
0.00123269
0.00162964
0.00207165
0.00255866
0.00309049
0.00366701
0.00428785
0.00495251
0.00566009
0.00640938
0.00719875
0.00802593
0.00888812
0.00978199
0.0107037
0.0116492
0.0126142
0.0135941
0.0145848
0.0155821
0.0165824
0.0175821
0.0185782
0.0195678
0.0205487
0.0215187
0.0224762
0.0234198
0.0243483
0.0252614
0.0261586
0.0270401
0.0279069
0.0287601
0.0296017
0.0304342
0.0312611
0.0320864
0.032916
7.82697e-05
0.000308137
0.000572724
0.000879004
0.00122957
0.00162486
0.00206494
0.00254976
0.00307922
0.00365308
0.00427107
0.00493274
0.00563722
0.00638333
0.0071694
0.00799329
0.00885224
0.00974297
0.0106618
0.0116046
0.0125671
0.013545
0.0145339
0.0155299
0.0165291
0.0175281
0.0185238
0.0195135
0.0204946
0.0214652
0.0224235
0.0233682
0.0242981
0.0252124
0.0261112
0.0269943
0.0278626
0.0287173
0.0295602
0.0303937
0.0312212
0.0320465
0.0328741
7.85705e-05
0.000307932
0.000571979
0.000877274
0.0012265
0.00162017
0.00205836
0.002541
0.00306807
0.00363936
0.0042546
0.00491327
0.00561466
0.00635758
0.00714042
0.00796106
0.00881681
0.00970446
0.0106204
0.0115605
0.0125206
0.0134963
0.0144835
0.0154781
0.0164763
0.0174745
0.0184699
0.0194594
0.0204409
0.021412
0.0223711
0.0233168
0.0242478
0.0251637
0.0260638
0.0269485
0.0278184
0.0286745
0.0295187
0.0303532
0.0311812
0.0320064
0.0328329
7.88769e-05
0.000307729
0.000571225
0.000875564
0.00122352
0.00161557
0.00205186
0.0025324
0.0030571
0.00362584
0.00423832
0.0048941
0.00559243
0.00633219
0.00711183
0.00792925
0.00878183
0.00966645
0.0105794
0.0115169
0.0124745
0.0134482
0.0144336
0.0154267
0.0164238
0.0174213
0.0184163
0.0194058
0.0203874
0.0213591
0.0223189
0.0232655
0.0241978
0.0251149
0.0260166
0.0269028
0.0277742
0.0286317
0.0294771
0.0303127
0.0311413
0.0319665
0.0327924
7.92203e-05
0.000307579
0.000570506
0.000873896
0.00122057
0.00161106
0.00204551
0.00252394
0.00304632
0.00361253
0.0042223
0.00487521
0.00557052
0.00630717
0.00708363
0.00789786
0.00874729
0.00962885
0.010539
0.0114737
0.012429
0.0134005
0.0143841
0.0153758
0.0163718
0.0173686
0.0183631
0.0193524
0.0203343
0.0213064
0.022267
0.0232145
0.0241479
0.0250664
0.0259695
0.0268571
0.02773
0.0285889
0.0294356
0.0302722
0.0311016
0.0319278
0.0327568
7.95436e-05
0.000307392
0.000569795
0.000872254
0.00121768
0.00160663
0.00203926
0.00251565
0.00303572
0.00359946
0.00420653
0.00485663
0.00554895
0.00628252
0.0070558
0.00786688
0.00871319
0.00959173
0.010499
0.0114311
0.0123839
0.0133533
0.0143351
0.0153253
0.0163202
0.0173162
0.0183102
0.0192995
0.0202814
0.0212539
0.0222152
0.0231637
0.0240982
0.0250179
0.0259224
0.0268115
0.0276858
0.0285462
0.0293941
0.0302317
0.031062
0.0318883
0.0327148
7.98055e-05
0.000307172
0.000569081
0.000870625
0.00121483
0.00160225
0.00203309
0.00250745
0.00302531
0.00358653
0.00419099
0.00483825
0.00552767
0.00625819
0.00702841
0.00783633
0.00867955
0.00955505
0.0104595
0.0113889
0.0123393
0.0133066
0.0142866
0.0152753
0.016269
0.0172642
0.0182577
0.0192468
0.0202289
0.0212018
0.0221637
0.0231131
0.0240487
0.0249696
0.0258754
0.026766
0.0276417
0.0285035
0.0293526
0.0301914
0.0310222
0.0318489
0.0326756
8.00615e-05
0.000307002
0.000568398
0.000869048
0.00121204
0.00159796
0.00202704
0.00249937
0.003015
0.00357383
0.00417569
0.00482015
0.00550667
0.00623418
0.00700131
0.00780615
0.00864631
0.00951884
0.0104204
0.0113472
0.0122952
0.0132604
0.0142385
0.0152257
0.0162183
0.0172126
0.0182056
0.0191945
0.0201766
0.0211499
0.0221125
0.0230627
0.0239993
0.0249214
0.0258285
0.0267205
0.0275976
0.0284607
0.0293112
0.0301509
0.0309824
0.0318092
0.0326349
8.03573e-05
0.000306822
0.000567711
0.000867492
0.00120929
0.00159374
0.00202108
0.00249144
0.00300487
0.00356131
0.00416058
0.00480234
0.00548596
0.00621049
0.00697458
0.00777636
0.00861347
0.00948308
0.0103818
0.0113059
0.0122516
0.0132146
0.0141909
0.0151766
0.0161679
0.0171614
0.0181539
0.0191425
0.0201247
0.0210983
0.0220614
0.0230124
0.0239501
0.0248734
0.0257818
0.0266751
0.0275536
0.028418
0.0292696
0.0301103
0.0309425
0.0317694
0.0325947
8.0662e-05
0.000306671
0.000567036
0.000865952
0.00120659
0.00158959
0.00201522
0.00248366
0.00299489
0.00354897
0.0041457
0.00478475
0.00546556
0.00618712
0.0069482
0.00774694
0.00858104
0.00944769
0.0103436
0.0112651
0.0122083
0.0131693
0.0141437
0.0151279
0.016118
0.0171106
0.0181025
0.0190908
0.0200731
0.021047
0.0220106
0.0229624
0.023901
0.0248254
0.0257351
0.0266297
0.0275096
0.0283753
0.0292281
0.0300697
0.0309025
0.0317293
0.0325539
8.0959e-05
0.000306506
0.000566389
0.000864445
0.00120393
0.0015855
0.00200945
0.00247596
0.00298509
0.00353684
0.00413104
0.00476746
0.00544542
0.00616414
0.0069222
0.0077179
0.00854905
0.00941273
0.0103059
0.0112248
0.0121656
0.0131243
0.014097
0.0150796
0.0160685
0.0170602
0.0180515
0.0190395
0.0200218
0.0209959
0.0219601
0.0229126
0.0238521
0.0247776
0.0256885
0.0265845
0.0274656
0.0283326
0.0291865
0.030029
0.0308624
0.0316895
0.0325143
8.12042e-05
0.000306338
0.00056577
0.000862968
0.00120132
0.00158149
0.0020038
0.0024684
0.00297545
0.00352486
0.00411663
0.00475035
0.00542558
0.00614139
0.00689653
0.00768929
0.00851739
0.00937823
0.0102686
0.0111849
0.0121233
0.0130799
0.0140507
0.0150318
0.0160194
0.0170101
0.0180008
0.0189885
0.0199707
0.0209451
0.0219098
0.022863
0.0238034
0.02473
0.025642
0.0265392
0.0274216
0.0282899
0.0291449
0.0299884
0.0308224
0.03165
0.0324749
8.14559e-05
0.00030616
0.000565135
0.000861557
0.00119878
0.00157755
0.00199821
0.00246096
0.0029659
0.00351308
0.00410238
0.00473352
0.00540598
0.00611894
0.00687117
0.00766096
0.00848616
0.0093441
0.0102317
0.0111454
0.0120815
0.0130359
0.0140048
0.0149843
0.0159707
0.0169605
0.0179505
0.0189379
0.01992
0.0208946
0.0218597
0.0228135
0.0237548
0.0246824
0.0255956
0.026494
0.0273777
0.0282471
0.0291033
0.0299477
0.0307825
0.0316107
0.032436
8.17512e-05
0.000306045
0.000564535
0.000860146
0.00119628
0.00157368
0.00199273
0.00245363
0.00295653
0.00350146
0.00408834
0.00471691
0.00538666
0.00609681
0.00684614
0.00763301
0.0084553
0.00931042
0.0101952
0.0111063
0.01204
0.0129923
0.0139594
0.0149373
0.0159224
0.0169112
0.0179006
0.0188876
0.0198696
0.0208443
0.0218098
0.0227643
0.0237064
0.024635
0.0255493
0.026449
0.0273338
0.0282045
0.0290617
0.0299071
0.0307427
0.0315713
0.032397
8.2026e-05
0.000305888
0.000563925
0.000858734
0.00119381
0.00156988
0.00198734
0.00244644
0.00294728
0.00349001
0.0040745
0.00470056
0.00536763
0.00607495
0.00682143
0.00760541
0.00842481
0.00927708
0.0101592
0.0110677
0.0119991
0.0129492
0.0139144
0.0148907
0.0158745
0.0168623
0.017851
0.0188376
0.0198195
0.0207943
0.0217602
0.0227153
0.0236581
0.0245877
0.0255031
0.0264039
0.02729
0.0281618
0.0290202
0.0298665
0.0307029
0.0315321
0.032358
8.22416e-05
0.000305702
0.000563322
0.000857345
0.00119136
0.00156611
0.001982
0.00243932
0.00293822
0.00347874
0.00406085
0.00468438
0.00534884
0.00605345
0.00679707
0.00757817
0.0083947
0.00924412
0.0101235
0.0110296
0.0119584
0.0129065
0.0138698
0.0148445
0.015827
0.0168138
0.0178017
0.0187879
0.0197696
0.0207446
0.0217108
0.0226665
0.0236101
0.0245405
0.025457
0.0263589
0.0272462
0.0281192
0.0289787
0.029826
0.0306632
0.0314931
0.0323192
8.24518e-05
0.000305563
0.000562745
0.000856002
0.00118897
0.00156241
0.00197677
0.0024323
0.00292923
0.00346761
0.00404743
0.00466843
0.00533027
0.00603215
0.00677299
0.00755125
0.00836494
0.00921158
0.0100883
0.0109917
0.0119183
0.0128642
0.0138256
0.0147987
0.0157799
0.0167656
0.0177528
0.0187385
0.01972
0.0206951
0.0216616
0.0226178
0.0235622
0.0244936
0.025411
0.026314
0.0272024
0.0280766
0.0289372
0.0297856
0.0306237
0.0314544
0.0322814
8.27004e-05
0.000305408
0.000562159
0.000854683
0.00118663
0.00155878
0.0019716
0.00242541
0.00292038
0.00345663
0.00403414
0.00465272
0.00531195
0.00601113
0.0067492
0.00752465
0.00833552
0.00917943
0.0100534
0.0109543
0.0118785
0.0128223
0.0137818
0.0147533
0.0157331
0.0167178
0.0177043
0.0186895
0.0196708
0.0206459
0.0216127
0.0225693
0.0235144
0.0244466
0.0253651
0.0262692
0.0271588
0.028034
0.0288958
0.0297453
0.0305845
0.0314161
0.0322434
8.29792e-05
0.000305308
0.000561611
0.000853381
0.0011843
0.00155521
0.00196655
0.00241862
0.00291167
0.00344581
0.00402105
0.0046372
0.00529387
0.00599039
0.00672571
0.00749837
0.00830646
0.0091476
0.010019
0.0109173
0.0118392
0.0127808
0.0137384
0.0147083
0.0156867
0.0166704
0.017656
0.0186407
0.0196218
0.0205969
0.021564
0.0225211
0.0234668
0.0243999
0.0253193
0.0262245
0.0271152
0.0279917
0.0288546
0.0297053
0.0305458
0.0313792
0.0322112
8.32322e-05
0.000305166
0.000561058
0.000852092
0.00118203
0.00155169
0.00196154
0.00241195
0.00290309
0.00343518
0.00400815
0.00462193
0.00527607
0.00596994
0.00670251
0.00747242
0.00827773
0.00911615
0.00998487
0.0108807
0.0118002
0.0127397
0.0136954
0.0146636
0.0156407
0.0166233
0.0176082
0.0185923
0.0195731
0.0205482
0.0215155
0.0224731
0.0234194
0.0243533
0.0252736
0.0261799
0.0270717
0.0279494
0.0288135
0.0296654
0.0305072
0.0313415
0.0321714
8.34256e-05
0.000304993
0.000560501
0.000850815
0.00117978
0.00154821
0.00195661
0.00240535
0.00289466
0.00342465
0.00399542
0.00460681
0.00525847
0.00594974
0.00667966
0.0074468
0.00824937
0.00908504
0.00995114
0.0108445
0.0117616
0.012699
0.0136528
0.0146194
0.0155951
0.0165766
0.0175606
0.0185442
0.0195247
0.0204998
0.0214672
0.0224253
0.0233722
0.0243068
0.0252281
0.0261354
0.0270283
0.0279072
0.0287726
0.0296258
0.0304687
0.0313043
0.0321362
8.36103e-05
0.000304851
0.000559962
0.000849588
0.00117758
0.0015448
0.00195178
0.00239884
0.0028863
0.0034143
0.00398289
0.0045919
0.00524109
0.00592977
0.00665702
0.00742147
0.00822131
0.0090543
0.00991777
0.0108086
0.0117235
0.0126587
0.0136106
0.0145755
0.0155499
0.0165302
0.0175134
0.0184964
0.0194766
0.0204516
0.0214192
0.0223776
0.0233251
0.0242605
0.0251827
0.026091
0.0269851
0.0278652
0.0287318
0.0295863
0.0304303
0.0312664
0.0320969
8.38397e-05
0.00030472
0.000559429
0.000848371
0.00117541
0.00154143
0.00194699
0.00239243
0.00287807
0.00340406
0.00397047
0.0045772
0.00522392
0.00591006
0.00663467
0.00739643
0.00819358
0.00902394
0.00988479
0.0107731
0.0116857
0.0126187
0.0135688
0.014532
0.015505
0.0164842
0.0174665
0.0184489
0.0194288
0.0204037
0.0213714
0.0223301
0.0232783
0.0242144
0.0251374
0.0260468
0.026942
0.0278233
0.0286911
0.0295468
0.0303919
0.0312289
0.0320605
8.40781e-05
0.000304613
0.000558904
0.000847148
0.00117327
0.00153813
0.00194228
0.00238613
0.00286995
0.00339397
0.00395824
0.00456268
0.00520701
0.00589058
0.00661259
0.00737169
0.00816616
0.00899385
0.00985215
0.010738
0.0116482
0.0125792
0.0135273
0.0144889
0.0154604
0.0164385
0.0174199
0.0184017
0.0193812
0.020356
0.0213239
0.022283
0.0232316
0.0241684
0.0250924
0.0260026
0.026899
0.0277815
0.0286506
0.0295074
0.0303538
0.0311922
0.0320271
8.43106e-05
0.00030449
0.000558401
0.000845961
0.00117116
0.00153486
0.00193764
0.00237992
0.00286198
0.00338404
0.00394617
0.00454838
0.00519027
0.00587141
0.0065908
0.00734723
0.00813909
0.00896411
0.00981985
0.0107033
0.0116112
0.01254
0.0134862
0.0144461
0.0154162
0.0163931
0.0173736
0.0183548
0.0193339
0.0203086
0.0212766
0.022236
0.0231851
0.0241226
0.0250474
0.0259587
0.0268562
0.0277398
0.0286101
0.029468
0.0303153
0.0311534
0.0319831
8.44932e-05
0.00030436
0.000557919
0.000844797
0.00116909
0.00153165
0.00193308
0.00237378
0.0028541
0.00337422
0.00393431
0.00453422
0.00517378
0.00585241
0.00656927
0.00732313
0.00811228
0.00893473
0.0097879
0.0106689
0.0115745
0.0125012
0.0134455
0.0144037
0.0153724
0.0163481
0.0173277
0.0183082
0.0192869
0.0202614
0.0212295
0.0221892
0.0231388
0.024077
0.0250026
0.0259149
0.0268134
0.0276982
0.0285696
0.0294287
0.0302765
0.0311151
0.0319463
8.46816e-05
0.000304218
0.000557415
0.000843683
0.00116706
0.00152849
0.00192856
0.00236773
0.00284631
0.00336455
0.00392255
0.00452028
0.00515748
0.00583365
0.00654797
0.00729923
0.00808581
0.00890565
0.00975628
0.0106349
0.0115381
0.0124627
0.0134051
0.0143617
0.0153289
0.0163034
0.0172821
0.0182619
0.0192402
0.0202146
0.0211826
0.0221426
0.0230927
0.0240315
0.0249579
0.0258712
0.0267708
0.0276566
0.0285292
0.0293891
0.0302378
0.0310767
0.0319077
8.49152e-05
0.000304138
0.000556945
0.000842569
0.00116506
0.00152539
0.00192414
0.00236177
0.00283864
0.003355
0.00391096
0.0045065
0.00514138
0.00581513
0.00652694
0.00727564
0.00805963
0.00887693
0.00972503
0.0106011
0.0115022
0.0124247
0.0133651
0.01432
0.0152858
0.0162591
0.0172368
0.018216
0.0191938
0.0201679
0.0211361
0.0220962
0.0230468
0.0239862
0.0249134
0.0258276
0.0267282
0.0276152
0.0284887
0.0293496
0.030199
0.0310385
0.0318707
8.51307e-05
0.000304016
0.000556462
0.000841444
0.00116309
0.00152234
0.00191979
0.00235593
0.0028311
0.00334561
0.00389952
0.00449293
0.00512551
0.00579683
0.00650616
0.00725231
0.00803373
0.00884847
0.0096941
0.0105678
0.0114666
0.0123869
0.0133255
0.0142786
0.015243
0.0162151
0.0171919
0.0181703
0.0191477
0.0201215
0.0210897
0.0220501
0.023001
0.0239411
0.0248691
0.0257841
0.0266858
0.0275737
0.0284483
0.0293101
0.0301602
0.0310005
0.0318336
8.52878e-05
0.000303864
0.000555982
0.000840335
0.00116113
0.0015193
0.00191546
0.00235013
0.00282366
0.00333628
0.00388824
0.00447947
0.00510981
0.0057788
0.00648564
0.00722927
0.00800815
0.00882032
0.00966348
0.0105348
0.0114313
0.0123495
0.0132862
0.0142377
0.0152005
0.0161714
0.0171472
0.0181249
0.0191018
0.0200755
0.0210436
0.0220042
0.0229556
0.0238962
0.0248249
0.0257408
0.0266434
0.0275324
0.0284079
0.0292706
0.0301215
0.0309621
0.0317942
8.54395e-05
0.000303755
0.000555523
0.000839262
0.00115919
0.00151629
0.00191122
0.0023444
0.00281627
0.00332712
0.00387711
0.0044662
0.0050943
0.00576092
0.00646535
0.00720648
0.00798284
0.0087925
0.00963317
0.0105021
0.0113963
0.0123125
0.0132472
0.014197
0.0151584
0.016128
0.0171028
0.0180798
0.0190562
0.0200296
0.0209977
0.0219585
0.0229102
0.0238514
0.0247808
0.0256976
0.0266011
0.027491
0.0283675
0.0292312
0.0300831
0.0309251
0.0317607
8.56306e-05
0.000303633
0.000555056
0.000838213
0.00115732
0.00151336
0.001907
0.00233876
0.002809
0.00331805
0.00386607
0.00445311
0.00507897
0.00574326
0.00644528
0.00718394
0.0079578
0.00876499
0.00960316
0.0104698
0.0113617
0.0122758
0.0132086
0.0141567
0.0151166
0.016085
0.0170588
0.018035
0.0190109
0.019984
0.020952
0.021913
0.0228651
0.0238068
0.0247369
0.0256545
0.0265589
0.0274497
0.0283273
0.0291919
0.0300449
0.0308881
0.0317248
8.58522e-05
0.00030356
0.000554606
0.000837156
0.00115546
0.00151049
0.00190289
0.0023332
0.00280184
0.00330911
0.00385521
0.00444017
0.00506383
0.00572582
0.00642545
0.00716166
0.00793303
0.00873774
0.00957354
0.0104377
0.0113274
0.0122395
0.0131703
0.0141167
0.0150751
0.0160423
0.0170151
0.0179906
0.0189659
0.0199387
0.0209066
0.0218677
0.0228201
0.0237624
0.0246932
0.0256115
0.0265168
0.0274086
0.0282871
0.0291528
0.0300067
0.0308506
0.0316859
8.60514e-05
0.00030345
0.000554172
0.000836125
0.00115362
0.00150763
0.00189882
0.00232775
0.00279479
0.00330033
0.00384449
0.00442743
0.00504891
0.00570862
0.00640584
0.00713963
0.00790857
0.00871078
0.00954416
0.010406
0.0112935
0.0122034
0.0131324
0.0140771
0.015034
0.0159999
0.0169717
0.0179463
0.0189212
0.0198936
0.0208615
0.0218227
0.0227754
0.0237181
0.0246495
0.0255687
0.0264748
0.0273676
0.028247
0.0291137
0.0299688
0.0308141
0.0316539
8.61909e-05
0.000303304
0.000553726
0.000835103
0.00115181
0.00150481
0.00189479
0.00232234
0.00278784
0.0032916
0.00383391
0.00441479
0.00503415
0.0056916
0.00638652
0.00711786
0.00788432
0.00868414
0.00951509
0.0103747
0.0112599
0.0121677
0.0130948
0.0140378
0.0149932
0.0159579
0.0169286
0.0179024
0.0188767
0.0198488
0.0208166
0.0217778
0.0227309
0.023674
0.024606
0.0255259
0.0264329
0.0273266
0.0282071
0.0290748
0.0299306
0.0307759
0.0316109
8.63221e-05
0.000303188
0.000553293
0.000834118
0.00115003
0.00150204
0.00189085
0.00231698
0.00278093
0.00328301
0.00382347
0.0044023
0.00501954
0.00567476
0.00636734
0.00709632
0.00786037
0.00865774
0.00948631
0.0103436
0.0112266
0.0121323
0.0130575
0.0139988
0.0149527
0.0159161
0.0168858
0.0178588
0.0188325
0.0198043
0.0207719
0.0217332
0.0226865
0.0236301
0.0245627
0.0254833
0.0263911
0.0272858
0.0281672
0.0290359
0.0298928
0.0307397
0.0315803
8.6498e-05
0.000303084
0.000552863
0.000833136
0.00114827
0.00149929
0.00188693
0.00231171
0.00277412
0.00327451
0.0038131
0.00439
0.00500511
0.00565811
0.0063484
0.00707502
0.00783667
0.00863167
0.00945784
0.0103128
0.0111936
0.0120973
0.0130206
0.0139601
0.0149125
0.0158746
0.0168433
0.0178155
0.0187886
0.01976
0.0207274
0.0216888
0.0226423
0.0235863
0.0245195
0.0254409
0.0263495
0.027245
0.0281274
0.0289971
0.029855
0.0307027
0.0315422
8.66878e-05
0.000303004
0.000552435
0.000832143
0.00114653
0.00149661
0.00188308
0.00230653
0.00276741
0.00326612
0.00380289
0.00437784
0.00499088
0.00564166
0.00632967
0.00705395
0.00781322
0.00860582
0.00942966
0.0102823
0.011161
0.0120626
0.0129839
0.0139218
0.0148727
0.0158335
0.0168011
0.0177725
0.0187449
0.0197159
0.0206832
0.0216446
0.0225983
0.0235427
0.0244765
0.0253985
0.026308
0.0272044
0.0280877
0.0289584
0.0298171
0.0306654
0.0315045
8.68403e-05
0.000302886
0.000552031
0.000831182
0.00114482
0.00149393
0.00187926
0.00230141
0.00276082
0.00325788
0.00379282
0.00436585
0.00497679
0.00562545
0.00631117
0.0070331
0.00779005
0.00858024
0.00940176
0.0102521
0.0111286
0.0120282
0.0129476
0.0138837
0.0148331
0.0157927
0.0167591
0.0177297
0.0187015
0.0196721
0.0206392
0.0216006
0.0225545
0.0234993
0.0244336
0.0253563
0.0262665
0.0271639
0.0280481
0.0289197
0.0297794
0.0306284
0.0314692
8.69702e-05
0.000302795
0.000551637
0.000830234
0.00114313
0.00149131
0.00187552
0.00229633
0.00275428
0.00324969
0.0037829
0.00435395
0.00496289
0.00560937
0.00629288
0.00701254
0.00776707
0.00855496
0.00937413
0.0102223
0.0110965
0.0119941
0.0129116
0.013846
0.0147939
0.0157521
0.0167175
0.0176872
0.0186584
0.0196286
0.0205954
0.0215568
0.022511
0.0234561
0.0243909
0.0253142
0.0262252
0.0271234
0.0280086
0.0288811
0.0297416
0.0305911
0.031431
8.71315e-05
0.000302683
0.000551227
0.000829333
0.00114147
0.00148872
0.0018718
0.00229133
0.0027478
0.00324161
0.00377304
0.00434223
0.00494913
0.00559348
0.00627478
0.00699214
0.00774439
0.00852992
0.00934678
0.0101926
0.0110648
0.0119602
0.0128759
0.0138086
0.014755
0.0157119
0.0166762
0.017645
0.0186155
0.0195853
0.0205519
0.0215133
0.0224675
0.023413
0.0243483
0.0252723
0.0261841
0.0270831
0.0279692
0.0288426
0.0297039
0.0305544
0.0313955
8.73242e-05
0.000302625
0.000550848
0.000828429
0.00113985
0.00148618
0.00186816
0.0022864
0.00274144
0.00323364
0.00376332
0.00433065
0.00493554
0.00557778
0.00625688
0.00697198
0.00772193
0.00850518
0.00931973
0.0101633
0.0110333
0.0119268
0.0128406
0.0137715
0.0147164
0.015672
0.0166352
0.0176031
0.0185729
0.0195422
0.0205086
0.0214699
0.0224243
0.0233701
0.0243059
0.0252305
0.026143
0.0270428
0.0279298
0.0288042
0.0296667
0.030519
0.0313654
8.74933e-05
0.000302523
0.000550453
0.000827508
0.00113823
0.00148366
0.00186456
0.00228157
0.00273516
0.00322581
0.00375374
0.00431921
0.00492211
0.00556225
0.00623917
0.00695204
0.0076997
0.00848064
0.00929294
0.0101343
0.0110022
0.0118936
0.0128055
0.0137347
0.0146781
0.0156323
0.0165944
0.0175614
0.0185306
0.0194994
0.0204655
0.0214268
0.0223813
0.0233274
0.0242637
0.0251888
0.0261021
0.0270027
0.0278906
0.0287659
0.0296292
0.0304816
0.0313229
8.76033e-05
0.00030239
0.000550058
0.000826601
0.00113663
0.00148117
0.00186099
0.00227677
0.00272898
0.00321801
0.00374428
0.00430788
0.00490884
0.00554695
0.00622169
0.00693234
0.00767773
0.00845636
0.00926641
0.0101056
0.0109713
0.0118607
0.0127707
0.0136983
0.01464
0.015593
0.0165539
0.01752
0.0184885
0.0194569
0.0204227
0.0213839
0.0223385
0.0232849
0.0242216
0.0251473
0.0260612
0.0269627
0.0278515
0.0287276
0.0295917
0.0304445
0.0312871
8.77086e-05
0.000302301
0.000549682
0.000825723
0.00113503
0.00147869
0.0018575
0.00227201
0.00272281
0.00321034
0.00373492
0.00429667
0.0048957
0.00553174
0.00620438
0.00691282
0.00765597
0.00843235
0.00924013
0.0100771
0.0109407
0.0118281
0.0127362
0.0136621
0.0146024
0.0155539
0.0165138
0.0174789
0.0184467
0.0194145
0.0203801
0.0213412
0.0222959
0.0232425
0.0241796
0.0251059
0.0260206
0.0269228
0.0278124
0.0286894
0.0295543
0.030408
0.0312514
8.78534e-05
0.000302197
0.000549296
0.000824863
0.0011335
0.00147628
0.001854
0.00226731
0.00271674
0.00320274
0.00372563
0.00428562
0.00488271
0.00551673
0.00618725
0.00689351
0.00763443
0.00840859
0.0092141
0.0100489
0.0109104
0.0117957
0.0127021
0.0136262
0.0145649
0.0155152
0.0164739
0.0174381
0.0184052
0.0193725
0.0203377
0.0212986
0.0222534
0.0232003
0.0241378
0.0250647
0.02598
0.026883
0.0277735
0.0286514
0.0295174
0.0303725
0.0312191
8.80299e-05
0.000302143
0.000548923
0.000823992
0.00113197
0.00147391
0.0018506
0.00226269
0.00271076
0.00319524
0.00371648
0.00427468
0.00486987
0.00550189
0.00617031
0.0068744
0.00761311
0.00838504
0.0091884
0.0100209
0.0108803
0.0117638
0.0126682
0.0135906
0.0145278
0.0154767
0.0164342
0.0173975
0.0183639
0.0193307
0.0202955
0.0212564
0.0222112
0.0231583
0.0240963
0.0250236
0.0259396
0.0268434
0.0277348
0.0286137
0.0294808
0.0303374
0.0311856
8.81857e-05
0.000302051
0.000548565
0.000823143
0.00113045
0.00147155
0.00184722
0.00225816
0.00270487
0.00318788
0.00370745
0.00426391
0.00485721
0.00548724
0.00615355
0.0068555
0.00759205
0.00836172
0.00916287
0.0099933
0.0108506
0.011732
0.0126346
0.0135553
0.0144909
0.0154385
0.0163949
0.0173572
0.0183228
0.019289
0.0202536
0.0212143
0.0221692
0.0231165
0.0240548
0.0249827
0.0258994
0.026804
0.0276962
0.0285762
0.0294445
0.0303021
0.0311508
8.82825e-05
0.000301924
0.000548195
0.000822299
0.00112896
0.00146921
0.00184387
0.00225363
0.00269903
0.00318053
0.00369852
0.0042532
0.00484465
0.00547271
0.00613701
0.00683681
0.00757115
0.00833867
0.00913761
0.00996592
0.0108211
0.0117005
0.0126012
0.0135203
0.0144543
0.0154006
0.0163558
0.0173172
0.018282
0.0192477
0.0202119
0.0211724
0.0221274
0.0230749
0.0240135
0.024942
0.0258593
0.0267647
0.0276579
0.0285389
0.0294082
0.0302667
0.0311155
8.83695e-05
0.00030182
0.000547832
0.000821486
0.00112748
0.00146691
0.00184058
0.00224915
0.00269324
0.00317331
0.00368971
0.00424263
0.00483224
0.00545834
0.00612059
0.00681831
0.0075505
0.00831583
0.00911259
0.00993875
0.0107919
0.0116693
0.0125682
0.0134855
0.0144181
0.0153629
0.016317
0.0172774
0.0182415
0.0192066
0.0201705
0.0211308
0.0220857
0.0230334
0.0239724
0.0249014
0.0258194
0.0267256
0.0276197
0.0285018
0.0293722
0.030232
0.0310826
8.85263e-05
0.000301764
0.000547492
0.000820689
0.00112604
0.00146465
0.00183733
0.00224476
0.00268755
0.00316616
0.00368096
0.00423222
0.00481998
0.00544415
0.00610437
0.0068
0.00753005
0.00829325
0.00908785
0.00991185
0.0107629
0.0116384
0.0125355
0.013451
0.0143821
0.0153256
0.0162785
0.0172379
0.0182012
0.0191658
0.0201292
0.0210894
0.0220443
0.0229922
0.0239316
0.0248611
0.0257797
0.0266867
0.0275817
0.0284648
0.0293364
0.0301975
0.0310505
8.86798e-05
0.000301686
0.000547139
0.00081987
0.0011246
0.00146242
0.00183414
0.00224045
0.00268193
0.0031591
0.00367233
0.00422189
0.00480787
0.00543011
0.00608833
0.00678188
0.0075098
0.00827084
0.00906333
0.00988523
0.0107343
0.0116078
0.012503
0.0134168
0.0143464
0.0152885
0.0162402
0.0171987
0.0181612
0.0191252
0.0200882
0.0210482
0.0220031
0.0229512
0.0238909
0.0248209
0.0257402
0.026648
0.0275439
0.0284279
0.0293002
0.0301612
0.0310092
8.87722e-05
0.000301568
0.000546787
0.000819059
0.00112317
0.00146019
0.00183094
0.00223615
0.00267637
0.00315213
0.00366381
0.00421171
0.00479585
0.00541625
0.00607246
0.00676393
0.00748979
0.00824866
0.00903903
0.00985884
0.0107058
0.0115774
0.0124708
0.0133829
0.0143109
0.0152517
0.0162022
0.0171597
0.0181214
0.0190848
0.0200475
0.0210073
0.0219621
0.0229104
0.0238504
0.0247809
0.0257008
0.0266094
0.0275062
0.028391
0.0292641
0.0301261
0.0309798
8.88548e-05
0.000301487
0.000546451
0.000818264
0.00112176
0.001458
0.00182782
0.0022319
0.00267087
0.00314521
0.0036554
0.00420158
0.00478399
0.00540247
0.00605675
0.00674623
0.00746993
0.00822673
0.00901496
0.00983272
0.0106776
0.0115473
0.0124388
0.0133493
0.0142757
0.0152151
0.0161645
0.017121
0.0180819
0.0190447
0.020007
0.0209665
0.0219214
0.0228698
0.0238101
0.0247411
0.0256616
0.0265709
0.0274684
0.0283539
0.0292272
0.0300878
0.0309326
8.89749e-05
0.000301392
0.000546105
0.000817514
0.00112038
0.00145583
0.00182469
0.00222769
0.00266541
0.00313839
0.00364703
0.00419161
0.00477225
0.00538886
0.0060412
0.00672864
0.00745031
0.00820499
0.00899112
0.0098068
0.0106497
0.0115174
0.0124071
0.0133159
0.0142409
0.0151789
0.0161271
0.0170826
0.0180427
0.0190049
0.0199666
0.020926
0.0218808
0.0228293
0.02377
0.0247014
0.0256226
0.0265324
0.0274306
0.0283165
0.02919
0.0300507
0.0308993
8.9127e-05
0.000301345
0.00054577
0.000816733
0.00111901
0.00145371
0.00182165
0.00222355
0.00266005
0.00313165
0.00363878
0.00418173
0.00476062
0.00537542
0.00602583
0.00671127
0.00743087
0.0081835
0.00896754
0.00978112
0.0106221
0.0114879
0.0123757
0.0132828
0.0142062
0.0151429
0.0160899
0.0170444
0.0180037
0.0189652
0.0199266
0.0208857
0.0218405
0.0227891
0.02373
0.0246619
0.0255835
0.026494
0.0273927
0.028279
0.0291526
0.0300131
0.0308602
8.9259e-05
0.000301261
0.000545449
0.000815974
0.00111766
0.0014516
0.00181863
0.00221949
0.00265476
0.00312503
0.00363065
0.00417201
0.00474917
0.00536214
0.00601058
0.00669404
0.00741162
0.00816217
0.00894417
0.00975572
0.0105947
0.0114585
0.0123446
0.01325
0.0141719
0.0151071
0.0160529
0.0170064
0.0179649
0.0189258
0.0198868
0.0208457
0.0218003
0.0227491
0.0236903
0.0246225
0.0255446
0.0264556
0.0273547
0.0282414
0.0291152
0.0299758
0.0308235
8.93324e-05
0.000301141
0.000545115
0.000815221
0.00111633
0.00144951
0.00181563
0.00221544
0.00264953
0.00311842
0.00362261
0.00416234
0.00473779
0.00534895
0.00599555
0.00667702
0.00739258
0.00814105
0.00892101
0.00973056
0.0105675
0.0114295
0.0123137
0.0132175
0.0141378
0.0150717
0.0160163
0.0169688
0.0179264
0.0188867
0.0198472
0.0208058
0.0217604
0.0227092
0.0236506
0.0245832
0.0255057
0.0264172
0.0273167
0.0282038
0.029078
0.0299393
0.0307889
8.93976e-05
0.000301049
0.000544788
0.000814492
0.00111499
0.00144744
0.0018127
0.00221143
0.00264432
0.00311191
0.00361465
0.00415277
0.00472655
0.00533591
0.00598062
0.00666016
0.00737371
0.00812017
0.00889806
0.00970557
0.0105406
0.0114006
0.0122831
0.0131852
0.014104
0.0150365
0.0159799
0.0169314
0.0178882
0.0188478
0.0198079
0.0207662
0.0217207
0.0226695
0.0236111
0.024544
0.0254669
0.0263788
0.0272788
0.0281663
0.0290411
0.0299033
0.0307544
8.95068e-05
0.000300966
0.000544463
0.000813767
0.00111371
0.00144541
0.00180975
0.00220747
0.00263918
0.00310546
0.00360673
0.00414334
0.00471544
0.00532301
0.00596586
0.00664346
0.00735503
0.0080995
0.00887531
0.00968084
0.0105139
0.011372
0.0122527
0.0131531
0.0140704
0.0150016
0.0159438
0.0168942
0.0178502
0.0188092
0.0197687
0.0207267
0.0216811
0.02263
0.0235717
0.0245049
0.0254282
0.0263404
0.0272409
0.028129
0.0290044
0.0298676
0.0307198
8.96463e-05
0.000300927
0.000544152
0.000813032
0.00111242
0.00144342
0.00180689
0.00220356
0.00263412
0.00309908
0.00359893
0.00413398
0.00470442
0.00531025
0.00595124
0.00662693
0.00733653
0.00807898
0.00885285
0.00965632
0.0104874
0.0113437
0.0122226
0.0131214
0.0140371
0.0149669
0.0159079
0.0168573
0.0178124
0.0187707
0.0197298
0.0206875
0.0216417
0.0225906
0.0235325
0.0244659
0.0253895
0.0263022
0.0272032
0.0280919
0.0289681
0.0298322
0.0306855
8.97668e-05
0.000300848
0.000543849
0.000812316
0.00111114
0.00144143
0.00180404
0.00219974
0.00262912
0.00309283
0.00359124
0.00412478
0.00469356
0.00529766
0.00593678
0.00661057
0.00731826
0.00805866
0.00883054
0.00963206
0.0104612
0.0113156
0.0121927
0.0130898
0.014004
0.0149324
0.0158723
0.0168206
0.0177749
0.0187325
0.0196911
0.0206485
0.0216025
0.0225514
0.0234934
0.0244271
0.025351
0.0262642
0.0271656
0.0280549
0.028932
0.0297974
0.0306534
8.98288e-05
0.000300732
0.000543532
0.000811603
0.00110988
0.00143946
0.00180121
0.0021959
0.00262417
0.00308657
0.00358361
0.0041156
0.00468278
0.00528514
0.0059225
0.00659438
0.00730008
0.00803857
0.00880844
0.00960802
0.0104352
0.0112878
0.0121631
0.0130586
0.0139712
0.0148983
0.0158368
0.0167842
0.0177376
0.0186945
0.0196526
0.0206096
0.0215635
0.0225123
0.0234544
0.0243883
0.0253126
0.0262262
0.0271282
0.0280181
0.0288957
0.029761
0.030613
8.98807e-05
0.000300639
0.00054322
0.000810917
0.00110864
0.00143752
0.00179842
0.0021921
0.00261925
0.00308041
0.00357607
0.00410655
0.00467212
0.00527276
0.00590832
0.00657834
0.00728213
0.00801865
0.00878654
0.00958415
0.0104095
0.0112602
0.0121337
0.0130275
0.0139387
0.0148643
0.0158017
0.016748
0.0177005
0.0186568
0.0196143
0.020571
0.0215246
0.0224734
0.0234156
0.0243497
0.0252743
0.0261883
0.0270908
0.0279812
0.0288594
0.0297253
0.0305798
9.00021e-05
0.000300593
0.000542929
0.000810244
0.00110742
0.00143561
0.00179568
0.00218838
0.00261441
0.00307432
0.00356859
0.00409762
0.00466158
0.00526052
0.0058943
0.00656248
0.00726436
0.00799896
0.00876488
0.00956051
0.0103839
0.0112328
0.0121046
0.0129967
0.0139064
0.0148307
0.0157668
0.0167121
0.0176637
0.0186193
0.0195763
0.0205325
0.021486
0.0224347
0.023377
0.0243112
0.0252361
0.0261505
0.0270535
0.0279444
0.028823
0.0296892
0.0305432
9.01216e-05
0.000300524
0.000542626
0.000809546
0.00110621
0.00143373
0.00179297
0.00218472
0.00260963
0.0030683
0.00356122
0.00408876
0.00465116
0.0052484
0.00588041
0.00654674
0.00724673
0.00797938
0.0087434
0.00953712
0.0103586
0.0112056
0.0120757
0.0129662
0.0138743
0.0147973
0.0157322
0.0166764
0.0176271
0.0185819
0.0195384
0.0204943
0.0214475
0.0223961
0.0233385
0.0242728
0.025198
0.0261128
0.0270162
0.0279077
0.0287868
0.0296537
0.0305094
9.01806e-05
0.000300415
0.000542322
0.000808857
0.00110499
0.00143183
0.00179026
0.00218107
0.00260489
0.00306235
0.00355392
0.00408002
0.00464081
0.00523644
0.00586666
0.00653115
0.00722929
0.00796
0.0087221
0.00951391
0.0103335
0.0111787
0.0120471
0.0129359
0.0138425
0.0147641
0.0156978
0.0166409
0.0175908
0.0185448
0.0195007
0.0204562
0.0214092
0.0223577
0.0233001
0.0242346
0.0251601
0.0260752
0.0269791
0.027871
0.0287508
0.0296184
0.030475
9.02296e-05
0.000300343
0.000542031
0.000808175
0.00110378
0.00142996
0.00178761
0.00217745
0.0026002
0.00305644
0.00354672
0.00407131
0.00463059
0.00522454
0.00585306
0.00651577
0.00721198
0.00794084
0.00870101
0.00949093
0.0103086
0.011152
0.0120186
0.0129059
0.0138109
0.0147311
0.0156636
0.0166057
0.0175546
0.018508
0.0194633
0.0204183
0.021371
0.0223194
0.0232618
0.0241965
0.0251222
0.0260377
0.026942
0.0278345
0.0287149
0.0295832
0.0304401
9.03162e-05
0.000300257
0.000541732
0.000807544
0.00110262
0.00142813
0.00178496
0.00217387
0.00259554
0.0030506
0.00353954
0.00406275
0.00462047
0.00521277
0.00583959
0.0065005
0.00719489
0.00792184
0.00868009
0.00946812
0.010284
0.0111256
0.0119904
0.012876
0.0137796
0.0146984
0.0156297
0.0165707
0.0175187
0.0184713
0.019426
0.0203806
0.021333
0.0222813
0.0232237
0.0241586
0.0250845
0.0260003
0.0269051
0.0277981
0.0286792
0.0295484
0.0304064
9.04354e-05
0.000300219
0.000541442
0.000806873
0.00110146
0.00142634
0.00178237
0.00217034
0.00259097
0.00304483
0.00353246
0.00405424
0.00461043
0.00520114
0.00582623
0.00648537
0.00717794
0.00790305
0.00865941
0.00944551
0.0102595
0.0110994
0.0119625
0.0128464
0.0137485
0.014666
0.015596
0.0165359
0.017483
0.0184348
0.019389
0.0203431
0.0212952
0.0222434
0.0231857
0.0241207
0.0250469
0.0259631
0.0268683
0.0277619
0.0286436
0.0295136
0.0303722
9.05355e-05
0.000300142
0.000541163
0.000806224
0.00110031
0.00142454
0.0017798
0.00216688
0.00258645
0.00303916
0.00352547
0.00404587
0.00460055
0.00518966
0.00581302
0.0064704
0.00716114
0.00788437
0.00863889
0.00942314
0.0102353
0.0110733
0.0119348
0.0128171
0.0137177
0.0146337
0.0155625
0.0165013
0.0174475
0.0183985
0.0193521
0.0203058
0.0212576
0.0222056
0.023148
0.024083
0.0250095
0.025926
0.0268317
0.0277259
0.0286083
0.0294788
0.0303376
9.05773e-05
0.000300031
0.000540873
0.000805579
0.00109918
0.00142276
0.00177724
0.00216341
0.00258196
0.00303349
0.00351854
0.00403753
0.00459072
0.00517823
0.00579997
0.00645558
0.00714452
0.00786588
0.00861855
0.00940098
0.0102113
0.0110475
0.0119072
0.012788
0.013687
0.0146017
0.0155293
0.016467
0.0174122
0.0183625
0.0193154
0.0202687
0.0212202
0.022168
0.0231103
0.0240455
0.0249722
0.0258891
0.0267952
0.02769
0.0285731
0.0294444
0.0303047
9.06094e-05
0.000299942
0.000540586
0.000804955
0.00109803
0.00142099
0.00177474
0.00215999
0.0025775
0.00302791
0.00351171
0.00402928
0.00458101
0.00516693
0.005787
0.00644089
0.00712805
0.0078476
0.00859839
0.00937895
0.0101875
0.0110219
0.0118799
0.012759
0.0136566
0.0145699
0.0154962
0.0164329
0.0173772
0.0183267
0.0192789
0.0202317
0.0211829
0.0221305
0.0230728
0.0240081
0.024935
0.0258523
0.0267589
0.0276543
0.0285379
0.0294097
0.0302692
9.07098e-05
0.000299897
0.00054032
0.000804347
0.00109695
0.00141927
0.00177223
0.00215661
0.00257311
0.00302237
0.00350491
0.00402116
0.0045714
0.00515575
0.00577418
0.00642636
0.00711174
0.0078295
0.0085784
0.00935714
0.0101639
0.0109965
0.0118529
0.0127303
0.0136264
0.0145384
0.0154634
0.016399
0.0173423
0.0182911
0.0192427
0.0201949
0.0211458
0.0220933
0.0230355
0.0239709
0.024898
0.0258156
0.0267227
0.0276185
0.0285026
0.0293747
0.0302344
9.08256e-05
0.000299853
0.000540052
0.000803721
0.00109585
0.00141758
0.00176979
0.00215328
0.00256878
0.0030169
0.0034982
0.00401309
0.00456187
0.00514469
0.00576147
0.00641194
0.00709556
0.00781151
0.00855867
0.00933551
0.0101404
0.0109714
0.011826
0.0127019
0.0135965
0.014507
0.0154308
0.0163653
0.0173077
0.0182556
0.0192066
0.0201584
0.0211089
0.0220562
0.0229984
0.0239338
0.0248611
0.0257791
0.0266866
0.0275829
0.0284673
0.0293396
0.0301989
9.08677e-05
0.000299746
0.000539776
0.000803094
0.00109475
0.00141587
0.00176735
0.00215
0.00256449
0.00301152
0.00349157
0.00400514
0.00455247
0.00513377
0.00574889
0.00639767
0.00707957
0.00779368
0.00853902
0.0093141
0.0101172
0.0109464
0.0117993
0.0126736
0.0135667
0.0144759
0.0153985
0.0163318
0.0172733
0.0182204
0.0191707
0.020122
0.0210722
0.0220192
0.0229614
0.0238969
0.0248244
0.0257427
0.0266505
0.0275472
0.0284321
0.0293046
0.0301649
9.08886e-05
0.000299648
0.000539484
0.000802471
0.00109367
0.00141418
0.00176492
0.0021467
0.00256024
0.00300613
0.00348498
0.0039972
0.00454313
0.00512289
0.00573646
0.00638354
0.00706366
0.00777605
0.00851957
0.00929288
0.0100942
0.0109216
0.0117729
0.0126456
0.0135372
0.014445
0.0153663
0.0162986
0.0172391
0.0181853
0.019135
0.0200858
0.0210357
0.0219825
0.0229245
0.0238601
0.0247878
0.0257063
0.0266146
0.0275117
0.0283968
0.0292698
0.0301304
9.09308e-05
0.000299569
0.000539209
0.000801877
0.0010926
0.00141251
0.00176253
0.00214344
0.002556
0.00300082
0.00347847
0.00398937
0.00453388
0.00511212
0.0057241
0.00636954
0.00704795
0.00775856
0.0085003
0.0092718
0.0100714
0.0108971
0.0117467
0.0126178
0.0135079
0.0144143
0.0153344
0.0162655
0.0172051
0.0181505
0.0190995
0.0200498
0.0209993
0.0219459
0.0228878
0.0238235
0.0247514
0.0256701
0.0265787
0.0274761
0.0283618
0.0292352
0.0300965
9.10293e-05
0.000299529
0.000538957
0.000801298
0.00109155
0.00141088
0.00176018
0.00214024
0.00255184
0.00299557
0.00347202
0.00398164
0.00452474
0.00510148
0.00571188
0.00635567
0.00703236
0.00774125
0.0084812
0.00925089
0.0100487
0.0108727
0.0117207
0.0125902
0.0134788
0.0143838
0.0153027
0.0162327
0.0171713
0.0181159
0.0190642
0.020014
0.0209631
0.0219094
0.0228513
0.023787
0.024715
0.025634
0.0265429
0.0274408
0.0283269
0.0292011
0.0300636
9.11201e-05
0.000299465
0.000538688
0.00080069
0.0010905
0.00140925
0.00175784
0.00213711
0.00254772
0.00299038
0.00346564
0.00397397
0.00451569
0.00509094
0.00569976
0.00634192
0.00701691
0.00772404
0.00846226
0.0092302
0.0100263
0.0108485
0.0116948
0.0125628
0.0134499
0.0143536
0.0152712
0.0162001
0.0171377
0.0180815
0.0190291
0.0199784
0.020927
0.0218732
0.022815
0.0237506
0.0246788
0.0255981
0.0265073
0.0274056
0.0282923
0.0291675
0.0300318
9.11495e-05
0.000299361
0.00053842
0.000800094
0.00108946
0.00140763
0.00175551
0.00213396
0.00254364
0.00298525
0.00345933
0.00396639
0.0045067
0.00508053
0.00568777
0.00632827
0.00700163
0.007707
0.00844348
0.00920967
0.010004
0.0108246
0.0116692
0.0125356
0.0134212
0.0143235
0.0152399
0.0161677
0.0171043
0.0180472
0.0189942
0.0199429
0.0208912
0.0218371
0.0227787
0.0237145
0.0246427
0.0255623
0.0264718
0.0273706
0.028258
0.029134
0.0299993
9.1169e-05
0.000299294
0.000538163
0.0007995
0.00108841
0.00140602
0.00175324
0.00213084
0.0025396
0.00298014
0.0034531
0.00395884
0.00449782
0.00507016
0.00567589
0.00631482
0.00698644
0.00769015
0.00842487
0.00918935
0.00998189
0.0108008
0.0116438
0.0125086
0.0133927
0.0142937
0.0152088
0.0161354
0.0170711
0.0180132
0.0189595
0.0199077
0.0208556
0.0218012
0.0227427
0.0236784
0.0246068
0.0255266
0.0264365
0.0273357
0.0282238
0.0291006
0.0299669
9.12261e-05
0.000299213
0.000537897
0.000798954
0.00108741
0.00140444
0.00175095
0.00212776
0.00253558
0.0029751
0.00344688
0.00395141
0.00448902
0.0050599
0.00566412
0.00630144
0.00697144
0.00767343
0.0084064
0.00916914
0.00996001
0.0107772
0.0116185
0.0124818
0.0133645
0.014264
0.0151779
0.0161034
0.0170381
0.0179794
0.018925
0.0198726
0.0208201
0.0217654
0.0227068
0.0236425
0.0245711
0.025491
0.0264013
0.027301
0.0281895
0.0290663
0.0299302
9.13163e-05
0.000299178
0.000537638
0.000798369
0.00108641
0.0014029
0.00174873
0.00212471
0.00253163
0.00297011
0.00344075
0.00394402
0.00448029
0.00504976
0.00565245
0.00628818
0.00695655
0.00765688
0.00838813
0.00914909
0.00993827
0.0107538
0.0115935
0.0124552
0.0133364
0.0142346
0.0151472
0.0160716
0.0170053
0.0179458
0.0188907
0.0198377
0.0207847
0.0217298
0.0226711
0.0236068
0.0245354
0.0254556
0.0263662
0.0272663
0.0281553
0.0290329
0.0298995
9.1388e-05
0.000299106
0.000537391
0.000797803
0.00108542
0.00140135
0.00174651
0.00212174
0.00252772
0.00296521
0.00343469
0.00393676
0.00447168
0.00503974
0.00564089
0.00627506
0.00694178
0.00764041
0.00837
0.00912927
0.00991675
0.0107305
0.0115687
0.0124288
0.0133085
0.0142054
0.0151167
0.01604
0.0169728
0.0179123
0.0188565
0.019803
0.0207496
0.0216944
0.0226355
0.0235711
0.0244999
0.0254203
0.0263312
0.0272318
0.0281213
0.0289995
0.0298664
9.14017e-05
0.000298999
0.000537131
0.00079724
0.00108443
0.00139981
0.0017443
0.00211873
0.00252385
0.00296029
0.00342868
0.00392949
0.00446312
0.00502976
0.00562948
0.00626206
0.00692717
0.00762411
0.00835202
0.00910963
0.00989534
0.0107075
0.011544
0.0124026
0.0132809
0.0141764
0.0150865
0.0160087
0.0169403
0.0178791
0.0188226
0.0197685
0.0207147
0.0216591
0.0226001
0.0235357
0.0244645
0.0253852
0.0262964
0.0271975
0.0280876
0.0289667
0.0298354
9.14055e-05
0.000298914
0.000536874
0.000796694
0.00108343
0.00139827
0.00174213
0.00211576
0.00251998
0.00295544
0.00342273
0.00392233
0.00445465
0.00501989
0.00561812
0.00624917
0.00691268
0.00760799
0.0083342
0.0090901
0.00987418
0.0106847
0.0115195
0.0123766
0.0132535
0.0141475
0.0150564
0.0159775
0.0169082
0.0178461
0.0187888
0.0197341
0.0206799
0.0216241
0.0225648
0.0235004
0.0244293
0.0253502
0.0262618
0.0271633
0.0280541
0.0289341
0.029804
9.14774e-05
0.000298872
0.000536636
0.000796165
0.0010825
0.00139679
0.00173997
0.00211285
0.00251619
0.00295065
0.00341683
0.00391526
0.00444627
0.00501012
0.00560689
0.00623641
0.00689832
0.00759202
0.0083165
0.00907071
0.00985312
0.010662
0.0114953
0.0123508
0.0132262
0.0141189
0.0150266
0.0159465
0.0168762
0.0178132
0.0187552
0.0196999
0.0206453
0.0215892
0.0225297
0.0234653
0.0243943
0.0253153
0.0262273
0.0271292
0.0280204
0.0289005
0.0297684
9.15654e-05
0.000298832
0.000536396
0.000795615
0.00108155
0.00139533
0.00173786
0.00210997
0.00251243
0.0029459
0.003411
0.00390823
0.00443795
0.00500045
0.00559575
0.00622374
0.00688407
0.00757612
0.00829901
0.0090515
0.00983226
0.0106395
0.0114712
0.0123252
0.0131991
0.0140905
0.0149969
0.0159157
0.0168444
0.0177806
0.0187219
0.019666
0.0206108
0.0215544
0.0224949
0.0234303
0.0243594
0.0252807
0.0261929
0.0270952
0.027987
0.0288678
0.0297382
9.15807e-05
0.000298728
0.000536149
0.000795065
0.00108059
0.00139385
0.00173574
0.00210713
0.0025087
0.00294122
0.00340523
0.0039013
0.00442975
0.00499087
0.00558469
0.0062112
0.00686999
0.00756037
0.00828162
0.0090325
0.0098116
0.0106172
0.0114473
0.0122997
0.0131722
0.0140623
0.0149674
0.0158851
0.0168128
0.0177481
0.0186887
0.0196322
0.0205766
0.0215199
0.0224601
0.0233955
0.0243247
0.0252462
0.0261587
0.0270614
0.0279537
0.028835
0.0297056
9.15722e-05
0.000298633
0.000535883
0.000794512
0.00107963
0.00139236
0.00173364
0.00210427
0.00250501
0.00293654
0.0033995
0.00389437
0.00442158
0.00498135
0.0055738
0.00619877
0.00685596
0.0075448
0.0082644
0.00901366
0.00979106
0.010595
0.0114236
0.0122745
0.0131455
0.0140343
0.0149381
0.0158547
0.0167814
0.0177158
0.0186557
0.0195986
0.0205426
0.0214855
0.0224255
0.0233609
0.0242901
0.0252118
0.0261246
0.0270278
0.0279205
0.0288027
0.0296746
9.16072e-05
0.000298565
0.000535636
0.000793995
0.0010787
0.00139092
0.00173156
0.00210144
0.00250134
0.00293193
0.00339383
0.00388754
0.0044135
0.00497193
0.00556296
0.00618645
0.00684211
0.00752934
0.00824732
0.00899493
0.00977074
0.0105731
0.0114
0.0122495
0.0131191
0.0140064
0.0149091
0.0158245
0.0167502
0.0176838
0.0186228
0.0195652
0.0205087
0.0214512
0.0223911
0.0233264
0.0242557
0.0251775
0.0260907
0.0269943
0.0278876
0.0287701
0.029641
9.16775e-05
0.000298529
0.000535396
0.00079346
0.00107778
0.00138951
0.00172952
0.00209866
0.00249772
0.00292736
0.0033882
0.00388078
0.00440548
0.0049626
0.00555222
0.00617425
0.00682835
0.00751403
0.00823038
0.00897632
0.00975051
0.0105513
0.0113767
0.0122246
0.0130928
0.0139788
0.0148802
0.0157945
0.0167192
0.0176519
0.0185902
0.0195319
0.0204749
0.0214172
0.0223568
0.0232921
0.0242214
0.0251434
0.0260569
0.026961
0.027855
0.028739
0.0296151
9.17317e-05
0.000298459
0.000535164
0.000792936
0.00107687
0.00138808
0.00172749
0.00209594
0.00249414
0.00292284
0.00338265
0.00387408
0.00439758
0.00495335
0.00554157
0.00616213
0.00681472
0.0074988
0.00821358
0.00895792
0.00973051
0.0105296
0.0113535
0.0121999
0.0130667
0.0139513
0.0148515
0.0157647
0.0166884
0.0176202
0.0185578
0.0194989
0.0204414
0.0213833
0.0223228
0.0232579
0.0241873
0.0251095
0.0260233
0.0269278
0.0278223
0.0287064
0.0295796
9.17286e-05
0.000298354
0.00053492
0.000792415
0.00107596
0.00138667
0.00172546
0.0020932
0.00249059
0.00291836
0.00337712
0.00386745
0.00438969
0.00494421
0.00553103
0.00615011
0.00680122
0.00748372
0.00819691
0.00893966
0.00971062
0.0105082
0.0113305
0.0121754
0.0130407
0.0139241
0.014823
0.0157351
0.0166578
0.0175887
0.0185255
0.019466
0.0204081
0.0213496
0.0222888
0.023224
0.0241534
0.0250758
0.0259898
0.0268946
0.0277892
0.028673
0.0295443
9.17171e-05
0.000298274
0.000534676
0.000791893
0.00107505
0.00138526
0.00172349
0.00209049
0.00248707
0.00291391
0.00337169
0.00386085
0.00438192
0.00493511
0.00552058
0.00613826
0.00678781
0.00746881
0.0081804
0.00892158
0.00969091
0.0104869
0.0113076
0.0121511
0.013015
0.013897
0.0147947
0.0157056
0.0166273
0.0175574
0.0184935
0.0194333
0.0203749
0.0213161
0.0222551
0.0231901
0.0241196
0.0250421
0.0259563
0.0268613
0.0277561
0.0286399
0.029512
9.17492e-05
0.000298203
0.000534436
0.000791409
0.00107416
0.00138389
0.00172149
0.0020878
0.00248356
0.00290951
0.00336626
0.00385436
0.00437421
0.00492611
0.00551022
0.00612646
0.00677455
0.00745399
0.008164
0.00890356
0.00967134
0.0104658
0.011285
0.0121269
0.0129895
0.0138701
0.0147666
0.0156764
0.0165971
0.0175263
0.0184616
0.0194008
0.0203419
0.0212827
0.0222215
0.0231564
0.0240859
0.0250084
0.0259229
0.0268281
0.0277232
0.0286077
0.0294824
9.18125e-05
0.000298174
0.000534205
0.000790887
0.00107329
0.00138254
0.00171955
0.00208514
0.00248011
0.00290515
0.0033609
0.00384789
0.00436655
0.00491719
0.00549994
0.00611476
0.00676138
0.00743933
0.00814777
0.00888572
0.00965193
0.0104448
0.0112625
0.012103
0.0129641
0.0138434
0.0147387
0.0156474
0.016567
0.0174953
0.0184299
0.0193685
0.0203091
0.0212495
0.0221881
0.0231229
0.0240523
0.024975
0.0258895
0.0267949
0.0276902
0.0285744
0.029446
9.18585e-05
0.000298106
0.00053398
0.000790383
0.00107241
0.00138119
0.00171761
0.00208255
0.00247671
0.00290087
0.0033556
0.00384152
0.004359
0.00490839
0.00548976
0.00610318
0.00674832
0.00742473
0.00813166
0.00886806
0.00963272
0.010424
0.0112402
0.0120792
0.0129389
0.0138169
0.0147109
0.0156185
0.0165372
0.0174645
0.0183984
0.0193364
0.0202764
0.0212165
0.0221548
0.0230894
0.0240188
0.0249416
0.0258563
0.0267618
0.0276573
0.0285419
0.0294155
9.18465e-05
0.000298001
0.000533742
0.000789882
0.00107155
0.00137984
0.00171568
0.00207992
0.00247332
0.00289657
0.00335034
0.00383515
0.00435148
0.00489961
0.00547971
0.0060917
0.00673539
0.00741027
0.00811568
0.00885057
0.00961361
0.0104034
0.011218
0.0120556
0.0129138
0.0137906
0.0146834
0.0155898
0.0165075
0.017434
0.018367
0.0193044
0.0202439
0.0211836
0.0221216
0.0230561
0.0239855
0.0249083
0.0258231
0.0267289
0.0276248
0.0285102
0.0293858
9.18242e-05
0.000297916
0.000533505
0.000789396
0.00107067
0.00137849
0.00171378
0.00207732
0.00246994
0.00289233
0.00334513
0.00382886
0.00434404
0.00489092
0.0054697
0.00608032
0.00672256
0.00739597
0.00809983
0.00883317
0.00959469
0.0103829
0.011196
0.0120321
0.0128891
0.0137644
0.014656
0.0155613
0.016478
0.0174036
0.0183358
0.0192726
0.0202116
0.0211509
0.0220886
0.0230229
0.0239523
0.0248751
0.0257901
0.0266962
0.0275926
0.0284792
0.0293567
9.18697e-05
0.000297876
0.000533288
0.000788926
0.00106985
0.00137719
0.00171189
0.00207477
0.00246662
0.00288813
0.00333995
0.00382267
0.00433668
0.00488232
0.00545979
0.00606904
0.00670985
0.0073818
0.00808409
0.00881588
0.00957587
0.0103626
0.0111743
0.0120089
0.0128644
0.0137385
0.0146288
0.015533
0.0164486
0.0173734
0.0183049
0.0192409
0.0201794
0.0211183
0.0220557
0.0229899
0.0239192
0.024842
0.0257572
0.0266637
0.0275606
0.0284478
0.029325
9.19309e-05
0.000297834
0.000533068
0.000788433
0.001069
0.00137589
0.00171003
0.00207226
0.00246334
0.00288398
0.00333484
0.00381649
0.00432936
0.0048738
0.00544996
0.00605784
0.00669723
0.00736769
0.00806853
0.00879874
0.00955721
0.0103424
0.0111525
0.0119858
0.0128399
0.0137127
0.0146018
0.0155049
0.0164195
0.0173433
0.018274
0.0192095
0.0201474
0.0210859
0.0220231
0.022957
0.0238862
0.0248092
0.0257245
0.0266313
0.0275287
0.0284162
0.0292933
9.19201e-05
0.000297738
0.000532832
0.000787939
0.00106816
0.0013746
0.00170818
0.00206977
0.00246006
0.00287987
0.00332978
0.0038104
0.00432214
0.00486536
0.00544019
0.00604673
0.00668473
0.0073537
0.00805306
0.00878179
0.00953874
0.0103224
0.0111311
0.0119628
0.0128156
0.0136871
0.014575
0.0154769
0.0163905
0.0173134
0.0182434
0.0191781
0.0201155
0.0210536
0.0219905
0.0229243
0.0238534
0.0247765
0.025692
0.0265991
0.027497
0.028385
0.0292634
9.18875e-05
0.000297645
0.000532584
0.00078744
0.0010673
0.00137329
0.00170634
0.00206726
0.00245684
0.00287577
0.00332475
0.00380432
0.00431495
0.00485697
0.00543058
0.00603574
0.00667231
0.00733987
0.00803772
0.00876498
0.00952037
0.0103025
0.0111097
0.0119401
0.0127914
0.0136616
0.0145483
0.0154491
0.0163617
0.0172838
0.0182129
0.019147
0.0200839
0.0210215
0.021958
0.0228917
0.0238208
0.0247439
0.0256597
0.0265671
0.0274654
0.0283541
0.029233
9.18968e-05
0.000297576
0.000532358
0.000786976
0.00106648
0.00137202
0.00170452
0.00206477
0.00245361
0.00287172
0.00331977
0.0037983
0.00430784
0.00484866
0.005421
0.00602485
0.00666003
0.00732613
0.00802249
0.00874825
0.00950218
0.0102828
0.0110885
0.0119175
0.0127675
0.0136363
0.0145218
0.0154215
0.0163331
0.0172542
0.0181826
0.019116
0.0200523
0.0209896
0.0219258
0.0228592
0.0237883
0.0247114
0.0256274
0.0265352
0.027434
0.0283234
0.0292032
9.19408e-05
0.000297538
0.000532137
0.000786495
0.00106567
0.00137078
0.00170272
0.00206234
0.00245044
0.00286771
0.00331482
0.00379236
0.00430077
0.00484042
0.0054115
0.00601402
0.00664783
0.00731253
0.00800742
0.00873164
0.00948408
0.0102633
0.0110675
0.011895
0.0127437
0.0136112
0.0144955
0.0153941
0.0163047
0.0172249
0.0181525
0.0190852
0.020021
0.0209578
0.0218937
0.022827
0.0237559
0.0246792
0.0255954
0.0265035
0.0274028
0.028293
0.0291744
9.19685e-05
0.000297466
0.000531925
0.000786026
0.00106486
0.00136953
0.00170094
0.00205995
0.0024473
0.00286374
0.00330994
0.00378646
0.00429381
0.00483227
0.00540209
0.0060033
0.00663573
0.00729899
0.00799245
0.00871521
0.00946617
0.0102439
0.0110466
0.0118727
0.01272
0.0135863
0.0144694
0.0153668
0.0162764
0.0171957
0.0181225
0.0190546
0.0199897
0.0209261
0.0218618
0.0227948
0.0237238
0.0246471
0.0255635
0.026472
0.0273717
0.0282623
0.0291436
9.19395e-05
0.000297366
0.000531694
0.000785557
0.00106405
0.00136828
0.00169915
0.00205753
0.00244416
0.00285981
0.00330508
0.00378062
0.00428685
0.00482419
0.00539277
0.00599265
0.00662375
0.00728557
0.0079776
0.0086989
0.00944836
0.0102246
0.0110259
0.0118506
0.0126965
0.0135616
0.0144434
0.0153398
0.0162483
0.0171667
0.0180927
0.0190241
0.0199588
0.0208946
0.02183
0.0227629
0.0236917
0.0246152
0.0255318
0.0264405
0.0273406
0.0282314
0.0291122
9.19015e-05
0.00029728
0.000531464
0.000785083
0.00106323
0.00136703
0.0016974
0.00205513
0.00244107
0.0028559
0.00330031
0.00377481
0.00428
0.00481615
0.00538353
0.00598216
0.00661184
0.00727231
0.00796288
0.00868275
0.0094307
0.0102055
0.0110054
0.0118287
0.0126732
0.013537
0.0144176
0.0153129
0.0162204
0.0171379
0.0180631
0.0189938
0.0199279
0.0208634
0.0217983
0.0227311
0.0236599
0.0245833
0.0255001
0.0264092
0.0273096
0.0282006
0.0290818
9.19306e-05
0.000297239
0.000531258
0.000784662
0.00106246
0.00136583
0.00169566
0.00205279
0.002438
0.00285203
0.00329553
0.0037691
0.0042732
0.00480821
0.00537437
0.0059717
0.00660007
0.00725913
0.00794826
0.00866665
0.00941318
0.0101865
0.010985
0.0118069
0.0126501
0.0135125
0.014392
0.0152861
0.0161926
0.0171092
0.0180336
0.0189636
0.0198972
0.0208322
0.0217669
0.0226994
0.0236282
0.0245517
0.0254686
0.026378
0.0272788
0.0281707
0.0290539
9.19743e-05
0.000297194
0.000531052
0.000784198
0.00106169
0.00136464
0.00169396
0.00205046
0.00243498
0.0028482
0.00329081
0.0037634
0.00426644
0.00480033
0.00536527
0.00596133
0.00658837
0.00724606
0.00793377
0.0086507
0.00939579
0.0101677
0.0109648
0.0117852
0.0126271
0.0134883
0.0143665
0.0152595
0.016165
0.0170807
0.0180043
0.0189336
0.0198666
0.0208012
0.0217356
0.022668
0.0235966
0.0245202
0.0254373
0.026347
0.0272484
0.0281413
0.0290263
9.19461e-05
0.000297103
0.000530815
0.000783729
0.0010609
0.00136344
0.00169224
0.00204818
0.00243197
0.00284443
0.00328614
0.00375779
0.00425978
0.00479255
0.00535625
0.00595106
0.00657678
0.00723307
0.0079194
0.00863492
0.00937857
0.010149
0.0109446
0.0117637
0.0126043
0.0134642
0.0143412
0.0152331
0.0161377
0.0170524
0.0179752
0.0189039
0.0198362
0.0207704
0.0217045
0.0226366
0.0235653
0.0244889
0.0254062
0.0263163
0.0272183
0.0281119
0.0289972
9.1901e-05
0.000297011
0.000530576
0.000783262
0.00106012
0.00136224
0.00169053
0.00204586
0.00242899
0.00284064
0.0032815
0.00375216
0.00425314
0.00478478
0.00534735
0.00594087
0.00656528
0.0072202
0.00790515
0.00861927
0.00936144
0.0101304
0.0109247
0.0117424
0.0125816
0.0134403
0.0143161
0.0152069
0.0161104
0.0170242
0.0179462
0.0188742
0.0198061
0.0207398
0.0216735
0.0226055
0.023534
0.0244578
0.0253753
0.0262857
0.0271882
0.0280822
0.0289675
9.18742e-05
0.000296931
0.000530358
0.000782819
0.00105933
0.00136103
0.00168885
0.00204356
0.00242601
0.00283689
0.00327691
0.00374661
0.00424656
0.00477709
0.00533848
0.00593077
0.00655388
0.00720747
0.00789101
0.0086037
0.00934448
0.010112
0.0109049
0.0117212
0.0125591
0.0134165
0.0142911
0.0151808
0.0160833
0.0169962
0.0179174
0.0188447
0.019776
0.0207093
0.0216427
0.0225745
0.023503
0.0244267
0.0253445
0.0262552
0.027158
0.0280524
0.028938
9.19008e-05
0.000296887
0.000530161
0.000782394
0.0010586
0.00135988
0.00168718
0.00204131
0.00242308
0.00283319
0.00327234
0.00374114
0.00424005
0.00476948
0.0053297
0.00592076
0.00654255
0.00719483
0.00787695
0.00858823
0.0093276
0.0100938
0.0108852
0.0117001
0.0125367
0.0133929
0.0142663
0.0151549
0.0160564
0.0169685
0.0178888
0.0188154
0.0197461
0.020679
0.0216121
0.0225436
0.0234721
0.0243958
0.0253138
0.0262247
0.0271277
0.0280219
0.0289064
9.19349e-05
0.000296837
0.000529962
0.00078195
0.00105784
0.00135873
0.00168553
0.00203909
0.00242018
0.00282953
0.00326783
0.00373568
0.00423358
0.00476194
0.00532098
0.00591082
0.00653133
0.00718225
0.00786306
0.0085729
0.00931086
0.0100756
0.0108657
0.0116793
0.0125145
0.0133694
0.0142417
0.0151292
0.0160296
0.0169408
0.0178604
0.0187863
0.0197164
0.0206488
0.0215816
0.0225129
0.0234413
0.0243651
0.0252831
0.0261941
0.0270971
0.0279909
0.0288744
9.18976e-05
0.000296748
0.000529726
0.000781496
0.00105708
0.00135758
0.00168389
0.0020369
0.00241729
0.00282591
0.00326337
0.00373031
0.0042272
0.00475446
0.00531231
0.00590094
0.00652019
0.0071698
0.00784924
0.00855773
0.0092943
0.0100576
0.0108463
0.0116585
0.0124925
0.0133461
0.0142173
0.0151036
0.0160031
0.0169133
0.0178321
0.0187573
0.0196869
0.0206188
0.0215513
0.0224824
0.0234106
0.0243344
0.0252525
0.0261635
0.0270663
0.0279596
0.0288416
9.1839e-05
0.000296639
0.000529478
0.00078104
0.00105631
0.00135642
0.00168226
0.00203468
0.00241444
0.00282229
0.00325892
0.00372493
0.00422084
0.00474703
0.00530379
0.00589118
0.00650917
0.00715744
0.00783554
0.00854268
0.00927781
0.0100398
0.010827
0.011638
0.0124706
0.013323
0.0141929
0.0150782
0.0159767
0.016886
0.017804
0.0187285
0.0196575
0.020589
0.021521
0.022452
0.0233801
0.0243038
0.0252219
0.0261329
0.0270357
0.0279291
0.0288121
9.18256e-05
0.000296576
0.000529273
0.000780615
0.00105558
0.00135529
0.00168065
0.00203247
0.00241159
0.00281871
0.00325452
0.00371961
0.00421454
0.00473966
0.00529529
0.0058815
0.00649823
0.00714521
0.00782193
0.00852769
0.00926146
0.010022
0.0108079
0.0116175
0.0124489
0.0133
0.0141688
0.015053
0.0159504
0.0168588
0.017776
0.0186999
0.0196283
0.0205593
0.021491
0.0224217
0.0233497
0.0242733
0.0251914
0.0261026
0.0270058
0.0279005
0.0287868
9.18286e-05
0.000296515
0.000529065
0.000780169
0.00105483
0.00135416
0.00167904
0.00203034
0.00240878
0.00281516
0.00325015
0.00371437
0.0042083
0.00473236
0.00528685
0.00587187
0.00648736
0.00713306
0.00780844
0.00851281
0.00924526
0.0100044
0.010789
0.0115972
0.0124273
0.0132772
0.0141447
0.0150279
0.0159243
0.0168318
0.0177482
0.0186714
0.0195992
0.0205298
0.0214611
0.0223915
0.0233193
0.024243
0.0251612
0.0260728
0.0269769
0.0278735
0.0287647
9.17993e-05
0.000296437
0.00052885
0.000779735
0.0010541
0.00135304
0.00167745
0.00202819
0.002406
0.00281166
0.00324583
0.00370915
0.00420212
0.00472516
0.00527848
0.00586234
0.00647659
0.00712098
0.00779507
0.0084981
0.00922914
0.00998697
0.0107701
0.0115771
0.0124058
0.0132545
0.0141209
0.015003
0.0158984
0.016805
0.0177206
0.0186431
0.0195703
0.0205004
0.0214314
0.0223616
0.0232892
0.0242129
0.0251313
0.0260433
0.0269483
0.0278462
0.0287379
9.1752e-05
0.000296357
0.000528633
0.000779306
0.00105338
0.00135194
0.00167588
0.00202606
0.00240325
0.00280816
0.00324154
0.00370396
0.00419597
0.00471796
0.00527023
0.0058529
0.00646592
0.00710902
0.0077818
0.00848352
0.00921316
0.00996964
0.0107515
0.0115571
0.0123845
0.013232
0.0140972
0.0149782
0.0158726
0.0167783
0.0176931
0.0186149
0.0195416
0.0204712
0.0214018
0.0223317
0.0232593
0.0241831
0.0251016
0.026014
0.0269193
0.0278167
0.0287041
9.17161e-05
0.000296278
0.000528429
0.000778895
0.00105264
0.00135082
0.00167432
0.00202393
0.00240049
0.00280471
0.0032373
0.00369883
0.00418988
0.00471084
0.00526202
0.00584353
0.00645533
0.00709718
0.00776863
0.00846901
0.00919733
0.00995243
0.0107329
0.0115372
0.0123634
0.0132096
0.0140737
0.0149536
0.015847
0.0167518
0.0176658
0.0185869
0.019513
0.0204421
0.0213724
0.0223021
0.0232295
0.0241533
0.025072
0.0259845
0.0268898
0.0277864
0.0286716
9.17281e-05
0.00029623
0.000528235
0.00077848
0.00105195
0.00134975
0.00167278
0.00202186
0.00239779
0.00280129
0.00323308
0.00369377
0.00418386
0.00470379
0.00525388
0.00583423
0.00644481
0.00708543
0.00775554
0.00845458
0.00918157
0.00993535
0.0107146
0.0115175
0.0123424
0.0131874
0.0140504
0.0149292
0.0158216
0.0167255
0.0176387
0.018559
0.0194845
0.0204132
0.0213431
0.0222726
0.0231999
0.0241237
0.0250424
0.025955
0.0268602
0.0277566
0.0286435
9.17452e-05
0.000296175
0.000528048
0.000778072
0.00105125
0.0013487
0.00167127
0.0020198
0.00239511
0.00279791
0.0032289
0.00368872
0.00417787
0.0046968
0.0052458
0.00582501
0.00643439
0.00707373
0.00774262
0.00844029
0.00916595
0.00991841
0.0106962
0.0114979
0.0123216
0.0131653
0.0140271
0.0149049
0.0157963
0.0166993
0.0176117
0.0185314
0.0194563
0.0203844
0.0213141
0.0222432
0.0231705
0.0240941
0.0250129
0.0259254
0.0268304
0.0277264
0.0286119
9.169e-05
0.000296091
0.000527806
0.000777641
0.00105055
0.00134762
0.00166974
0.00201777
0.00239243
0.00279456
0.00322477
0.00368375
0.00417196
0.00468988
0.00523776
0.00581584
0.00642403
0.00706215
0.00772974
0.00842614
0.00915049
0.00990156
0.0106781
0.0114785
0.0123009
0.0131434
0.0140041
0.0148807
0.0157712
0.0166733
0.0175849
0.0185039
0.0194281
0.0203559
0.0212851
0.022214
0.0231411
0.0240647
0.0249834
0.0258958
0.0268007
0.0276966
0.0285827
9.16183e-05
0.000295986
0.000527557
0.000777204
0.00104983
0.00134653
0.00166822
0.00201571
0.0023898
0.0027912
0.00322068
0.00367876
0.00416607
0.00468299
0.00522986
0.00580679
0.0064138
0.00705066
0.00771699
0.00841212
0.00913509
0.00988488
0.0106601
0.0114592
0.0122803
0.0131217
0.0139812
0.0148568
0.0157462
0.0166474
0.0175582
0.0184765
0.0194002
0.0203274
0.0212562
0.0221849
0.0231118
0.0240353
0.0249539
0.0258664
0.0267712
0.0276674
0.0285542
9.15697e-05
0.000295911
0.000527355
0.000776793
0.00104911
0.00134545
0.00166672
0.00201367
0.00238715
0.00278789
0.00321658
0.00367386
0.00416024
0.00467616
0.00522197
0.0057978
0.00640363
0.00703928
0.00770431
0.00839814
0.00911985
0.00986831
0.0106422
0.01144
0.0122599
0.0131
0.0139584
0.0148329
0.0157214
0.0166217
0.0175317
0.0184493
0.0193724
0.0202991
0.0212276
0.022156
0.0230826
0.024006
0.0249246
0.025837
0.026742
0.0276388
0.0285273
9.15686e-05
0.00029586
0.000527161
0.000776378
0.00104844
0.00134443
0.00166522
0.00201167
0.00238456
0.00278461
0.00321254
0.00366897
0.00415444
0.0046694
0.00521415
0.00578886
0.00639353
0.00702799
0.00769174
0.00838427
0.00910468
0.00985185
0.0106245
0.0114209
0.0122396
0.0130786
0.0139358
0.0148093
0.0156968
0.0165962
0.0175054
0.0184222
0.0193448
0.020271
0.021199
0.0221272
0.0230536
0.0239768
0.0248953
0.0258077
0.0267129
0.0276101
0.0284988
9.15605e-05
0.000295797
0.000526966
0.00077597
0.00104775
0.00134339
0.00166376
0.00200971
0.00238198
0.00278136
0.00320854
0.00366414
0.00414873
0.0046627
0.0052064
0.00578001
0.00638352
0.00701674
0.00767931
0.00837052
0.00908967
0.00983552
0.0106068
0.0114021
0.0122195
0.0130572
0.0139134
0.0147857
0.0156722
0.0165708
0.0174792
0.0183953
0.0193172
0.020243
0.0211707
0.0220984
0.0230246
0.0239477
0.0248661
0.0257786
0.0266839
0.0275812
0.0284697
9.14959e-05
0.00029571
0.00052673
0.000775553
0.00104707
0.00134235
0.00166228
0.00200772
0.00237941
0.00277814
0.00320456
0.00365935
0.00414301
0.00465605
0.00519871
0.00577121
0.0063736
0.0070056
0.00766693
0.00835691
0.00907474
0.00981931
0.0105893
0.0113833
0.0121995
0.0130361
0.0138911
0.0147624
0.0156479
0.0165455
0.0174531
0.0183686
0.0192899
0.0202151
0.0211423
0.0220698
0.0229958
0.0239188
0.0248371
0.0257496
0.0266551
0.0275525
0.0284412
9.14219e-05
0.000295625
0.000526509
0.00077513
0.00104637
0.0013413
0.00166083
0.00200574
0.00237688
0.00277492
0.00320063
0.00365458
0.00413738
0.00464944
0.0051911
0.00576254
0.00636373
0.00699459
0.00765467
0.00834342
0.00905992
0.00980322
0.010572
0.0113647
0.0121796
0.0130151
0.0138689
0.0147392
0.0156237
0.0165204
0.0174272
0.018342
0.0192627
0.0201874
0.0211142
0.0220413
0.0229671
0.0238899
0.0248082
0.0257208
0.0266264
0.0275244
0.0284147
9.14096e-05
0.00029557
0.000526328
0.000774763
0.00104571
0.0013403
0.00165939
0.00200381
0.00237436
0.00277175
0.00319672
0.00364989
0.0041318
0.0046429
0.00518355
0.0057539
0.00635398
0.00698363
0.00764248
0.00832995
0.00904522
0.00978724
0.0105547
0.0113462
0.01216
0.0129941
0.0138469
0.0147161
0.0155997
0.0164955
0.0174014
0.0183155
0.0192356
0.0201598
0.0210861
0.022013
0.0229385
0.0238611
0.0247794
0.025692
0.026598
0.0274966
0.0283881
9.14066e-05
0.000295512
0.000526143
0.000774359
0.00104505
0.00133931
0.00165798
0.0020019
0.00237187
0.00276862
0.00319285
0.00364521
0.00412624
0.00463641
0.00517604
0.00574532
0.00634428
0.00697279
0.00763042
0.00831661
0.00903063
0.00977138
0.0105376
0.0113278
0.0121404
0.0129734
0.013825
0.0146932
0.0155758
0.0164707
0.0173759
0.0182891
0.0192086
0.0201323
0.0210582
0.0219847
0.02291
0.0238325
0.0247507
0.0256634
0.0265694
0.0274676
0.0283557
9.13332e-05
0.000295426
0.000525905
0.000773943
0.00104438
0.00133829
0.00165655
0.00200001
0.00236938
0.00276551
0.00318902
0.00364061
0.00412076
0.00462999
0.00516858
0.00573682
0.00633466
0.00696198
0.00761843
0.00830342
0.00901619
0.00975566
0.0105206
0.0113096
0.0121209
0.0129528
0.0138033
0.0146704
0.015552
0.016446
0.0173504
0.018263
0.0191818
0.0201049
0.0210305
0.0219566
0.0228816
0.023804
0.0247222
0.0256349
0.026541
0.0274395
0.0283303
9.12476e-05
0.000295335
0.000525669
0.000773524
0.00104371
0.00133728
0.00165513
0.00199809
0.00236691
0.0027624
0.00318521
0.00363598
0.0041153
0.00462359
0.00516121
0.00572837
0.00632513
0.00695127
0.00760654
0.0082903
0.00900181
0.00974004
0.0105037
0.0112915
0.0121016
0.0129323
0.0137817
0.0146477
0.0155284
0.0164215
0.0173251
0.0182369
0.0191551
0.0200777
0.0210028
0.0219286
0.0228534
0.0237756
0.0246937
0.0256064
0.0265127
0.0274113
0.0283017
9.1181e-05
0.000295252
0.000525464
0.000773128
0.00104302
0.00133626
0.00165373
0.00199619
0.00236448
0.00275931
0.00318143
0.00363141
0.00410988
0.00461726
0.00515392
0.00572002
0.00631565
0.00694068
0.00759474
0.00827732
0.00898755
0.00972453
0.010487
0.0112735
0.0120824
0.012912
0.0137603
0.0146253
0.0155049
0.0163971
0.0172999
0.018211
0.0191286
0.0200507
0.0209753
0.0219007
0.0228253
0.0237473
0.0246654
0.0255781
0.0264844
0.0273832
0.0282734
9.11631e-05
0.000295187
0.000525273
0.00077273
0.00104239
0.0013353
0.00165233
0.00199433
0.00236206
0.00275627
0.00317767
0.0036269
0.00410451
0.00461098
0.00514666
0.00571174
0.00630626
0.00693016
0.007583
0.00826435
0.00897339
0.00970913
0.0104704
0.0112556
0.0120634
0.0128917
0.013739
0.0146029
0.0154816
0.0163729
0.0172748
0.0181852
0.0191022
0.0200237
0.0209479
0.021873
0.0227973
0.0237191
0.0246371
0.02555
0.0264565
0.0273562
0.0282493
9.11501e-05
0.00029513
0.0005251
0.000772352
0.00104174
0.00133432
0.00165097
0.00199249
0.00235968
0.00275326
0.00317396
0.00362241
0.00409918
0.00460476
0.00513945
0.00570351
0.00629695
0.00691969
0.00757142
0.00825151
0.00895933
0.00969386
0.0104538
0.0112379
0.0120444
0.0128717
0.0137178
0.0145807
0.0154584
0.0163488
0.0172499
0.0181596
0.0190759
0.0199969
0.0209207
0.0218454
0.0227694
0.0236911
0.0246091
0.0255221
0.026429
0.0273293
0.0282231
9.10675e-05
0.000295044
0.000524861
0.000771953
0.0010411
0.00133335
0.0016496
0.00199067
0.00235729
0.00275028
0.00317029
0.003618
0.00409393
0.00459859
0.00513229
0.00569532
0.0062877
0.00690932
0.00755988
0.00823881
0.00894542
0.00967866
0.0104374
0.0112203
0.0120256
0.0128517
0.0136967
0.0145586
0.0154354
0.0163249
0.0172252
0.0181342
0.0190498
0.0199702
0.0208935
0.0218179
0.0227416
0.0236632
0.0245812
0.0254943
0.0264016
0.0273022
0.0281954
9.09696e-05
0.000294938
0.000524613
0.000771541
0.00104043
0.00133237
0.00164823
0.00198883
0.00235493
0.00274729
0.00316662
0.00361356
0.00408869
0.00459245
0.00512524
0.00568724
0.00627855
0.00689903
0.00754844
0.00822622
0.00893156
0.00966363
0.0104212
0.0112028
0.012007
0.012832
0.0136758
0.0145366
0.0154124
0.0163011
0.0172005
0.0181088
0.0190238
0.0199437
0.0208665
0.0217905
0.0227141
0.0236356
0.0245535
0.0254668
0.0263743
0.0272752
0.0281689
9.08956e-05
0.000294862
0.00052441
0.000771152
0.00103977
0.00133139
0.00164688
0.001987
0.00235257
0.00274434
0.003163
0.00360918
0.00408349
0.00458637
0.00511821
0.00567921
0.00626946
0.00688884
0.00753707
0.00821366
0.00891785
0.00964868
0.010405
0.0111854
0.0119885
0.0128123
0.013655
0.0145148
0.0153896
0.0162774
0.017176
0.0180835
0.0189979
0.0199172
0.0208396
0.0217633
0.0226866
0.023608
0.0245259
0.0254393
0.0263468
0.0272475
0.0281394
9.08677e-05
0.000294796
0.000524232
0.000770763
0.00103916
0.00133046
0.00164554
0.00198521
0.00235025
0.00274141
0.00315939
0.00360484
0.00407832
0.00458034
0.00511122
0.00567123
0.00626043
0.00687874
0.00752581
0.00820118
0.00890419
0.00963383
0.010389
0.0111682
0.01197
0.0127927
0.0136344
0.0144932
0.015367
0.0162539
0.0171517
0.0180584
0.0189722
0.019891
0.0208129
0.0217363
0.0226593
0.0235805
0.0244984
0.0254118
0.0263194
0.0272198
0.0281117
9.08287e-05
0.000294728
0.000524041
0.000770383
0.00103853
0.00132952
0.00164421
0.00198343
0.00234796
0.00273851
0.00315583
0.00360054
0.00407324
0.00457436
0.00510431
0.00566332
0.00625147
0.00686866
0.00751463
0.00818885
0.00889064
0.0096191
0.010373
0.0111511
0.0119517
0.0127733
0.0136139
0.0144716
0.0153445
0.0162304
0.0171274
0.0180335
0.0189466
0.0198648
0.0207863
0.0217093
0.0226321
0.0235532
0.0244711
0.0253844
0.026292
0.0271925
0.0280852
9.07361e-05
0.000294639
0.000523802
0.000769986
0.00103789
0.00132857
0.00164289
0.00198167
0.00234564
0.00273564
0.00315227
0.00359627
0.00406814
0.00456844
0.00509743
0.00565546
0.0062426
0.00685868
0.00750353
0.0081766
0.00887724
0.00960444
0.0103572
0.0111341
0.0119336
0.012754
0.0135935
0.0144502
0.0153221
0.0162071
0.0171033
0.0180087
0.0189211
0.0198388
0.0207598
0.0216825
0.0226051
0.023526
0.0244438
0.0253571
0.0262646
0.0271647
0.0280552
9.06355e-05
0.000294541
0.000523564
0.000769588
0.00103725
0.00132762
0.00164156
0.00197989
0.00234339
0.00273276
0.00314878
0.00359202
0.00406313
0.00456254
0.00509067
0.0056477
0.00623377
0.00684881
0.00749252
0.00816447
0.00886388
0.00958994
0.0103415
0.0111172
0.0119155
0.0127348
0.0135732
0.0144289
0.0152998
0.016184
0.0170794
0.017984
0.0188958
0.0198129
0.0207335
0.0216558
0.0225781
0.0234989
0.0244166
0.0253299
0.0262375
0.0271385
0.0280331
9.05567e-05
0.000294469
0.000523365
0.00076921
0.00103661
0.00132668
0.00164027
0.00197814
0.00234113
0.00272993
0.00314528
0.00358784
0.00405814
0.0045567
0.00508391
0.00563998
0.00622504
0.00683899
0.00748157
0.00815235
0.00885062
0.0095755
0.0103259
0.0111004
0.0118976
0.0127157
0.0135531
0.0144078
0.0152777
0.016161
0.0170555
0.0179594
0.0188706
0.0197872
0.0207073
0.0216292
0.0225513
0.0234719
0.0243896
0.0253029
0.0262108
0.0271126
0.0280086
9.05218e-05
0.000294395
0.000523197
0.000768834
0.00103602
0.00132578
0.00163898
0.00197643
0.0023389
0.00272713
0.00314183
0.00358366
0.00405318
0.00455091
0.0050772
0.00563231
0.00621635
0.00682925
0.00747073
0.00814035
0.00883747
0.00956118
0.0103104
0.0110837
0.0118798
0.0126968
0.0135331
0.0143867
0.0152557
0.0161381
0.0170319
0.0179349
0.0188455
0.0197615
0.0206812
0.0216028
0.0225246
0.023445
0.0243626
0.0252759
0.0261837
0.0270848
0.0279763
9.04447e-05
0.000294324
0.000522985
0.000768456
0.0010354
0.00132487
0.0016377
0.00197474
0.00233667
0.00272433
0.00313841
0.00357953
0.0040483
0.00454515
0.00507054
0.00562471
0.00620774
0.00681956
0.00745997
0.00812848
0.00882445
0.00954697
0.010295
0.0110672
0.011862
0.012678
0.0135132
0.0143658
0.0152338
0.0161153
0.0170083
0.0179107
0.0188205
0.019736
0.0206553
0.0215765
0.022498
0.0234182
0.0243357
0.0252488
0.0261564
0.0270571
0.0279499
9.03419e-05
0.000294235
0.000522753
0.000768063
0.00103477
0.00132394
0.00163642
0.00197302
0.00233449
0.00272158
0.003135
0.00357543
0.00404341
0.00453948
0.00506396
0.00561715
0.00619921
0.00680996
0.00744929
0.00811667
0.00881148
0.00953285
0.0102797
0.0110507
0.0118445
0.0126593
0.0134934
0.014345
0.0152121
0.0160927
0.0169848
0.0178865
0.0187958
0.0197106
0.0206294
0.0215503
0.0224715
0.0233915
0.0243087
0.0252216
0.0261287
0.0270279
0.0279158
9.02508e-05
0.00029415
0.000522539
0.000767675
0.00103415
0.00132302
0.00163516
0.00197131
0.00233229
0.00271883
0.00313165
0.00357135
0.00403859
0.00453381
0.00505744
0.00560971
0.00619071
0.00680047
0.00743869
0.00810498
0.00879861
0.00951883
0.0102645
0.0110344
0.011827
0.0126407
0.0134738
0.0143244
0.0151905
0.0160702
0.0169615
0.0178624
0.018771
0.0196854
0.0206037
0.0215242
0.0224451
0.0233648
0.0242817
0.0251943
0.026101
0.0270004
0.0278922
9.02063e-05
0.000294071
0.000522373
0.000767327
0.00103356
0.00132215
0.0016339
0.00196964
0.00233013
0.00271611
0.00312829
0.00356732
0.00403379
0.00452821
0.00505096
0.00560228
0.0061823
0.006791
0.00742814
0.0080933
0.00878583
0.0095049
0.0102495
0.0110181
0.0118096
0.0126222
0.0134543
0.0143038
0.015169
0.0160479
0.0169383
0.0178385
0.0187465
0.0196603
0.0205781
0.0214981
0.0224187
0.023338
0.0242547
0.0251671
0.0260737
0.0269736
0.0278672
9.01603e-05
0.000294005
0.00052219
0.000766962
0.00103297
0.00132126
0.00163267
0.00196799
0.002328
0.00271342
0.00312498
0.00356333
0.00402904
0.00452265
0.00504452
0.00559491
0.00617396
0.00678164
0.0074177
0.00808173
0.00877314
0.00949108
0.0102344
0.011002
0.0117924
0.0126039
0.0134349
0.0142834
0.0151476
0.0160256
0.0169153
0.0178147
0.018722
0.0196352
0.0205526
0.0214721
0.0223923
0.0233114
0.0242278
0.0251399
0.0260465
0.0269465
0.0278391
9.00475e-05
0.000293917
0.000521941
0.000766576
0.00103238
0.00132038
0.00163143
0.00196636
0.00232585
0.00271075
0.0031217
0.00355938
0.00402434
0.00451713
0.0050381
0.00558758
0.00616566
0.00677232
0.00740734
0.00807029
0.00876059
0.00947733
0.0102196
0.010986
0.0117753
0.0125857
0.0134156
0.0142631
0.0151264
0.0160034
0.0168923
0.017791
0.0186976
0.0196103
0.0205271
0.0214462
0.022366
0.0232848
0.0242009
0.0251129
0.0260193
0.0269191
0.0278107
8.9921e-05
0.000293809
0.000521685
0.000766179
0.00103176
0.00131948
0.0016302
0.0019647
0.00232375
0.00270808
0.00311843
0.00355542
0.00401967
0.00451165
0.00503181
0.00558035
0.00615746
0.00676308
0.00739705
0.00805894
0.00874807
0.00946372
0.0102048
0.0109701
0.0117582
0.0125676
0.0133964
0.0142429
0.0151052
0.0159814
0.0168694
0.0177674
0.0186734
0.0195854
0.0205017
0.0214204
0.0223398
0.0232583
0.0241741
0.025086
0.0259925
0.0268929
0.0277873
8.98191e-05
0.000293729
0.000521478
0.000765804
0.00103114
0.00131858
0.00162898
0.00196305
0.00232164
0.00270544
0.00311519
0.00355151
0.00401504
0.00450622
0.00502552
0.00557317
0.00614931
0.00675393
0.00738682
0.00804761
0.00873566
0.00945017
0.0101901
0.0109543
0.0117413
0.0125496
0.0133774
0.0142229
0.0150842
0.0159595
0.0168467
0.0177439
0.0186492
0.0195606
0.0204764
0.0213946
0.0223137
0.0232318
0.0241475
0.0250592
0.025966
0.026867
0.027762
8.97619e-05
0.000293648
0.000521304
0.000765431
0.00103057
0.00131774
0.00162776
0.00196144
0.00231956
0.00270283
0.00311197
0.00354764
0.00401042
0.00450084
0.00501927
0.00556602
0.00614121
0.00674486
0.00737667
0.00803638
0.00872333
0.00943672
0.0101756
0.0109386
0.0117245
0.0125317
0.0133584
0.0142029
0.0150633
0.0159377
0.0168241
0.0177205
0.0186251
0.019536
0.0204512
0.021369
0.0222876
0.0232054
0.024121
0.0250328
0.0259398
0.0268413
0.0277367
8.97055e-05
0.000293582
0.000521133
0.000765081
0.00102999
0.00131688
0.00162657
0.00195985
0.00231751
0.00270024
0.0031088
0.0035438
0.00400587
0.00449551
0.0050131
0.00555894
0.00613319
0.00673581
0.00736665
0.00802523
0.00871109
0.0094234
0.0101611
0.010923
0.0117078
0.0125139
0.0133396
0.0141831
0.0150425
0.015916
0.0168016
0.0176973
0.0186012
0.0195114
0.0204261
0.0213434
0.0222617
0.0231793
0.0240947
0.0250066
0.0259139
0.0268161
0.0277128
8.95825e-05
0.000293491
0.000520889
0.000764707
0.00102941
0.00131602
0.00162537
0.00195827
0.00231543
0.00269768
0.00310563
0.00354
0.00400135
0.0044902
0.00500694
0.00555191
0.00612521
0.00672685
0.00735665
0.00801421
0.00869898
0.00941012
0.0101467
0.0109075
0.0116912
0.0124962
0.0133209
0.0141634
0.0150219
0.0158944
0.0167792
0.0176741
0.0185773
0.0194869
0.0204011
0.021318
0.0222359
0.0231533
0.0240686
0.0249806
0.0258885
0.0267913
0.0276889
8.94445e-05
0.000293377
0.000520627
0.00076431
0.0010288
0.00131514
0.00162417
0.00195667
0.00231341
0.0026951
0.00310248
0.00353621
0.00399687
0.00448495
0.0050009
0.00554496
0.00611733
0.00671797
0.00734675
0.00800327
0.00868691
0.00939698
0.0101325
0.0108922
0.0116747
0.0124787
0.0133022
0.0141438
0.0150013
0.015873
0.0167569
0.0176511
0.0185536
0.0194626
0.0203761
0.0212926
0.0222102
0.0231274
0.0240427
0.024955
0.025863
0.0267658
0.0276611
8.93728e-05
0.000293307
0.000520464
0.000763967
0.00102823
0.0013143
0.001623
0.0019551
0.0023114
0.00269258
0.0030994
0.00353247
0.00399243
0.00447974
0.00499487
0.00553806
0.0061095
0.00670917
0.0073369
0.00799235
0.00867494
0.00938391
0.0101183
0.0108769
0.0116584
0.0124612
0.0132838
0.0141243
0.0149809
0.0158516
0.0167347
0.0176281
0.0185299
0.0194383
0.0203514
0.0212674
0.0221848
0.0231017
0.0240171
0.0249295
0.0258378
0.0267413
0.0276392
8.93054e-05
0.00029323
0.000520281
0.000763607
0.00102767
0.00131348
0.00162185
0.00195356
0.00230941
0.00269009
0.00309632
0.00352876
0.00398801
0.00447458
0.00498888
0.00553121
0.00610172
0.00670043
0.00732712
0.00798154
0.00866306
0.00937094
0.0101042
0.0108617
0.0116421
0.0124439
0.0132654
0.0141049
0.0149605
0.0158304
0.0167126
0.0176052
0.0185064
0.0194142
0.0203267
0.0212424
0.0221594
0.0230763
0.0239916
0.0249042
0.0258129
0.0267167
0.0276148
8.91729e-05
0.000293136
0.000520037
0.000763229
0.00102709
0.00131263
0.00162068
0.00195204
0.00230741
0.00268759
0.00309327
0.00352508
0.00398366
0.00446945
0.00498293
0.0055244
0.00609399
0.00669174
0.00731749
0.00797082
0.0086513
0.00935808
0.0100902
0.0108466
0.0116259
0.0124266
0.0132471
0.0140856
0.0149403
0.0158093
0.0166907
0.0175826
0.018483
0.0193902
0.0203023
0.0212175
0.0221342
0.023051
0.0239664
0.0248791
0.025788
0.0266919
0.0275894
8.9033e-05
0.000293037
0.000519792
0.000762837
0.00102649
0.00131177
0.00161952
0.00195049
0.00230544
0.00268513
0.00309023
0.00352144
0.0039793
0.00446439
0.00497704
0.00551766
0.00608637
0.00668314
0.00730789
0.00796021
0.0086396
0.0093453
0.0100764
0.0108317
0.0116099
0.0124095
0.013229
0.0140665
0.0149202
0.0157882
0.0166688
0.0175599
0.0184597
0.0193663
0.0202779
0.0211927
0.0221092
0.0230259
0.0239412
0.024854
0.025763
0.0266669
0.0275646
8.89106e-05
0.000292926
0.00051956
0.000762457
0.0010259
0.00131093
0.00161836
0.00194896
0.0023035
0.00268267
0.00308725
0.00351781
0.00397502
0.00445935
0.00497126
0.005511
0.00607878
0.00667464
0.00729837
0.0079497
0.00862799
0.00933263
0.0100626
0.0108168
0.0115939
0.0123925
0.0132109
0.0140474
0.0149002
0.0157674
0.0166471
0.0175375
0.0184366
0.0193425
0.0202536
0.0211681
0.0220844
0.0230009
0.0239162
0.024829
0.0257379
0.0266415
0.0275383
8.88413e-05
0.000292851
0.000519406
0.000762112
0.00102535
0.00131013
0.00161724
0.00194745
0.00230156
0.00268026
0.00308426
0.00351423
0.00397076
0.00445437
0.00496549
0.0055044
0.00607128
0.00666617
0.00728892
0.0079392
0.00861648
0.00932003
0.0100489
0.0108021
0.0115781
0.0123756
0.013193
0.0140285
0.0148803
0.0157466
0.0166255
0.0175151
0.0184135
0.0193189
0.0202295
0.0211436
0.0220597
0.0229759
0.0238912
0.0248038
0.0257124
0.0266154
0.0275103
8.87707e-05
0.00029277
0.000519227
0.00076177
0.0010248
0.00130931
0.00161612
0.00194598
0.00229966
0.00267787
0.00308133
0.00351069
0.00396655
0.00444945
0.00495977
0.00549785
0.00606384
0.00665781
0.00727957
0.00792881
0.00860505
0.00930753
0.0100354
0.0107874
0.0115624
0.0123588
0.0131752
0.0140097
0.0148605
0.015726
0.016604
0.0174928
0.0183906
0.0192954
0.0202055
0.0211193
0.022035
0.0229511
0.0238661
0.0247785
0.0256867
0.0265889
0.0274827
8.86359e-05
0.000292669
0.000518979
0.000761401
0.00102424
0.0013085
0.001615
0.00194452
0.00229775
0.00267549
0.00307843
0.00350721
0.00396239
0.00444454
0.00495409
0.00549134
0.00605646
0.0066495
0.00727031
0.00791856
0.00859377
0.00929517
0.0100219
0.0107729
0.0115468
0.0123422
0.0131574
0.013991
0.0148409
0.0157054
0.0165827
0.0174708
0.0183678
0.0192721
0.0201817
0.021095
0.0220104
0.0229263
0.023841
0.0247532
0.025661
0.0265629
0.0274576
8.84915e-05
0.000292547
0.000518723
0.00076102
0.00102367
0.00130768
0.00161389
0.00194305
0.00229589
0.00267315
0.00307554
0.00350372
0.00395828
0.00443974
0.00494851
0.00548492
0.0060492
0.00664128
0.00726114
0.00790841
0.00858254
0.00928291
0.0100086
0.0107585
0.0115313
0.0123257
0.0131399
0.0139724
0.0148214
0.015685
0.0165614
0.0174488
0.0183452
0.0192488
0.020158
0.0210709
0.0219859
0.0229015
0.0238159
0.0247277
0.0256351
0.0265363
0.0274294
8.83751e-05
0.000292451
0.000518514
0.000760645
0.00102309
0.00130687
0.0016128
0.00194158
0.00229403
0.00267083
0.00307271
0.00350029
0.00395422
0.00443496
0.004943
0.00547862
0.00604197
0.00663318
0.00725204
0.0078983
0.00857143
0.00927074
0.00999535
0.0107442
0.0115159
0.0123092
0.0131225
0.013954
0.014802
0.0156647
0.0165403
0.0174269
0.0183226
0.0192257
0.0201343
0.0210468
0.0219614
0.0228767
0.0237908
0.0247021
0.0256091
0.0265097
0.0274024
8.831e-05
0.000292352
0.00051834
0.000760306
0.00102256
0.0013061
0.00161171
0.00194016
0.0022922
0.00266854
0.0030699
0.00349691
0.00395019
0.00443026
0.00493753
0.00547233
0.00603485
0.00662514
0.00724305
0.00788831
0.00856042
0.00925869
0.00998226
0.01073
0.0115007
0.0122929
0.0131051
0.0139357
0.0147827
0.0156446
0.0165193
0.0174051
0.0183002
0.0192026
0.0201107
0.0210227
0.021937
0.0228518
0.0237656
0.0246765
0.025583
0.0264834
0.0273762
8.82529e-05
0.000292265
0.000518172
0.000759971
0.00102203
0.00130533
0.00161066
0.00193877
0.00229042
0.00266631
0.00306715
0.0034936
0.00394625
0.00442564
0.00493216
0.00546617
0.00602784
0.00661723
0.00723419
0.00787844
0.00854954
0.00924679
0.00996924
0.0107159
0.0114856
0.0122767
0.0130879
0.0139174
0.0147636
0.0156245
0.0164984
0.0173835
0.0182778
0.0191797
0.0200873
0.0209988
0.0219126
0.022827
0.0237403
0.0246509
0.025557
0.0264571
0.0273499
8.81427e-05
0.000292144
0.000517936
0.000759616
0.0010215
0.00130456
0.0016096
0.0019374
0.00228863
0.00266409
0.00306444
0.00349034
0.00394237
0.00442105
0.00492685
0.00546007
0.0060209
0.0066094
0.00722544
0.00786873
0.00853883
0.00923498
0.00995641
0.010702
0.0114706
0.0122607
0.0130708
0.0138994
0.0147446
0.0156046
0.0164777
0.017362
0.0182556
0.0191568
0.0200638
0.0209748
0.0218882
0.0228022
0.0237151
0.0246252
0.025531
0.0264308
0.0273233
8.80221e-05
0.000291998
0.000517701
0.000759265
0.00102097
0.00130381
0.00160858
0.00193605
0.00228695
0.00266198
0.00306181
0.00348717
0.00393861
0.00441664
0.00492171
0.00545415
0.00601414
0.00660172
0.00721684
0.00785919
0.00852821
0.00922336
0.00994372
0.0106883
0.0114557
0.0122448
0.0130539
0.0138815
0.0147257
0.0155848
0.016457
0.0173405
0.0182334
0.019134
0.0200404
0.0209509
0.0218638
0.0227773
0.0236898
0.0245996
0.0255052
0.0264051
0.0272988
8.79961e-05
0.000291898
0.00051751
0.000758925
0.00102043
0.00130305
0.00160758
0.00193472
0.00228525
0.00265986
0.00305925
0.00348404
0.00393489
0.00441226
0.00491663
0.0054483
0.00600746
0.00659418
0.00720833
0.00784968
0.00851773
0.00921184
0.00993116
0.0106746
0.0114411
0.0122291
0.0130371
0.0138637
0.0147069
0.0155651
0.0164365
0.0173192
0.0182114
0.0191113
0.0200171
0.020927
0.0218394
0.0227525
0.0236646
0.0245741
0.0254794
0.0263794
0.0272731
8.79709e-05
0.00029184
0.000517377
0.000758664
0.00102005
0.00130249
0.00160676
0.00193362
0.00228381
0.00265802
0.00305694
0.00348123
0.00393147
0.00440821
0.00491185
0.00544274
0.00600106
0.0065869
0.00720009
0.00784046
0.0085075
0.00920056
0.00991882
0.0106612
0.0114265
0.0122135
0.0130205
0.013846
0.0146882
0.0155455
0.016416
0.0172979
0.0181893
0.0190885
0.0199937
0.0209031
0.021815
0.0227276
0.0236393
0.0245485
0.0254536
0.0263534
0.0272466
8.81504e-05
0.00029159
0.000517111
0.000758285
0.00101952
0.00130176
0.00160578
0.00193234
0.00228215
0.00265593
0.00305439
0.00347814
0.00392779
0.00440387
0.00490681
0.00543694
0.00599446
0.00657944
0.00719178
0.00783116
0.00849721
0.00918927
0.00990642
0.0106478
0.011412
0.0121979
0.0130038
0.0138283
0.0146696
0.0155259
0.0163955
0.0172765
0.0181672
0.0190657
0.0199702
0.020879
0.0217904
0.0227025
0.0236139
0.0245228
0.0254277
0.0263273
0.0272201
8.77629e-05
0.000291871
0.000516914
0.000757809
0.00101884
0.00130092
0.00160479
0.00193119
0.00228078
0.00265435
0.00305248
0.00347588
0.0039251
0.00440066
0.00490298
0.00543243
0.00598918
0.00657326
0.00718463
0.00782299
0.00848792
0.00917874
0.0098947
0.0106348
0.0113977
0.0121823
0.012987
0.0138103
0.0146504
0.0155056
0.0163742
0.0172543
0.0181441
0.0190418
0.0199458
0.020854
0.0217649
0.0226767
0.0235878
0.0244965
0.0254014
0.026301
0.0271944
9.09295e-05
0.000291316
0.000519295
0.000761755
0.00102377
0.00130642
0.00161057
0.00193698
0.00228636
0.00265938
0.0030568
0.00347924
0.00392727
0.00440143
0.0049022
0.00542986
0.00598468
0.0065668
0.0071761
0.00781238
0.00847515
0.00916391
0.00987783
0.010616
0.0113771
0.01216
0.0129631
0.013785
0.0146239
0.0154781
0.0163458
0.0172252
0.0181146
0.019012
0.0199158
0.020824
0.0217351
0.0226471
0.0235586
0.0244678
0.0253733
0.0262735
0.0271667
7.07917e-05
0.00028147
0.000495022
0.000728845
0.000983662
0.00125971
0.0015576
0.00187797
0.00222155
0.00258908
0.0029813
0.00339894
0.0038426
0.00431287
0.0048103
0.00533524
0.00588793
0.00646846
0.00707677
0.00771268
0.00837573
0.00906526
0.00978047
0.0105204
0.0112838
0.0120692
0.0128754
0.0137005
0.0145428
0.0154007
0.0162722
0.0171556
0.018049
0.0189504
0.0198582
0.0207705
0.0216855
0.0226015
0.0235168
0.0244298
0.0253389
0.0262426
0.0271392
0.000669243
0.00243192
0.00420095
0.00595469
0.00769156
0.00941347
0.0111182
0.0128066
0.0144804
0.0161414
0.0177917
0.0194335
0.021069
0.0226994
0.0243266
0.0259518
0.0275758
0.0291997
0.0308245
0.032451
0.0340792
0.0357094
0.0373421
0.0389776
0.0406155
0.042256
0.0438992
0.0455444
0.0471918
0.0488407
0.0504912
0.0521429
0.0537951
0.0554473
0.0570989
0.0587496
0.0603987
0.0620458
0.06369
0.0653304
0.0669663
0.0685967
0.0702226
8.74897e-05
0.00102673
0.00233045
0.00376594
0.00529255
0.00687311
0.00848726
0.0101229
0.0117723
0.0134302
0.015094
0.0167616
0.0184325
0.0201055
0.0217805
0.0234575
0.0251368
0.0268183
0.0285024
0.0301891
0.0318783
0.0335702
0.0352646
0.0369617
0.0386612
0.040363
0.042067
0.0437726
0.0454798
0.0471881
0.048897
0.0506062
0.0523151
0.0540229
0.0557297
0.0574344
0.0591364
0.0608353
0.06253
0.0642201
0.0659045
0.0675822
0.0692529
0.000272666
0.000880617
0.00189222
0.00306422
0.00435013
0.00572038
0.00715571
0.00864262
0.0101709
0.0117331
0.013323
0.014936
0.0165682
0.0182168
0.0198793
0.0215539
0.023239
0.0249336
0.0266365
0.0283464
0.0300631
0.0317858
0.033514
0.0352467
0.0369838
0.0387247
0.0404687
0.0422154
0.0439645
0.0457151
0.0474666
0.0492185
0.0509699
0.0527207
0.05447
0.0562169
0.0579608
0.0597008
0.0614363
0.0631666
0.0648907
0.0666079
0.0683192
0.000288434
0.000795425
0.00166105
0.00267209
0.00379505
0.00500938
0.00630024
0.00765617
0.00906822
0.0105288
0.0120315
0.0135709
0.0151423
0.0167419
0.0183664
0.0200126
0.0216781
0.0233606
0.0250582
0.0267693
0.0284923
0.0302261
0.0319693
0.0337209
0.0354796
0.0372448
0.0390154
0.0407907
0.0425698
0.0443519
0.0461362
0.0479216
0.0497075
0.0514932
0.0532778
0.0550602
0.0568399
0.0586159
0.0603871
0.0621529
0.0639123
0.0656643
0.0674105
0.000289995
0.000700806
0.00146664
0.00236885
0.00337991
0.00448308
0.00566602
0.00691928
0.00823491
0.0096065
0.0110281
0.0124949
0.0140021
0.0155459
0.0171227
0.0187292
0.0203624
0.0220195
0.0236984
0.0253969
0.0271128
0.0288442
0.0305898
0.0323477
0.0341167
0.0358952
0.0376822
0.0394764
0.0412766
0.0430818
0.0448908
0.0467025
0.0485162
0.0503306
0.0521446
0.0539573
0.0557678
0.057575
0.0593779
0.0611753
0.0629661
0.0647489
0.066525
0.000285698
0.000623781
0.00131635
0.0021372
0.00306345
0.00408014
0.00517688
0.00634552
0.00757951
0.00887306
0.0102215
0.01162
0.0130649
0.0145522
0.0160786
0.0176407
0.0192355
0.0208605
0.0225127
0.0241899
0.0258898
0.0276103
0.0293491
0.0311047
0.032875
0.0346587
0.0364541
0.0382595
0.0400735
0.0418948
0.0437221
0.0455541
0.0473896
0.0492272
0.0510658
0.0529042
0.0547411
0.0565755
0.0584061
0.0602316
0.0620507
0.0638619
0.0656656
0.000281315
0.000566517
0.00120185
0.00195823
0.00281623
0.00376229
0.00478728
0.0058844
0.00704794
0.00827307
0.00955563
0.0108918
0.012278
0.0137109
0.015187
0.0167036
0.018258
0.0198471
0.0214685
0.0231195
0.0247978
0.0265012
0.0282273
0.0299739
0.0317393
0.0335217
0.035319
0.0371294
0.0389513
0.0407832
0.0426233
0.0444704
0.0463226
0.0481787
0.0500375
0.0518974
0.0537569
0.0556148
0.0574697
0.0593202
0.0611649
0.0630026
0.0648351
0.000276603
0.000521452
0.00111003
0.00181339
0.00261494
0.00350201
0.00446652
0.00550252
0.00660507
0.00777015
0.00899411
0.0102736
0.0116056
0.012987
0.0144152
0.0158873
0.0174007
0.0189529
0.0205413
0.0221632
0.0238165
0.0254987
0.0272076
0.028941
0.0306967
0.0324727
0.0342669
0.0360774
0.0379025
0.03974
0.0415884
0.0434459
0.0453107
0.0471814
0.0490564
0.0509339
0.0528127
0.0546907
0.0565668
0.0584395
0.0603071
0.0621683
0.0640245
0.000272343
0.00048464
0.00103403
0.00169278
0.00244676
0.00328374
0.00419649
0.00517961
0.00622895
0.00734098
0.00851253
0.00974076
0.0110229
0.0123566
0.0137393
0.0151685
0.0166419
0.018157
0.0197115
0.021303
0.0229293
0.0245879
0.0262768
0.0279936
0.0297361
0.0315021
0.0332893
0.035096
0.03692
0.0387593
0.040612
0.0424761
0.0443499
0.0462316
0.0481193
0.0500113
0.0519059
0.0538014
0.055696
0.0575882
0.0594759
0.0613573
0.0632319
0.000268453
0.000454047
0.000970166
0.00159073
0.00230396
0.00309772
0.00396543
0.00490231
0.00590473
0.0069695
0.00809395
0.00927564
0.0105122
0.0118016
0.0131415
0.0145299
0.0159646
0.0174434
0.0189642
0.0205249
0.0221232
0.0237568
0.0254236
0.0271215
0.0288481
0.0306011
0.0323787
0.0341784
0.0359982
0.0378359
0.0396895
0.0415572
0.0434368
0.0453262
0.0472236
0.049127
0.0510349
0.052945
0.0548558
0.0567651
0.0586711
0.0605709
0.0624618
0.000264831
0.000428208
0.000915671
0.0015031
0.00218093
0.00293694
0.00376505
0.00466107
0.00562165
0.00664398
0.00772595
0.00886518
0.01006
0.0113082
0.0126082
0.0139579
0.0153556
0.0167994
0.0182872
0.0198171
0.021387
0.0229949
0.0246386
0.0263159
0.0280247
0.0297629
0.0315284
0.0333186
0.0351316
0.0369651
0.038817
0.0406853
0.0425677
0.0444621
0.0463666
0.0482791
0.0501975
0.0521201
0.0540448
0.0559697
0.0578931
0.0598145
0.0617396
0.000261465
0.000405988
0.00086841
0.00142674
0.00207348
0.00279621
0.00358922
0.00444871
0.00537166
0.00635587
0.0073991
0.00849972
0.00965592
0.0108662
0.0121287
0.0134421
0.0148047
0.0162147
0.0176705
0.0191701
0.0207118
0.0222936
0.0239136
0.0255694
0.0272593
0.0289811
0.0307325
0.0325113
0.0343153
0.0361424
0.0379904
0.039857
0.0417399
0.0436369
0.0455462
0.0474654
0.0493924
0.0513252
0.0532617
0.0552002
0.0571393
0.059078
0.0610207
0.000258301
0.000386632
0.000827159
0.00136005
0.00197869
0.00267166
0.00343327
0.00425992
0.00514904
0.00609853
0.00710658
0.00817166
0.00929235
0.0104672
0.0116949
0.0129741
0.0143033
0.0156811
0.017106
0.018576
0.0200899
0.0216458
0.0232416
0.0248757
0.0265458
0.02825
0.029986
0.0317519
0.0335454
0.0353643
0.0372064
0.0390692
0.0409505
0.0428483
0.0447603
0.046684
0.0486176
0.0505586
0.0525051
0.0544553
0.0564074
0.0583594
0.0603101
0.000255231
0.000369695
0.000790803
0.001301
0.00189425
0.00256039
0.0032937
0.00409075
0.00494911
0.00586697
0.00684277
0.00787518
0.00896293
0.0101049
0.0113
0.012547
0.0138446
0.0151917
0.0165866
0.0180283
0.0195151
0.0210452
0.0226171
0.0242289
0.0258789
0.0275648
0.0292847
0.0310365
0.0328181
0.0346273
0.0364616
0.038319
0.0401973
0.042094
0.0440066
0.0459333
0.0478714
0.0498189
0.0517738
0.0537339
0.0556973
0.0576624
0.0596297
0.000252296
0.000354833
0.000758375
0.00124813
0.0018184
0.00246035
0.00316796
0.00393797
0.0047683
0.00565718
0.0066033
0.00760547
0.00866281
0.0097742
0.0109387
0.0121554
0.0134231
0.0147408
0.0161073
0.0175215
0.0189818
0.0204868
0.0220349
0.0236246
0.025254
0.0269211
0.0286242
0.0303612
0.0321298
0.033928
0.0357536
0.0376043
0.0394779
0.0413718
0.0432837
0.0452114
0.0471526
0.049105
0.0510665
0.0530347
0.0550076
0.0569834
0.0589619
0.000249755
0.000343264
0.00072929
0.00120047
0.00174984
0.00236975
0.00305388
0.00379922
0.00460378
0.00546594
0.00638467
0.00735892
0.00838791
0.0094707
0.0106066
0.0117946
0.013034
0.0143238
0.0156631
0.0170508
0.0184854
0.0199659
0.0214907
0.0230583
0.024667
0.0263153
0.0280011
0.0297226
0.0314775
0.033264
0.0350797
0.0369224
0.03879
0.0406797
0.0425895
0.044517
0.0464598
0.0484155
0.0503818
0.0523566
0.0543372
0.0563213
0.0583062
0.000248214
0.000338079
0.000703213
0.00115733
0.00168751
0.00228721
0.00294984
0.00367248
0.00445319
0.00529078
0.00618407
0.00713237
0.00813483
0.00919086
0.0102997
0.0114609
0.0126735
0.0139369
0.0152501
0.0166121
0.0180221
0.0194786
0.0209806
0.0225265
0.0241148
0.025744
0.0274123
0.0291177
0.0308585
0.0326324
0.0344374
0.0362712
0.0381314
0.0400161
0.0419226
0.0438486
0.0457916
0.0477491
0.0497191
0.0516989
0.0536864
0.0556791
0.0576777
0.000247657
0.000337743
0.000679668
0.00111794
0.00163044
0.00221159
0.00285443
0.00355607
0.00431484
0.00512954
0.00599925
0.00692327
0.00790098
0.00893189
0.0100155
0.0111512
0.0123384
0.0135765
0.0148648
0.0162023
0.0175883
0.0190217
0.0205013
0.0220259
0.0235941
0.0252043
0.0268548
0.0285441
0.0302701
0.0320309
0.0338246
0.0356486
0.0375009
0.0393793
0.0412814
0.0432046
0.0451466
0.047105
0.0490772
0.0510609
0.0530537
0.0550534
0.0570605
0.000247591
0.000339111
0.000658429
0.00108195
0.00157829
0.00214199
0.00276647
0.00344875
0.00418711
0.00498053
0.00582821
0.00672956
0.00768407
0.00869138
0.00975106
0.0108627
0.0120258
0.0132398
0.0145042
0.0158183
0.0171812
0.0185921
0.0200501
0.0215537
0.023102
0.0246934
0.0263263
0.0279992
0.0297102
0.0314575
0.0332391
0.0350527
0.0368964
0.0387678
0.0406643
0.0425838
0.0445239
0.0464818
0.0484553
0.0504417
0.0524384
0.0544426
0.0564513
0.000247656
0.000340362
0.000639137
0.00104897
0.00153037
0.00207776
0.00268517
0.00334932
0.00406871
0.00484227
0.00566934
0.00654938
0.00748216
0.00846723
0.00950435
0.0105932
0.0117333
0.0129244
0.014166
0.0154576
0.0167983
0.0181875
0.0196242
0.0211075
0.0226362
0.0242088
0.0258243
0.0274808
0.0291766
0.0309101
0.0326793
0.0344821
0.0363164
0.03818
0.0400702
0.0419852
0.0439222
0.0458788
0.0478525
0.0498405
0.0518403
0.0538492
0.0558661
0.000247608
0.00034104
0.000621557
0.00101867
0.00148616
0.00201825
0.00260968
0.00325698
0.0039586
0.00471351
0.0055212
0.00638136
0.00729361
0.00825769
0.00927338
0.0103406
0.0114589
0.0126282
0.013848
0.0151179
0.0164372
0.0178054
0.0192216
0.020685
0.0221944
0.0237488
0.0253467
0.0269868
0.0286675
0.030387
0.0321435
0.033935
0.0357594
0.0376144
0.039498
0.0414076
0.0433408
0.0452952
0.0472679
0.0492567
0.0512588
0.0532713
0.055293
0.000247365
0.000341153
0.000605434
0.000990678
0.00144513
0.00196286
0.00253936
0.00317087
0.00385576
0.00459325
0.0053828
0.00622415
0.00711697
0.00806115
0.00905665
0.0101033
0.0112009
0.0123493
0.0135483
0.0147973
0.0160961
0.0174439
0.0188402
0.0202842
0.0217749
0.0233112
0.0248919
0.0265157
0.0281812
0.0298865
0.0316301
0.0334099
0.0352239
0.0370701
0.0389462
0.0408497
0.0427785
0.0447297
0.046701
0.0486898
0.0506934
0.0527092
0.0547352
0.00024694
0.000340813
0.000590534
0.000964674
0.0014069
0.00191115
0.00247365
0.00309031
0.00375957
0.00448064
0.00525308
0.00607662
0.00695111
0.00787652
0.00885282
0.00987993
0.0109578
0.0120863
0.0132651
0.0144942
0.0157731
0.0171013
0.0184783
0.0199034
0.0213758
0.0228944
0.0244581
0.0260658
0.027716
0.0294071
0.0311377
0.0329054
0.0347089
0.0365458
0.0384138
0.0403109
0.0422344
0.044182
0.0461511
0.0481391
0.0501436
0.0521624
0.0541952
0.000246364
0.000340167
0.000576728
0.000940385
0.00137111
0.00186266
0.00241201
0.00301477
0.00366929
0.00437489
0.00513114
0.00593788
0.00679502
0.0077026
0.00866063
0.00966913
0.0107281
0.0118374
0.0129971
0.014207
0.0154668
0.016776
0.0181343
0.0195411
0.0209956
0.0224967
0.0240438
0.0256355
0.0272706
0.0289476
0.0306648
0.0324206
0.0342132
0.0360403
0.0379
0.0397898
0.0417077
0.0436509
0.0456171
0.0476035
0.0496076
0.0516269
0.0536585
0.00024573
0.000339281
0.000564216
0.000917725
0.00133766
0.00181735
0.00235415
0.0029437
0.00358434
0.00427526
0.00501626
0.00580704
0.00664776
0.00753837
0.00847902
0.00946977
0.0105106
0.0116018
0.0127431
0.0139345
0.0151758
0.0164667
0.0178069
0.0191958
0.0206327
0.022117
0.0236477
0.0252236
0.0268437
0.0285065
0.0302105
0.0319541
0.0337356
0.0355526
0.0374035
0.0392859
0.0411974
0.0431357
0.0450982
0.0470821
0.0490847
0.0511028
0.0531334
0.000245077
0.000338469
0.000554167
0.000896675
0.00130638
0.00177496
0.0022997
0.00287677
0.00350422
0.0041813
0.00490771
0.00568346
0.00650848
0.007383
0.008307
0.00928076
0.0103045
0.0113781
0.0125018
0.0136754
0.0148989
0.0161721
0.0174947
0.0188662
0.0202861
0.0217538
0.0232683
0.0248288
0.026434
0.0280827
0.0297736
0.0315049
0.0332749
0.0350818
0.0369236
0.0387981
0.0407029
0.0426356
0.0445936
0.0465743
0.0485745
0.0505909
0.0526205
0.000244481
0.00033825
0.000548186
0.000877299
0.00127708
0.00173509
0.00224836
0.00281357
0.00342849
0.00409243
0.00480509
0.00556644
0.00637659
0.00723562
0.00814385
0.00910145
0.0101086
0.0111655
0.0122722
0.0134287
0.014635
0.0158911
0.0171967
0.0185514
0.0199547
0.0214061
0.0229048
0.02445
0.0260405
0.0276753
0.0293529
0.031072
0.0328305
0.034627
0.0364595
0.0383256
0.0402233
0.04215
0.044103
0.0460798
0.0480773
0.050092
0.0521208
0.000243995
0.000338898
0.000545872
0.00085959
0.00124959
0.00169746
0.0021998
0.00275375
0.00335682
0.00400826
0.00470782
0.00545549
0.00625139
0.00709577
0.00798887
0.00893096
0.00992225
0.010963
0.0120533
0.0131934
0.0143832
0.0156227
0.0169118
0.01825
0.0196373
0.0210728
0.022556
0.0240862
0.0256622
0.0272832
0.0289477
0.0306542
0.0324014
0.0341874
0.0360102
0.0378678
0.0397579
0.0416782
0.0436261
0.0455987
0.0475931
0.0496059
0.0516338
0.000243688
0.000340218
0.000545549
0.000843347
0.00122371
0.00166192
0.00215384
0.00269702
0.00328883
0.00392838
0.00461544
0.00535002
0.0061324
0.00696274
0.00784137
0.0087686
0.00974469
0.0107699
0.0118445
0.0129687
0.0141426
0.015366
0.016639
0.0179614
0.0193329
0.0207529
0.022221
0.0237364
0.0252982
0.0269054
0.0285569
0.0302512
0.0319868
0.0337621
0.0355751
0.0374239
0.0393063
0.0412199
0.0431622
0.0451304
0.0471218
0.0491335
0.0511637
0.000243522
0.000341806
0.000545903
0.00082837
0.00119936
0.00162827
0.00211019
0.00264317
0.00322422
0.00385239
0.00452755
0.0052497
0.00601911
0.00683601
0.00770077
0.00861368
0.00957517
0.0105855
0.011645
0.0127539
0.0139122
0.0151202
0.0163777
0.0176847
0.0190407
0.0204457
0.0218989
0.0233999
0.0249476
0.0265413
0.0281798
0.0298618
0.0315859
0.0333504
0.0351535
0.0369934
0.0388678
0.0407745
0.0427108
0.0446744
0.0466626
0.048673
0.050705
0.000243414
0.000343354
0.000546179
0.000814422
0.00117638
0.00159638
0.00206881
0.00259195
0.00316266
0.00378006
0.00444379
0.00515407
0.00591103
0.00671505
0.00756647
0.00846574
0.00941319
0.0104092
0.0114542
0.0125482
0.0136916
0.0148845
0.016127
0.0174189
0.0187601
0.0201503
0.021589
0.0230756
0.0246097
0.0261899
0.0278156
0.0294855
0.031198
0.0329516
0.0347449
0.0365757
0.0384419
0.0403413
0.0422715
0.0442302
0.0462146
0.0482222
0.0502506
0.000243243
0.000344649
0.000545981
0.0008013
0.00115465
0.00156618
0.00202962
0.00254318
0.00310405
0.00371106
0.00436393
0.00506277
0.00580783
0.00659951
0.00743819
0.0083243
0.00925824
0.0102405
0.0112713
0.012351
0.01348
0.0146584
0.0158862
0.0171635
0.0184902
0.0198659
0.0212904
0.0227632
0.0242836
0.0258507
0.0274637
0.0291214
0.0308223
0.0325653
0.0343485
0.03617
0.0380279
0.03992
0.041844
0.0437973
0.0457774
0.0477813
0.049806
0.000242959
0.000345644
0.000545232
0.000788874
0.00113404
0.00153747
0.00199233
0.0024967
0.00304811
0.00364518
0.00428762
0.00497553
0.00570918
0.006489
0.00731541
0.00818886
0.0091098
0.0100787
0.0110959
0.0121619
0.0132769
0.0144411
0.0156548
0.0169178
0.0182304
0.019592
0.0210026
0.0224617
0.0239687
0.025523
0.0271234
0.0287689
0.0304585
0.0321907
0.0339638
0.035776
0.0376255
0.03951
0.0414274
0.0433752
0.0453506
0.0473507
0.0493723
0.000242628
0.000346346
0.000544023
0.000777059
0.00111445
0.00151018
0.00195681
0.00245229
0.00299463
0.00358218
0.00421461
0.00489199
0.00561473
0.00638315
0.00719775
0.00805902
0.00896743
0.00992344
0.0109275
0.0119802
0.0130816
0.0142321
0.015432
0.0166813
0.01798
0.0193279
0.020725
0.0221707
0.0236646
0.0252059
0.026794
0.0284277
0.030106
0.0318273
0.0335903
0.0353931
0.037234
0.039111
0.0410216
0.0429636
0.0449343
0.0469309
0.0489504
0.000242258
0.000346781
0.000542482
0.000765901
0.00109586
0.00148419
0.00192288
0.00240985
0.00294346
0.00352183
0.00414461
0.00481198
0.00552419
0.00628165
0.00708483
0.00793435
0.00883066
0.00977426
0.0107657
0.0118054
0.0128937
0.014031
0.0152174
0.0164533
0.0177384
0.0190731
0.0204568
0.0218894
0.0233704
0.0248993
0.0264751
0.028097
0.029764
0.0314746
0.0332274
0.035021
0.0368533
0.0387224
0.0406261
0.0425622
0.0445283
0.046522
0.0485425
0.000241856
0.000347009
0.000540733
0.000755605
0.00107818
0.00145939
0.00189046
0.00236921
0.00289437
0.00346398
0.00407755
0.00473523
0.00543726
0.00618413
0.0069764
0.00781459
0.00869922
0.00963088
0.0106101
0.0116372
0.0127128
0.0138372
0.0150107
0.0162334
0.0175055
0.018827
0.0201977
0.0216175
0.0230859
0.0246022
0.026166
0.0277763
0.029432
0.031132
0.0328749
0.0346589
0.0364826
0.0383438
0.0402406
0.0421707
0.0441319
0.0461222
0.048141
0.000241403
0.000347098
0.000538974
0.000746778
0.00106143
0.00143568
0.0018594
0.00233021
0.00284732
0.00340848
0.00401318
0.0046615
0.00535377
0.00609049
0.00687219
0.00769944
0.00857279
0.00949286
0.0104601
0.0114751
0.0125384
0.0136503
0.0148111
0.016021
0.0172804
0.0185892
0.0199472
0.0213543
0.0228103
0.0243145
0.0258665
0.0274652
0.0291098
0.0307992
0.032532
0.0343067
0.0361216
0.037975
0.0398646
0.0417884
0.0437441
0.0457292
0.0477406
0.000240888
0.000347176
0.000537539
0.000740231
0.00104568
0.00141302
0.00182965
0.00229293
0.00280217
0.00335517
0.00395131
0.00459064
0.0052735
0.00600041
0.00677191
0.0075886
0.00845105
0.00935986
0.0103156
0.0113189
0.0123702
0.0134699
0.0146184
0.015816
0.0170629
0.0183591
0.0197047
0.0210996
0.0225433
0.0240356
0.0255758
0.0271631
0.0287969
0.0304758
0.0321985
0.0339638
0.03577
0.0376152
0.0394976
0.0414148
0.0433644
0.0453436
0.0473485
0.000240407
0.000347391
0.000536839
0.000736232
0.00103108
0.00139144
0.00180122
0.00225729
0.00275881
0.00330392
0.00389179
0.00452241
0.00519624
0.00591367
0.00667533
0.0074818
0.00833365
0.00923164
0.0101762
0.0111681
0.0122077
0.0132956
0.0144321
0.0156177
0.0168524
0.0181365
0.01947
0.0208527
0.0222845
0.023765
0.0252937
0.0268699
0.0284927
0.0301612
0.0318739
0.0336299
0.0354272
0.0372643
0.0391392
0.0410496
0.0429931
0.044967
0.046969
0.000239991
0.000347819
0.000536951
0.000734161
0.00101762
0.00137092
0.00177402
0.00222308
0.0027171
0.00325455
0.00383442
0.00445673
0.00512175
0.00583004
0.00658217
0.00737872
0.00822044
0.00910785
0.0100417
0.0110225
0.0120508
0.0131272
0.0142521
0.0154258
0.0166487
0.0179209
0.0192425
0.0206134
0.0220335
0.0235024
0.0250197
0.0265848
0.028197
0.0298549
0.031558
0.0333045
0.035093
0.0369219
0.0387891
0.0406926
0.04263
0.0445986
0.0465967
0.000239652
0.000348458
0.000537707
0.000733168
0.00100516
0.0013514
0.00174797
0.00219021
0.00267698
0.00320703
0.0037792
0.00439341
0.00504995
0.00574939
0.0064923
0.00727932
0.00811111
0.00898836
0.00991172
0.0108818
0.0118991
0.0129643
0.0140779
0.0152401
0.0164514
0.017712
0.0190219
0.0203812
0.0217898
0.0232474
0.0247535
0.0263078
0.0279091
0.029557
0.0312502
0.0329873
0.034767
0.0365876
0.0384471
0.0403436
0.0422747
0.0442379
0.046231
0.000239353
0.000349242
0.000538809
0.000732587
0.00099353
0.00133279
0.00172298
0.00215861
0.00263833
0.00316123
0.00372594
0.00433233
0.00498068
0.00567155
0.00640554
0.0071833
0.0080055
0.00887285
0.00978598
0.0107456
0.0117523
0.0128066
0.0139091
0.0150601
0.0162602
0.0175094
0.0188079
0.0201559
0.0215532
0.0229996
0.0244947
0.0260381
0.0276291
0.0292668
0.0309501
0.032678
0.0344488
0.0362611
0.038113
0.0400024
0.041927
0.0438844
0.0458723
0.000239042
0.000350079
0.000539952
0.000731991
0.000982516
0.00131497
0.00169894
0.00212814
0.00260107
0.00311704
0.00367454
0.00427335
0.00491378
0.00559636
0.00632171
0.00709049
0.00790339
0.0087611
0.00966435
0.0106138
0.0116102
0.0126539
0.0137456
0.0148857
0.0160748
0.0173128
0.0186002
0.0199371
0.0213233
0.0227587
0.024243
0.0257758
0.0273565
0.0289841
0.0306577
0.0323762
0.0341383
0.0359422
0.0377864
0.0396686
0.0415866
0.0435377
0.0455185
0.000238754
0.000350897
0.000541013
0.000731213
0.000972047
0.00129791
0.00167583
0.0020988
0.00256511
0.00307433
0.00362487
0.00421633
0.00484911
0.00552366
0.00624063
0.00700066
0.00780453
0.00865291
0.00954659
0.0104862
0.0114724
0.0125058
0.013587
0.0147165
0.0158947
0.017122
0.0183985
0.0197245
0.0210998
0.0225245
0.0239981
0.0255204
0.0270909
0.0287085
0.0303725
0.0320818
0.033835
0.0356307
0.037467
0.0393421
0.0412536
0.043199
0.0451754
0.000238486
0.00035163
0.000541906
0.000730178
0.000962039
0.00128153
0.0016536
0.00207055
0.00253048
0.00303311
0.00357679
0.00416121
0.00478651
0.00545327
0.00616209
0.00691371
0.00770881
0.00854817
0.0094325
0.0103625
0.0113388
0.0123622
0.0134332
0.0145523
0.01572
0.0169366
0.0182025
0.0195177
0.0208824
0.0222964
0.0237597
0.0252717
0.0268319
0.0284397
0.0300942
0.0317944
0.0335389
0.0353262
0.0371549
0.0390228
0.0409283
0.042869
0.0448442
0.000238199
0.000352243
0.00054257
0.000728879
0.0009525
0.00126579
0.0016322
0.00204333
0.00249717
0.00299328
0.00353037
0.00410785
0.00472595
0.00538516
0.00608611
0.00682952
0.00761611
0.00844667
0.0093219
0.0102425
0.0112093
0.0122229
0.0132839
0.0143928
0.0155502
0.0167565
0.0180119
0.0193167
0.0206709
0.0220745
0.0235274
0.0250293
0.0265795
0.0281776
0.0298227
0.0315137
0.0332495
0.0350287
0.0368497
0.0387108
0.0406101
0.0425461
0.044518
0.000237879
0.000352729
0.000542998
0.000727371
0.000943572
0.00125069
0.00161159
0.00201709
0.00246498
0.00295477
0.00348542
0.00405621
0.0046673
0.00531917
0.00601247
0.0067479
0.00752622
0.00834819
0.00921458
0.0101261
0.0110836
0.0120876
0.0131388
0.0142379
0.0153852
0.0165813
0.0178265
0.019121
0.020465
0.0218584
0.0233011
0.0247929
0.0263333
0.0279218
0.0295575
0.0312396
0.0329668
0.0347378
0.0365512
0.0384053
0.0402983
0.0422284
0.0441935
0.000237539
0.000353104
0.000543236
0.000725797
0.0009356
0.00123626
0.00159174
0.00199176
0.00243387
0.0029175
0.00344188
0.00400616
0.00461044
0.0052552
0.00594105
0.00666873
0.00743901
0.00825263
0.00911041
0.0100131
0.0109615
0.0119562
0.0129979
0.0140873
0.0152248
0.0164109
0.0176461
0.0189305
0.0202644
0.0216478
0.0230805
0.0245625
0.0260932
0.0276721
0.0292986
0.0309717
0.0326904
0.0344534
0.0362591
0.0381062
0.0399926
0.0419164
0.043875
0.000237185
0.000353398
0.000543381
0.000724401
0.000929073
0.00122257
0.00157263
0.00196729
0.00240376
0.00288139
0.00339968
0.00395763
0.00455531
0.00519314
0.00587176
0.00659191
0.00735435
0.00815987
0.00900927
0.0099033
0.0108428
0.0118284
0.0128608
0.0139407
0.0150686
0.0162451
0.0174704
0.018745
0.020069
0.0214425
0.0228654
0.0243376
0.0258588
0.0274284
0.0290457
0.03071
0.0324202
0.034175
0.0359732
0.0378131
0.0396929
0.0416106
0.0435639
0.000236825
0.000353651
0.000543565
0.00072344
0.000924286
0.00120973
0.00155425
0.00194364
0.0023746
0.00284639
0.00335875
0.00391056
0.0045018
0.0051329
0.00580449
0.00651731
0.00727212
0.00806975
0.00891097
0.0097966
0.0107274
0.0117042
0.0127275
0.0137982
0.0149167
0.0160836
0.0172993
0.0185642
0.0198785
0.0212423
0.0226555
0.0241182
0.0256299
0.0271902
0.0287985
0.0304541
0.0321558
0.0339027
0.0356932
0.037526
0.0393993
0.0413113
0.0432611
0.00023646
0.000353916
0.000543896
0.000723048
0.000921093
0.00119777
0.0015366
0.00192077
0.00234635
0.00281244
0.00331903
0.00386486
0.00444984
0.00507439
0.00573915
0.00644483
0.00719222
0.00798215
0.00881541
0.00969284
0.0106152
0.0115833
0.0125978
0.0136594
0.0147687
0.0159263
0.0171326
0.018388
0.0196927
0.0210469
0.0224507
0.023904
0.0254064
0.0269575
0.0285569
0.0302038
0.0318972
0.0336361
0.0354191
0.0372447
0.0391112
0.0410165
0.0429573
0.00023611
0.000354232
0.00054445
0.000723201
0.000919037
0.00118663
0.00151967
0.00189867
0.00231901
0.00277961
0.00328049
0.00382048
0.00439937
0.00501755
0.00567564
0.00637437
0.00711453
0.00789695
0.00872246
0.00959187
0.010506
0.0114656
0.0124714
0.0135242
0.0146245
0.0157729
0.01697
0.0182161
0.0195114
0.0208563
0.0222508
0.0236947
0.025188
0.0267301
0.0283207
0.029959
0.0316441
0.0333751
0.0351506
0.0369692
0.0388292
0.0407286
0.0426643
0.000235779
0.000354615
0.000545219
0.000723755
0.000917632
0.0011762
0.00150343
0.00187733
0.00229256
0.00274784
0.00324309
0.00377736
0.00435031
0.00496229
0.00561389
0.00630585
0.00703897
0.00781406
0.00863198
0.00949357
0.0103996
0.011351
0.0123483
0.0133925
0.014484
0.0156234
0.0168115
0.0180484
0.0193346
0.0206703
0.0220555
0.0234903
0.0249746
0.0265078
0.0280897
0.0297195
0.0313965
0.0331196
0.0348878
0.0366996
0.0385538
0.0404495
0.0423883
0.000235473
0.00035506
0.000546155
0.000724536
0.00091651
0.00116636
0.00148782
0.00185673
0.00226695
0.00271702
0.00320677
0.00373545
0.00430261
0.00490854
0.00555381
0.00623917
0.00696541
0.00773337
0.00854391
0.00939785
0.010296
0.0112393
0.0122284
0.0132641
0.0143469
0.0154777
0.0166568
0.0178848
0.0191619
0.0204885
0.0218648
0.0232906
0.0247659
0.0262904
0.0278637
0.0294851
0.031154
0.0328695
0.0346304
0.0364356
0.038284
0.0401746
0.0421069
0.000235187
0.000355543
0.000547181
0.000725388
0.000915433
0.001157
0.00147282
0.0018368
0.00224214
0.00268711
0.00317148
0.0036947
0.00425621
0.00485623
0.00549534
0.00617427
0.00689381
0.00765482
0.00845814
0.00930463
0.0101951
0.0111305
0.0121115
0.0131388
0.0142132
0.0153354
0.0165058
0.017725
0.0189933
0.020311
0.0216783
0.0230953
0.0245618
0.0260777
0.0276425
0.0292557
0.0309167
0.0326245
0.0343782
0.0361767
0.0380189
0.0399033
0.0418273
0.00023491
0.000356035
0.000548215
0.000726194
0.000914277
0.00114806
0.00145835
0.00181752
0.00221807
0.00265806
0.00313716
0.00365505
0.00421104
0.00480531
0.00543841
0.00611105
0.00682406
0.00757826
0.00837453
0.00921374
0.0100967
0.0110243
0.0119974
0.0130166
0.0140828
0.0151965
0.0163584
0.0175689
0.0188285
0.0201375
0.0214961
0.0229044
0.0243623
0.0258696
0.027426
0.0290311
0.0306841
0.0323844
0.034131
0.0359227
0.0377585
0.0396371
0.0415576
0.000234636
0.000356508
0.000549198
0.000726881
0.00091298
0.00113951
0.00144439
0.00179884
0.00219471
0.00262982
0.00310377
0.00361645
0.00416706
0.00475571
0.00538294
0.00604946
0.00675607
0.00750363
0.00829302
0.0091251
0.0100007
0.0109208
0.0118861
0.0128974
0.0139554
0.0150609
0.0162144
0.0174165
0.0186675
0.0199679
0.0213179
0.0227176
0.024167
0.0256659
0.0272141
0.0288111
0.0304563
0.0321491
0.0338884
0.0356732
0.0375022
0.0393737
0.0412855
0.000234363
0.000356942
0.00055009
0.000727414
0.000911549
0.00113141
0.0014309
0.00178074
0.00217201
0.00260235
0.00307126
0.00357886
0.00412421
0.00470738
0.00532888
0.00598941
0.00668979
0.00743087
0.00821353
0.00903864
0.0099071
0.0108198
0.0117774
0.012781
0.0138311
0.0149285
0.0160738
0.0172675
0.0185102
0.0198021
0.0211436
0.0225349
0.0239759
0.0254665
0.0270066
0.0285956
0.030233
0.0319183
0.0336503
0.035428
0.0372499
0.0391134
0.0410126
0.000234085
0.000357327
0.000550873
0.000727799
0.000910048
0.00112394
0.00141792
0.00176317
0.00214996
0.00257564
0.00303966
0.00354224
0.00408245
0.00466026
0.00527617
0.00593087
0.00662515
0.00735991
0.00813597
0.00895428
0.0098157
0.0107211
0.0116714
0.0126673
0.0137096
0.014799
0.0159363
0.0171218
0.0183562
0.0196399
0.0209731
0.022356
0.0237888
0.0252712
0.0268032
0.0283843
0.0300141
0.0316918
0.0334166
0.0351874
0.0370029
0.0388619
0.0407654
0.000233801
0.000357655
0.000551546
0.000728077
0.000908611
0.00111737
0.00140547
0.00174615
0.00212854
0.00254968
0.00300897
0.00350658
0.00404173
0.00461431
0.00522475
0.00587373
0.00656208
0.00729064
0.00806028
0.00887193
0.00972647
0.0106248
0.0115678
0.0125562
0.0135909
0.0146725
0.0158018
0.0169794
0.0182057
0.0194812
0.0208062
0.022181
0.0236055
0.0250799
0.0266039
0.0281772
0.0297994
0.0314697
0.0331873
0.0349512
0.0367603
0.0386134
0.0405089
0.00023351
0.000357934
0.000552138
0.000728326
0.000907404
0.00111196
0.00139366
0.00172969
0.00210773
0.00252445
0.0029791
0.00347183
0.00400203
0.00456949
0.00517458
0.00581798
0.0065005
0.007223
0.00798636
0.0087915
0.00963931
0.0105307
0.0114665
0.0124476
0.0134748
0.0145488
0.0156703
0.01684
0.0180584
0.0193258
0.0206428
0.0220095
0.023426
0.0248925
0.0264086
0.0279742
0.0295887
0.0312516
0.0329621
0.0347192
0.0365216
0.0383681
0.0402563
0.000233214
0.000358179
0.000552693
0.000728636
0.000906575
0.0011078
0.00138253
0.0017138
0.00208754
0.00249991
0.00295002
0.00343796
0.00396331
0.00452574
0.00512561
0.00576357
0.00644039
0.00715694
0.00791414
0.0087129
0.00955412
0.0104387
0.0113675
0.0123415
0.0133613
0.0144278
0.0155417
0.0167036
0.0179142
0.0191738
0.0204828
0.0218415
0.0232502
0.0247087
0.0262171
0.027775
0.029382
0.0310376
0.0327409
0.034491
0.0362867
0.0381262
0.0400066
0.000232918
0.000358409
0.000553255
0.000729085
0.000906186
0.00110474
0.0013721
0.00169848
0.00206793
0.00247603
0.00292168
0.00340492
0.00392551
0.00448304
0.00507779
0.00571041
0.00638166
0.00709242
0.0078436
0.0086361
0.00947085
0.0103488
0.0112707
0.0122376
0.0132503
0.0143094
0.0154159
0.0165702
0.017773
0.0190248
0.0203261
0.021677
0.0230778
0.0245286
0.0260292
0.0275795
0.0291791
0.0308273
0.0325235
0.0342666
0.0360556
0.0378892
0.0397682
0.000232624
0.00035864
0.000553864
0.000729711
0.000906201
0.00110249
0.00136232
0.00168373
0.00204891
0.00245277
0.00289405
0.00337267
0.00388861
0.00444133
0.00503108
0.00565848
0.00632428
0.00702938
0.00777467
0.00856105
0.00938948
0.0102609
0.0111761
0.0121361
0.0131417
0.0141936
0.0152927
0.0164395
0.0176348
0.018879
0.0201725
0.0215157
0.0229088
0.0243519
0.0258449
0.0273877
0.0289798
0.0306208
0.0323097
0.0340457
0.0358273
0.0376522
0.0395143
0.000232335
0.000358887
0.000554544
0.000730507
0.000906517
0.00110075
0.00135312
0.00166951
0.00203043
0.00243013
0.0028671
0.0033412
0.00385257
0.00440058
0.00498543
0.00560771
0.00626819
0.00696773
0.00770724
0.00848764
0.00930987
0.0101748
0.0110835
0.0120367
0.0130353
0.0140802
0.015172
0.0163115
0.0174994
0.018736
0.020022
0.0213576
0.0227431
0.0241786
0.0256641
0.0271994
0.0287841
0.0304177
0.0320996
0.0338285
0.0356031
0.0374216
0.0392834
0.000232057
0.000359158
0.000555294
0.000731438
0.000907021
0.00109927
0.00134438
0.00165579
0.00201248
0.00240806
0.0028408
0.00331045
0.00381735
0.00436075
0.0049408
0.00555807
0.00621333
0.00690743
0.00764128
0.00841582
0.00923197
0.0100907
0.0109929
0.0119394
0.0129313
0.0139691
0.0150539
0.0161862
0.0173667
0.0185959
0.0198744
0.0212025
0.0225805
0.0240085
0.0254865
0.0270144
0.0285918
0.0302182
0.0318929
0.0336149
0.0353828
0.037195
0.0390491
0.000231788
0.000359446
0.000556099
0.000732447
0.0009076
0.00109789
0.00133605
0.00164252
0.00199503
0.00238657
0.00281516
0.0032805
0.00378295
0.00432182
0.00489717
0.00550954
0.00615968
0.00684844
0.00757675
0.00834553
0.00915573
0.0100083
0.0109041
0.0118442
0.0128293
0.0138604
0.0149381
0.0160633
0.0172366
0.0184586
0.0197297
0.0210504
0.022421
0.0238416
0.0253122
0.0268328
0.0284029
0.0300222
0.0316899
0.0334051
0.0351667
0.0369739
0.0388268
0.000231529
0.000359747
0.000556932
0.000733479
0.000908168
0.0010965
0.00132808
0.00162968
0.00197806
0.00236563
0.00279017
0.0032513
0.00374935
0.00428376
0.0048545
0.00546208
0.00610722
0.00679076
0.00751362
0.00827674
0.00908109
0.00992763
0.0108173
0.0117509
0.0127295
0.0137538
0.0148247
0.0159429
0.0171091
0.0183239
0.0195878
0.0209012
0.0222645
0.0236777
0.0251411
0.0266543
0.0282173
0.0298295
0.0314903
0.0331989
0.0349544
0.036756
0.0386032
0.000231276
0.000360048
0.000557766
0.00073449
0.000908672
0.00109506
0.00132047
0.00161724
0.00196157
0.00234523
0.0027658
0.00322281
0.00371651
0.00424653
0.00481275
0.00541562
0.00605584
0.00673428
0.00745182
0.00820943
0.00900805
0.00984865
0.0107322
0.0116595
0.0126316
0.0136494
0.0147135
0.0158249
0.0169841
0.0181918
0.0194485
0.0207548
0.0221108
0.0235168
0.0249729
0.026479
0.0280349
0.0296401
0.0312942
0.0329962
0.0347454
0.0365403
0.0383776
0.000231026
0.00036034
0.000558575
0.000735443
0.000909085
0.00109357
0.00131329
0.00160521
0.00194552
0.00232535
0.00274202
0.00319497
0.00368441
0.00421011
0.00477189
0.00537013
0.00600554
0.00667897
0.00739129
0.00814348
0.00893648
0.00977126
0.0106488
0.01157
0.0125357
0.013547
0.0146045
0.0157091
0.0168614
0.0180622
0.0193119
0.020611
0.0219599
0.0233588
0.0248078
0.0263068
0.0278557
0.029454
0.0311014
0.032797
0.0345401
0.0363301
0.0381679
0.000230779
0.000360613
0.000559338
0.000736319
0.000909408
0.00109208
0.00130667
0.0015936
0.00192991
0.00230597
0.00271881
0.00316777
0.00365301
0.00417449
0.0047319
0.00532561
0.00595631
0.00662479
0.00733199
0.00807886
0.00886635
0.00969542
0.010567
0.0114822
0.0124417
0.0134466
0.0144976
0.0155955
0.0167411
0.017935
0.0191777
0.0204699
0.0218117
0.0232036
0.0246455
0.0261375
0.0276795
0.029271
0.0309117
0.0326009
0.0343378
0.0361214
0.0379499
0.000230531
0.000360862
0.000560049
0.000737122
0.000909674
0.0010907
0.0013008
0.00158246
0.00191474
0.00228706
0.00269613
0.00314117
0.00362229
0.00413961
0.00469274
0.00528201
0.00590807
0.00657173
0.00727392
0.00801555
0.00879762
0.0096211
0.0104869
0.0113961
0.0123495
0.0133481
0.0143927
0.0154841
0.016623
0.0178101
0.0190461
0.0203313
0.0216662
0.0230511
0.024486
0.0259711
0.0275062
0.0290911
0.0307251
0.0324079
0.0341384
0.0359157
0.0377379
0.000230281
0.000361086
0.000560707
0.000737865
0.000909939
0.00108952
0.00129583
0.00157184
0.00190002
0.00226862
0.00267398
0.00311515
0.00359222
0.00410546
0.0046544
0.0052393
0.00586082
0.00651975
0.00721699
0.00795348
0.00873024
0.00954823
0.0104084
0.0113117
0.0122591
0.0132516
0.0142898
0.0153747
0.0165071
0.0176876
0.0189167
0.0201951
0.0215232
0.0229012
0.0243293
0.0258076
0.0273359
0.028914
0.0305416
0.0322179
0.0339421
0.035713
0.0375281
0.000230029
0.000361287
0.00056132
0.000738581
0.000910266
0.00108865
0.0012918
0.00156178
0.00188575
0.00225064
0.00265232
0.00308969
0.00356276
0.00407199
0.00461681
0.00519744
0.0058145
0.00646879
0.0071612
0.00789268
0.00866422
0.00947679
0.0103314
0.0112289
0.0121704
0.0131568
0.0141888
0.0152674
0.0163933
0.0175672
0.0187897
0.0200614
0.0213827
0.0227539
0.0241752
0.0256468
0.0271684
0.0287399
0.030361
0.032031
0.0337492
0.0355152
0.0373297
0.000229777
0.000361471
0.000561908
0.000739306
0.000910709
0.00108813
0.00128861
0.00155229
0.00187194
0.00223311
0.00263116
0.0030648
0.00353401
0.00403923
0.00457998
0.0051564
0.00576908
0.00641881
0.00710648
0.00783303
0.00859944
0.0094067
0.0102558
0.0111477
0.0120834
0.0130637
0.0140897
0.015162
0.0162815
0.017449
0.018665
0.01993
0.0212446
0.0226091
0.0240237
0.0254886
0.0270036
0.0285686
0.0301832
0.0318468
0.033559
0.0353188
0.0371249
0.000229525
0.000361644
0.000562489
0.000740066
0.000911292
0.00108792
0.00128608
0.00154334
0.00185859
0.00221604
0.00261049
0.00304048
0.00350589
0.00400717
0.0045439
0.00511619
0.00572457
0.00636981
0.00705281
0.00777451
0.00853589
0.00933793
0.0101816
0.011068
0.0119979
0.0129724
0.0139923
0.0150585
0.0161718
0.0173328
0.0185424
0.0198009
0.0211089
0.0224668
0.0238748
0.025333
0.0268414
0.0283999
0.030008
0.0316653
0.033371
0.0351238
0.0369215
0.000229275
0.000361814
0.000563079
0.000740885
0.000912021
0.00108799
0.00128402
0.00153487
0.00184568
0.0021994
0.00259031
0.00301669
0.00347837
0.00397574
0.00450854
0.00507677
0.00568091
0.00632175
0.00700018
0.0077171
0.00847353
0.00927046
0.0101089
0.0109898
0.0119141
0.0128828
0.0138968
0.0149569
0.016064
0.0172187
0.0184219
0.0196739
0.0209755
0.0223268
0.0237282
0.0251799
0.0266818
0.0282338
0.0298354
0.0314862
0.0331853
0.0349312
0.0367219
0.000229028
0.000361987
0.000563689
0.000741764
0.000912865
0.00108822
0.00128225
0.00152682
0.00183318
0.00218321
0.0025706
0.00299344
0.00345144
0.00394495
0.00447387
0.00503809
0.00563809
0.00627462
0.00694853
0.00766078
0.00841236
0.00920425
0.0100374
0.0109129
0.0118317
0.0127947
0.0138029
0.014857
0.015958
0.0171066
0.0183034
0.0195491
0.0208442
0.0221891
0.0235841
0.0250292
0.0265246
0.0280701
0.0296653
0.0313096
0.033002
0.034741
0.0365239
0.000228789
0.000362166
0.000564322
0.000742693
0.000913791
0.00108856
0.00128063
0.00151914
0.00182108
0.00216742
0.00255134
0.00297069
0.00342505
0.00391476
0.00443985
0.00500014
0.00559606
0.00622835
0.00689784
0.0076055
0.0083523
0.00913922
0.00996729
0.0108375
0.0117508
0.0127082
0.0137106
0.0147589
0.0158539
0.0169964
0.018187
0.0194264
0.0207152
0.0220537
0.0234422
0.0248809
0.0263699
0.0279089
0.0294977
0.0311355
0.0328215
0.0345541
0.0363304
0.000228552
0.000362351
0.000564975
0.000743658
0.000914758
0.00108893
0.00127908
0.0015118
0.00180934
0.00215204
0.00253252
0.00294841
0.00339922
0.00388517
0.00440648
0.0049629
0.00555481
0.00618293
0.00684808
0.00755121
0.00829331
0.00907536
0.00989839
0.0107634
0.0116714
0.0126232
0.01362
0.0146625
0.0157515
0.016888
0.0180725
0.0193057
0.0205882
0.0219204
0.0233025
0.0247349
0.0262175
0.0277501
0.0293326
0.0309642
0.0326444
0.0343728
0.0361518
0.000228319
0.000362542
0.000565639
0.000744634
0.000915726
0.00108928
0.00127754
0.00150478
0.00179795
0.00213703
0.00251412
0.0029266
0.00337388
0.00385617
0.00437376
0.00492637
0.00551434
0.00613833
0.00679921
0.0074979
0.00823537
0.00901263
0.00983069
0.0106906
0.0115933
0.0125397
0.0135309
0.0145677
0.0156509
0.0167814
0.0179599
0.019187
0.0204633
0.0217892
0.0231651
0.0245911
0.0260673
0.0275937
0.0291699
0.0307954
0.0324697
0.0341923
0.0359619
0.000228092
0.000362731
0.000566301
0.000745602
0.000916668
0.00108959
0.001276
0.00149815
0.00178691
0.0021224
0.00249612
0.00290525
0.00334905
0.00382769
0.00434165
0.00489052
0.00547461
0.00609458
0.00675123
0.00744553
0.00817847
0.00895103
0.00976423
0.0106191
0.0115165
0.0124577
0.0134433
0.0144745
0.015552
0.0166766
0.0178491
0.0190702
0.0203403
0.02166
0.0230297
0.0244495
0.0259195
0.0274396
0.0290095
0.0306289
0.032297
0.0340127
0.0357732
0.000227869
0.000362916
0.000566952
0.000746545
0.000917565
0.00108985
0.0012745
0.00149199
0.00177623
0.00210812
0.00247851
0.00288432
0.0033247
0.00379978
0.00431012
0.0048553
0.00543558
0.00605158
0.00670412
0.00739414
0.00812259
0.00889051
0.0096989
0.0105488
0.0114411
0.012377
0.0133572
0.0143828
0.0154547
0.0165735
0.0177401
0.0189552
0.0202193
0.0215329
0.0228964
0.02431
0.0257738
0.0272877
0.0288515
0.0304647
0.0321266
0.033836
0.0355913
0.000227647
0.000363092
0.000567582
0.00074745
0.000918414
0.00109007
0.0012731
0.0014864
0.00176594
0.00209419
0.00246128
0.00286381
0.00330084
0.00377244
0.00427918
0.00482072
0.00539724
0.00600933
0.00665782
0.00734361
0.00806767
0.00883101
0.00963467
0.0104797
0.011367
0.0122976
0.0132725
0.0142927
0.0153589
0.0164721
0.0176329
0.018842
0.0201002
0.0214077
0.0227651
0.0241726
0.0256302
0.027138
0.0286957
0.0303029
0.0319588
0.0336625
0.0354125
0.000227426
0.000363257
0.000568185
0.000748316
0.000919223
0.0010903
0.00127185
0.0014815
0.00175607
0.00208064
0.00244446
0.00284375
0.00327749
0.00374568
0.00424884
0.00478677
0.00535959
0.00596783
0.00661231
0.00729394
0.00801367
0.00877253
0.00957153
0.0104117
0.0112941
0.0122196
0.0131892
0.014204
0.0152647
0.0163722
0.0175273
0.0187307
0.0199829
0.0212845
0.0226358
0.0240372
0.0254888
0.0269906
0.0285423
0.0301437
0.0317942
0.0334929
0.0352379
0.000227206
0.000363411
0.00056876
0.000749145
0.000920009
0.00109058
0.00127084
0.00147733
0.00174667
0.00206747
0.00242799
0.00282409
0.00325458
0.00371941
0.00421904
0.00475342
0.00532258
0.00592705
0.0065676
0.00724511
0.00796059
0.00871504
0.00950945
0.0103449
0.0112223
0.0121428
0.0131073
0.0141168
0.015172
0.016274
0.0174234
0.018621
0.0198673
0.021163
0.0225084
0.0239039
0.0253495
0.0268454
0.0283914
0.0299874
0.0316335
0.0333306
0.0350835
0.000226987
0.000363551
0.00056931
0.00074995
0.0009208
0.00109095
0.00127011
0.00147386
0.00173774
0.00205468
0.0024119
0.00280486
0.00323213
0.00369363
0.00418979
0.00472067
0.00528623
0.00588697
0.00652363
0.00719713
0.00790843
0.00865852
0.00944842
0.0102792
0.0111518
0.0120673
0.0130267
0.0140309
0.0150808
0.0161773
0.0173211
0.018513
0.0197536
0.0210434
0.022383
0.0237725
0.0252123
0.0267024
0.0282429
0.0298339
0.0314756
0.0331693
0.0349175
0.000226765
0.000363682
0.000569838
0.000750742
0.000921618
0.00109143
0.00126965
0.00147099
0.00172928
0.00204229
0.0023962
0.002786
0.00321011
0.00366832
0.00416105
0.00468847
0.00525049
0.00584757
0.00648042
0.00714995
0.00785712
0.00860291
0.00938838
0.0102145
0.0110824
0.011993
0.0129474
0.0139464
0.014991
0.016082
0.0172203
0.0184066
0.0196415
0.0209256
0.0222594
0.0236432
0.0250772
0.0265617
0.0280967
0.0296825
0.0313191
0.0330064
0.034742
0.000226545
0.000363806
0.000570354
0.000751535
0.00092248
0.00109203
0.00126943
0.00146859
0.00172126
0.00203028
0.00238088
0.00276755
0.00318852
0.00364348
0.00413281
0.00465683
0.00521535
0.00580881
0.00643792
0.00710354
0.00780664
0.00854821
0.0093293
0.0101509
0.0110141
0.0119199
0.0128693
0.0138632
0.0149026
0.0159883
0.0171211
0.0183019
0.0195312
0.0208096
0.0221377
0.0235157
0.0249441
0.026423
0.0279526
0.0295329
0.0311638
0.0328447
0.0345734
0.00022633
0.000363925
0.000570869
0.000752342
0.000923393
0.00109275
0.00126941
0.00146652
0.00171363
0.00201863
0.0023659
0.00274947
0.00316733
0.0036191
0.00410508
0.00462573
0.00518082
0.0057707
0.00639611
0.00705788
0.00775697
0.00849439
0.00927116
0.0100883
0.0109469
0.0118479
0.0127924
0.0137813
0.0148155
0.015896
0.0170234
0.0181987
0.0194225
0.0206953
0.0220177
0.0233901
0.0248129
0.0262863
0.0278103
0.029385
0.03101
0.0326847
0.0344077
0.000226119
0.000364041
0.000571387
0.000753169
0.000924357
0.00109355
0.00126951
0.00146467
0.00170635
0.00200732
0.00235127
0.00273176
0.00314654
0.00359514
0.00407782
0.00459517
0.00514686
0.00573324
0.00635499
0.00701296
0.00770811
0.00844144
0.00921398
0.0100267
0.0108808
0.0117771
0.0127168
0.0137007
0.0147298
0.015805
0.0169272
0.0180971
0.0193153
0.0205826
0.0218995
0.0232664
0.0246836
0.0261514
0.0276698
0.0292387
0.0308577
0.0325255
0.03424
0.000225909
0.000364159
0.000571908
0.000754015
0.00092536
0.00109441
0.00126969
0.00146295
0.00169937
0.00199633
0.00233697
0.00271439
0.00312613
0.00357161
0.00405106
0.0045651
0.00511345
0.00569638
0.00631455
0.00696879
0.00766006
0.00838935
0.00915769
0.0099661
0.0108157
0.0117074
0.0126423
0.0136213
0.0146454
0.0157155
0.0168324
0.0179969
0.0192098
0.0204716
0.021783
0.0231443
0.024556
0.0260182
0.027531
0.0290942
0.030707
0.0323682
0.0340739
0.000225699
0.000364277
0.000572431
0.000754875
0.000926389
0.00109531
0.00126989
0.00146129
0.0016927
0.00198566
0.002323
0.00269737
0.0031061
0.0035485
0.0040248
0.00453555
0.00508058
0.0056601
0.00627474
0.00692531
0.00761275
0.00833805
0.00910226
0.00990641
0.0107515
0.0116387
0.0125689
0.013543
0.0145622
0.0156272
0.016739
0.0178983
0.0191058
0.0203622
0.0216682
0.023024
0.0244302
0.0258868
0.027394
0.0289516
0.030559
0.0322162
0.0339257
0.000225491
0.000364396
0.000572957
0.000755742
0.000927427
0.0010962
0.00127009
0.0014597
0.00168638
0.0019753
0.00230936
0.00268071
0.00308647
0.00352587
0.00399902
0.00450651
0.00504826
0.0056244
0.00623554
0.00688249
0.00756616
0.00828754
0.00904768
0.00984763
0.0106884
0.011571
0.0124966
0.013466
0.0144802
0.0155403
0.0166469
0.017801
0.0190033
0.0202544
0.0215549
0.0229054
0.024306
0.0257572
0.0272589
0.028811
0.0304131
0.0320643
0.0337602
0.000225286
0.000364516
0.000573483
0.000756606
0.000928456
0.00109708
0.00127028
0.00145815
0.00168041
0.00196523
0.00229601
0.00266437
0.0030672
0.00350362
0.00397368
0.00447795
0.00501646
0.00558928
0.00619698
0.00684034
0.00752029
0.00823783
0.00899395
0.00978973
0.0106262
0.0115044
0.0124254
0.0133901
0.0143995
0.0154546
0.0165562
0.0177052
0.0189022
0.0201481
0.0214433
0.0227883
0.0241836
0.0256293
0.0271257
0.0286727
0.0302704
0.0319198
0.0336266
0.000225086
0.000364637
0.000574009
0.00075746
0.000929468
0.00109793
0.00127045
0.00145667
0.00167487
0.00195549
0.00228297
0.00264837
0.0030483
0.00348176
0.00394878
0.00444987
0.00498517
0.00555472
0.00615901
0.00679885
0.00747513
0.00818886
0.00894104
0.00973271
0.0105649
0.0114388
0.0123552
0.0133153
0.01432
0.0153702
0.0164668
0.0176107
0.0188026
0.0200432
0.0213331
0.0226728
0.0240628
0.0255032
0.0269944
0.0285363
0.0301295
0.0317746
0.033473
0.00022489
0.000364753
0.000574525
0.000758298
0.000930454
0.00109876
0.00127063
0.00145531
0.00166985
0.00194611
0.00227025
0.00263268
0.00302974
0.00346028
0.00392429
0.00442223
0.00495437
0.00552068
0.00612164
0.00675801
0.00743068
0.00814064
0.00888891
0.00967654
0.0105046
0.0113741
0.0122861
0.0132416
0.0142416
0.0152869
0.0163787
0.0175175
0.0187043
0.0199398
0.0212245
0.022559
0.0239436
0.0253788
0.0268647
0.0284015
0.029989
0.0316266
0.0333102
0.000224696
0.000364862
0.000575028
0.000759115
0.000931413
0.00109957
0.00127083
0.00145413
0.00166541
0.0019371
0.00225785
0.00261731
0.0030115
0.00343916
0.0039002
0.00439503
0.00492405
0.00548716
0.00608482
0.00671776
0.00738687
0.00809313
0.00883755
0.00962121
0.0104451
0.0113104
0.012218
0.0131689
0.0141643
0.0152049
0.0162918
0.0174257
0.0186075
0.0198378
0.0211173
0.0224466
0.023826
0.025256
0.0267366
0.0282678
0.0298492
0.0314793
0.0331541
0.000224502
0.000364964
0.000575513
0.000759909
0.000932349
0.00110037
0.00127109
0.00145315
0.00166157
0.0019285
0.00224578
0.00260226
0.00299363
0.00341844
0.00387652
0.00436828
0.00489421
0.00545415
0.00604855
0.00667811
0.00734371
0.00804631
0.00878694
0.00956667
0.0103865
0.0112475
0.0121508
0.0130973
0.014088
0.015124
0.0162061
0.0173351
0.0185119
0.0197372
0.0210116
0.0223357
0.0237099
0.0251346
0.0266098
0.0281355
0.0297109
0.0313348
0.0330049
0.000224306
0.00036506
0.000575979
0.000760681
0.000933273
0.00110119
0.00127144
0.0014524
0.00165827
0.00192031
0.00223404
0.00258752
0.00297606
0.00339806
0.00385323
0.00434194
0.00486481
0.00542166
0.00601284
0.00663905
0.00730118
0.0080002
0.00873711
0.00951294
0.0103288
0.0111856
0.0120846
0.0130267
0.0140129
0.0150443
0.0161216
0.0172458
0.0184176
0.0196379
0.0209073
0.0222263
0.0235953
0.0250147
0.0264846
0.0280048
0.029575
0.0311948
0.0328658
0.000224113
0.00036515
0.000576432
0.000761437
0.000934191
0.00110204
0.00127188
0.00145188
0.00165544
0.0019125
0.00222262
0.00257311
0.00295883
0.00337801
0.0038303
0.00431604
0.00483589
0.00538966
0.00597767
0.0066006
0.00725931
0.00795476
0.00868797
0.00945997
0.0102718
0.0111246
0.0120194
0.0129571
0.0139389
0.0149656
0.0160382
0.0171576
0.0183246
0.01954
0.0208043
0.0221182
0.0234821
0.0248963
0.0263609
0.0278758
0.0294409
0.031056
0.0327208
0.000223919
0.000365235
0.000576872
0.000762183
0.000935114
0.00110293
0.00127244
0.00145156
0.001653
0.00190507
0.00221153
0.00255899
0.0029419
0.0033583
0.00380776
0.00429058
0.0048074
0.00535812
0.005943
0.00656269
0.00721803
0.00790997
0.00863953
0.00940776
0.0102157
0.0110645
0.011955
0.0128885
0.0138658
0.014888
0.015956
0.0170707
0.0182329
0.0194433
0.0207027
0.0220115
0.0233703
0.0247793
0.0262387
0.0277485
0.0293085
0.0309184
0.0325775
0.000223729
0.000365318
0.000577307
0.000762924
0.00093605
0.00110387
0.00127308
0.00145141
0.00165085
0.00189796
0.00220076
0.00254518
0.00292531
0.00333894
0.0037856
0.00426553
0.00477935
0.00532705
0.00590883
0.00652531
0.00717732
0.0078658
0.00859177
0.00935628
0.0101604
0.0110051
0.0118916
0.0128208
0.0137938
0.0148115
0.0158749
0.0169849
0.0181423
0.0193479
0.0206023
0.0219062
0.0232599
0.0246638
0.0261181
0.0276227
0.0291777
0.0307826
0.0324372
0.000223544
0.000365396
0.000577741
0.000763669
0.000937007
0.00110486
0.00127381
0.00145137
0.00164891
0.00189118
0.00219028
0.00253166
0.00290901
0.00331994
0.00376382
0.00424089
0.00475174
0.00529643
0.00587515
0.00648847
0.00713719
0.00782228
0.00854469
0.00930552
0.0101058
0.0109466
0.011829
0.012754
0.0137227
0.014736
0.0157949
0.0169003
0.018053
0.0192537
0.0205033
0.0218021
0.0231508
0.0245497
0.0259989
0.0274985
0.0290485
0.0306485
0.0322978
0.000223357
0.00036547
0.000578167
0.000764417
0.000937977
0.00110588
0.00127459
0.0014514
0.00164709
0.00188468
0.00218008
0.00251844
0.00289302
0.00330125
0.00374241
0.00421666
0.00472456
0.0052663
0.00584198
0.00645215
0.00709763
0.00777935
0.00849829
0.00925547
0.010052
0.0108889
0.0117673
0.0126882
0.0136526
0.0146615
0.0157159
0.0168167
0.0179647
0.0191607
0.0204054
0.0216994
0.0230431
0.024437
0.0258812
0.0273758
0.0289209
0.0305166
0.032164
0.000223183
0.000365546
0.000578597
0.00076517
0.00093896
0.00110692
0.00127539
0.00145147
0.00164537
0.00187845
0.00217014
0.00250549
0.00287732
0.00328286
0.00372132
0.00419277
0.00469776
0.00523658
0.00580929
0.0064164
0.00705866
0.00773702
0.00845253
0.00920612
0.00999891
0.010832
0.0117064
0.0126232
0.0135834
0.014588
0.015638
0.0167342
0.0178776
0.0190689
0.0203088
0.0215979
0.0229368
0.0243257
0.0257649
0.0272546
0.0287947
0.0303846
0.0320218
0.000223009
0.000365618
0.000579031
0.000765933
0.000939968
0.00110798
0.00127622
0.00145156
0.00164372
0.00187254
0.0021605
0.00249281
0.0028619
0.00326479
0.00370056
0.00416925
0.00467136
0.0052073
0.00577703
0.00638107
0.0070202
0.0076953
0.00840735
0.0091574
0.00994657
0.0107758
0.0116463
0.0125591
0.0135151
0.0145154
0.0155611
0.0166528
0.0177916
0.0189783
0.0202134
0.0214977
0.0228316
0.0242157
0.02565
0.0271348
0.02867
0.0302559
0.0318946
0.000222803
0.000365694
0.000579447
0.000766683
0.000940949
0.00110902
0.00127703
0.00145167
0.00164216
0.00186696
0.00215114
0.00248042
0.00284679
0.00324705
0.00368016
0.00414611
0.00464536
0.00517841
0.00574522
0.00634628
0.00698228
0.00765411
0.00836279
0.00910938
0.00989493
0.0107204
0.011587
0.0124958
0.0134477
0.0144438
0.0154851
0.0165724
0.0177067
0.0188887
0.0201192
0.0213987
0.0227279
0.024107
0.0255364
0.0270163
0.0285464
0.0301262
0.0317522
0.000222609
0.00036578
0.000579844
0.000767409
0.00094193
0.00111007
0.00127785
0.00145176
0.00164067
0.00186175
0.00214206
0.00246827
0.00283194
0.00322959
0.00366006
0.0041233
0.0046197
0.00514996
0.00571389
0.00631195
0.00694483
0.00761351
0.00831887
0.00906201
0.0098439
0.0106658
0.0115286
0.0124334
0.0133812
0.0143732
0.0154101
0.0164931
0.0176229
0.0188004
0.0200261
0.0213009
0.0226253
0.0239996
0.0254242
0.0268992
0.0284246
0.0300002
0.0316268
0.000222438
0.000365852
0.000580264
0.00076816
0.000942909
0.0011111
0.00127864
0.00145187
0.00163929
0.00185698
0.00213326
0.00245642
0.00281735
0.00321242
0.00364026
0.00410079
0.00459446
0.00512188
0.00568297
0.00627809
0.00690797
0.00757347
0.00827555
0.00901524
0.00979363
0.0106118
0.0114708
0.0123717
0.0133156
0.0143033
0.0153361
0.0164147
0.0175401
0.0187129
0.0199342
0.0212043
0.022524
0.0238936
0.0253133
0.0267836
0.0283046
0.0298763
0.0315003
0.000222288
0.000365922
0.000580693
0.000768897
0.000943869
0.00111211
0.00127944
0.00145203
0.00163806
0.00185268
0.00212482
0.00244482
0.00280305
0.00319548
0.00362077
0.00407867
0.00456959
0.00509423
0.0056525
0.00624471
0.00687158
0.00753392
0.00823274
0.0089691
0.00974401
0.0105586
0.0114138
0.0123109
0.0132507
0.0142344
0.015263
0.0163373
0.0174582
0.0186267
0.0198434
0.0211088
0.0224239
0.0237887
0.0252039
0.0266696
0.028186
0.0297536
0.0313725
0.000222103
0.000365985
0.000581104
0.000769623
0.000944826
0.00111312
0.00128024
0.00145224
0.00163703
0.00184887
0.00211673
0.00243352
0.00278901
0.00317887
0.00360159
0.00405688
0.0045451
0.00506696
0.0056224
0.00621173
0.00683563
0.0074949
0.00819055
0.00892354
0.00969503
0.010506
0.0113576
0.0122508
0.0131867
0.0141664
0.0151908
0.0162608
0.0173775
0.0185415
0.0197536
0.0210146
0.0223249
0.0236852
0.0250958
0.0265569
0.0280689
0.0296315
0.0312428
0.000221912
0.000366054
0.000581474
0.000770308
0.000945743
0.0011141
0.00128104
0.00145252
0.0016362
0.00184553
0.00210898
0.00242248
0.00277524
0.00316256
0.00358273
0.00403545
0.00452101
0.00504007
0.00559272
0.00617923
0.00680018
0.0074564
0.00814886
0.00887861
0.00964669
0.0104541
0.011302
0.0121915
0.0131235
0.0140992
0.0151195
0.0161853
0.0172977
0.0184573
0.019665
0.0209214
0.0222273
0.0235829
0.024989
0.0264458
0.0279537
0.0295139
0.0311304
0.000221743
0.00036611
0.000581857
0.000770995
0.000946653
0.00111509
0.00128188
0.00145289
0.00163555
0.00184259
0.00210156
0.00241177
0.00276175
0.00314651
0.00356418
0.00401431
0.00449723
0.00501357
0.00556347
0.00614716
0.00676516
0.00741842
0.00810776
0.00883426
0.00959889
0.0104029
0.0112472
0.0121329
0.0130611
0.0140328
0.015049
0.0161107
0.0172188
0.0183741
0.0195774
0.0208294
0.0221307
0.0234819
0.0248836
0.026336
0.0278395
0.0293944
0.030998
0.000221599
0.000366162
0.000582249
0.000771688
0.000947566
0.00111609
0.00128276
0.00145334
0.00163506
0.00184001
0.00209445
0.00240132
0.0027485
0.0031307
0.00354587
0.0039935
0.00447383
0.00498743
0.00553463
0.00611552
0.00673068
0.0073809
0.00806718
0.00879044
0.00955178
0.0103523
0.011193
0.0120751
0.0129995
0.0139673
0.0149795
0.0160371
0.0171409
0.0182919
0.0194908
0.0207385
0.0220354
0.0233822
0.0247794
0.0262275
0.0277269
0.0292776
0.0308795
0.000221441
0.000366221
0.000582636
0.000772368
0.000948486
0.00111711
0.00128369
0.00145389
0.00163474
0.00183771
0.00208768
0.00239114
0.00273553
0.00311518
0.00352787
0.00397299
0.00445072
0.00496165
0.00550616
0.00608426
0.00669659
0.0073439
0.00802707
0.0087472
0.00950526
0.0103023
0.0111395
0.0120179
0.0129386
0.0139025
0.0149108
0.0159643
0.0170639
0.0182107
0.0194054
0.0206486
0.0219411
0.0232836
0.0246765
0.0261205
0.0276162
0.0291648
0.030771
0.000221235
0.000366274
0.000582979
0.000773027
0.00094939
0.00111812
0.00128464
0.00145452
0.00163456
0.00183564
0.00208121
0.00238125
0.00272284
0.00309996
0.00351018
0.0039528
0.00442797
0.00493622
0.005478
0.00605343
0.00666294
0.00730732
0.00798751
0.00870446
0.0094593
0.010253
0.0110867
0.0119615
0.0128784
0.0138386
0.0148429
0.0158923
0.0169879
0.0181305
0.0193209
0.0205598
0.0218481
0.0231862
0.0245749
0.0260148
0.0275062
0.02905
0.0306449
0.000221062
0.000366321
0.0005833
0.000773659
0.000950277
0.00111916
0.00128564
0.00145519
0.00163445
0.00183372
0.00207499
0.00237158
0.00271039
0.00308498
0.00349274
0.00393289
0.00440552
0.00491111
0.00545027
0.00602299
0.00662973
0.00727124
0.00794842
0.00866229
0.00941392
0.0102043
0.0110346
0.0119058
0.0128191
0.0137754
0.0147758
0.0158213
0.0169128
0.0180513
0.0192374
0.0204721
0.0217561
0.02309
0.0244745
0.02591
0.0273968
0.0289345
0.0305197
0.000220923
0.000366373
0.000583668
0.000774329
0.000951194
0.00112022
0.00128666
0.00145591
0.0016344
0.0018319
0.00206902
0.0023622
0.0026982
0.00307025
0.00347558
0.00391326
0.00438336
0.00488634
0.0054229
0.00599294
0.0065969
0.0072356
0.00790985
0.00862066
0.00936904
0.0101562
0.010983
0.0118507
0.0127603
0.0137129
0.0147095
0.0157511
0.0168386
0.0179729
0.0191549
0.0203855
0.0216652
0.0229949
0.024375
0.0258061
0.0272885
0.0288221
0.0304083
0.000220774
0.000366412
0.000584021
0.000774988
0.000952109
0.00112129
0.00128771
0.00145667
0.00163437
0.00183019
0.00206332
0.00235305
0.00268622
0.00305574
0.00345863
0.00389391
0.00436151
0.00486193
0.00539589
0.00596329
0.00656456
0.00720039
0.00787174
0.0085795
0.00932476
0.0101086
0.0109321
0.0117963
0.0127023
0.0136512
0.014644
0.0156817
0.0167651
0.0178955
0.0190734
0.0202998
0.0215754
0.0229008
0.0242767
0.0257034
0.0271813
0.0287104
0.0302902
0.000220605
0.00036646
0.000584375
0.000775644
0.000953037
0.00112237
0.00128877
0.00145742
0.00163438
0.00182856
0.00205791
0.00234413
0.00267448
0.00304148
0.00344198
0.00387483
0.00433998
0.00483787
0.0053692
0.00593397
0.00653256
0.00716564
0.00783406
0.00853883
0.00928103
0.0100616
0.0108818
0.0117425
0.012645
0.0135902
0.0145793
0.0156131
0.0166927
0.017819
0.0189928
0.0202151
0.0214865
0.0228077
0.0241793
0.0256017
0.0270751
0.0285995
0.0301742
0.000220437
0.000366501
0.000584718
0.000776289
0.000953939
0.00112343
0.00128981
0.00145819
0.00163442
0.00182703
0.00205284
0.00233549
0.002663
0.0030275
0.00342559
0.00385606
0.00431877
0.00481413
0.00534287
0.00590506
0.00650098
0.00713128
0.00779685
0.00849869
0.00923781
0.0100152
0.0108321
0.0116894
0.0125884
0.01353
0.0145153
0.0155453
0.016621
0.0177434
0.0189132
0.0201313
0.0213986
0.0227156
0.024083
0.025501
0.02697
0.0284901
0.0300611
0.000220283
0.000366559
0.000585041
0.000776916
0.000954846
0.0011245
0.00129087
0.00145894
0.00163447
0.00182558
0.0020481
0.00232709
0.00265174
0.00301374
0.00340944
0.00383755
0.00429783
0.00479074
0.00531691
0.0058765
0.00646974
0.00709737
0.00776012
0.00845903
0.00919504
0.00996935
0.010783
0.011637
0.0125324
0.0134704
0.0144521
0.0154783
0.0165502
0.0176686
0.0188344
0.0200485
0.0213117
0.0226245
0.0239876
0.0254013
0.0268659
0.0283813
0.0299467
0.000220115
0.000366594
0.000585362
0.000777567
0.000955751
0.00112555
0.0012919
0.0014597
0.00163455
0.00182426
0.00204373
0.00231899
0.00264072
0.00300021
0.00339354
0.00381928
0.00427722
0.00476764
0.00529128
0.0058483
0.00643897
0.00706388
0.00772384
0.00841982
0.00915286
0.00992406
0.0107344
0.0115851
0.0124771
0.0134115
0.0143896
0.0154121
0.0164801
0.0175946
0.0187565
0.0199666
0.0212257
0.0225344
0.0238932
0.0253026
0.0267628
0.0282738
0.0298364
0.000219963
0.000366646
0.000585707
0.000778201
0.000956641
0.0011266
0.00129293
0.00146047
0.00163466
0.0018231
0.00203979
0.00231116
0.00262996
0.00298688
0.00337787
0.0038013
0.00425686
0.00474488
0.00526598
0.00582046
0.00640854
0.00703075
0.00768794
0.0083811
0.00911117
0.00987925
0.0106864
0.0115338
0.0124224
0.0133534
0.0143278
0.0153467
0.0164108
0.0175215
0.0186795
0.0198856
0.0211406
0.0224451
0.0237997
0.0252047
0.0266604
0.0281663
0.0297204
0.000219795
0.000366688
0.00058604
0.000778831
0.000957536
0.00112764
0.00129397
0.00146126
0.00163486
0.0018221
0.00203626
0.00230367
0.00261945
0.00297384
0.00336246
0.00378358
0.00423679
0.0047224
0.00524097
0.00579293
0.00637845
0.00699802
0.00765251
0.00834279
0.00906996
0.00983499
0.010639
0.0114831
0.0123684
0.0132959
0.0142667
0.0152819
0.0163424
0.0174493
0.0186033
0.0198055
0.0210564
0.0223568
0.0237071
0.0251079
0.0265592
0.0280613
0.0296159
0.000219645
0.000366723
0.00058635
0.000779429
0.000958395
0.00112867
0.00129499
0.00146205
0.00163513
0.00182128
0.0020331
0.00229644
0.00260918
0.00296104
0.0033473
0.00376612
0.00421701
0.00470018
0.00521628
0.00576577
0.00634874
0.00696569
0.00761746
0.00830497
0.00902923
0.00979119
0.0105921
0.011433
0.0123149
0.013239
0.0142063
0.0152179
0.0162747
0.0173778
0.018528
0.0197261
0.0209731
0.0222693
0.0236155
0.0250119
0.0264587
0.0279554
0.0294994
0.000219517
0.000366759
0.000586686
0.000780055
0.000959261
0.00112969
0.00129602
0.00146289
0.00163548
0.00182061
0.00203028
0.00228955
0.00259919
0.00294847
0.00333239
0.00374889
0.00419747
0.0046783
0.00519191
0.00573893
0.00631935
0.00693377
0.00758286
0.0082676
0.00898892
0.00974799
0.0105458
0.0113835
0.0122621
0.0131828
0.0141466
0.0151546
0.0162078
0.0173071
0.0184534
0.0196477
0.0208906
0.0221827
0.0235247
0.0249169
0.0263593
0.0278522
0.029396
0.000219375
0.000366784
0.000586995
0.000780658
0.000960111
0.0011307
0.00129705
0.00146376
0.00163588
0.0018201
0.00202775
0.00228293
0.00258942
0.0029361
0.00331766
0.00373191
0.00417821
0.00465666
0.00516786
0.00571242
0.00629038
0.00690219
0.00754866
0.00823062
0.00894912
0.00970522
0.0105
0.0113345
0.0122099
0.0131272
0.0140876
0.015092
0.0161415
0.0172371
0.0183796
0.01957
0.0208089
0.0220971
0.023435
0.024823
0.0262617
0.0277513
0.0292933
0.000219219
0.00036682
0.000587302
0.000781248
0.000960966
0.00113172
0.00129812
0.00146467
0.00163638
0.00181972
0.00202547
0.00227656
0.0025799
0.00292397
0.00330319
0.00371516
0.00415917
0.0046353
0.00514408
0.00568619
0.0062617
0.006871
0.00751481
0.0081941
0.00890979
0.00966295
0.0104547
0.0112861
0.0121582
0.0130723
0.0140292
0.0150301
0.016076
0.0171679
0.0183067
0.0194932
0.0207281
0.0220123
0.0233462
0.0247304
0.0261656
0.0276527
0.0291945
0.000219063
0.000366848
0.000587599
0.000781827
0.000961803
0.00113273
0.00129918
0.00146563
0.00163695
0.00181945
0.00202339
0.00227048
0.00257063
0.0029121
0.00328896
0.00369867
0.00414041
0.00461423
0.00512058
0.00566031
0.00623336
0.00684013
0.00748138
0.00815795
0.00887088
0.00962116
0.0104099
0.0112382
0.0121072
0.0130179
0.0139714
0.0149689
0.0160112
0.0170995
0.0182345
0.0194171
0.0206483
0.0219285
0.0232585
0.024639
0.0260706
0.0275543
0.0290912
0.000218921
0.000366891
0.000587871
0.000782386
0.000962622
0.00113375
0.00130027
0.0014666
0.00163757
0.00181926
0.00202145
0.00226461
0.00256158
0.00290044
0.00327494
0.00368241
0.00412191
0.00459343
0.00509745
0.00563475
0.00620536
0.00680966
0.00744832
0.00812224
0.00883242
0.00957981
0.0103656
0.0111909
0.0120567
0.0129641
0.0139143
0.0149083
0.0159471
0.0170317
0.018163
0.0193419
0.0205692
0.0218456
0.0231718
0.0245485
0.0259764
0.0274558
0.0289854
0.000218765
0.000366911
0.000588145
0.00078296
0.000963458
0.00113478
0.00130137
0.0014676
0.00163822
0.00181912
0.00201962
0.00225901
0.00255277
0.00288899
0.00326116
0.00366636
0.00410364
0.00457289
0.00507461
0.0056095
0.00617767
0.00677953
0.00741566
0.00808695
0.00879434
0.00953899
0.0103218
0.011144
0.0120067
0.012911
0.0138578
0.0148484
0.0158837
0.0169647
0.0180923
0.0192675
0.020491
0.0217636
0.0230861
0.0244591
0.0258834
0.0273596
0.028889
0.000218621
0.000366933
0.000588429
0.000783526
0.000964285
0.0011358
0.00130248
0.00146863
0.00163889
0.00181904
0.00201789
0.00225364
0.00254415
0.00287773
0.00324754
0.00365055
0.00408561
0.00455265
0.00505207
0.00558456
0.00615036
0.00674972
0.00738336
0.00805202
0.00875674
0.00949856
0.0102785
0.0110977
0.0119573
0.0128583
0.0138019
0.0147891
0.0158209
0.0168983
0.0180224
0.0191938
0.0204137
0.0216826
0.0230014
0.0243709
0.0257919
0.0272659
0.0287959
0.00021849
0.000366965
0.000588733
0.000784095
0.000965128
0.00113684
0.0013036
0.00146967
0.0016396
0.00181897
0.00201626
0.00224853
0.00253576
0.00286669
0.00323418
0.00363496
0.00406784
0.00453266
0.00502976
0.00555988
0.00612331
0.00672028
0.00735138
0.00801747
0.00871956
0.00945859
0.0102357
0.0110519
0.0119084
0.0128063
0.0137467
0.0147304
0.0157588
0.0168327
0.0179532
0.019121
0.0203371
0.0216024
0.0229176
0.0242837
0.0257014
0.0271719
0.0286961
0.000218342
0.000366986
0.000589021
0.000784654
0.000965944
0.00113786
0.00130471
0.00147072
0.00164032
0.00181895
0.00201473
0.00224372
0.00252761
0.00285589
0.00322103
0.00361962
0.00405032
0.0045129
0.00500774
0.00553552
0.00609659
0.00669114
0.00731977
0.00798334
0.00868278
0.00941902
0.0101933
0.0110066
0.0118601
0.0127548
0.0136919
0.0146724
0.0156974
0.0167678
0.0178847
0.019049
0.0202615
0.0215231
0.0228348
0.0241973
0.0256114
0.0270778
0.0285961
0.000218207
0.000367023
0.000589284
0.000785194
0.000966766
0.00113889
0.00130584
0.00147175
0.00164104
0.00181894
0.00201329
0.0022392
0.0025197
0.0028453
0.00320811
0.0036045
0.004033
0.00449342
0.00498601
0.00551145
0.00607014
0.00666235
0.00728855
0.00794959
0.00864633
0.00937994
0.0101514
0.0109618
0.0118123
0.0127039
0.0136378
0.014615
0.0156366
0.0167036
0.017817
0.0189777
0.0201867
0.0214447
0.0227528
0.0241116
0.0255218
0.0269836
0.0284961
0.000218057
0.000367037
0.000589542
0.000785759
0.000967587
0.00113991
0.00130695
0.00147279
0.00164175
0.00181898
0.00201196
0.00223503
0.00251203
0.00283491
0.00319536
0.00358954
0.00401594
0.00447416
0.00496455
0.00548766
0.00604406
0.0066339
0.00725767
0.00791617
0.00861036
0.00934129
0.0101099
0.0109174
0.0117649
0.0126535
0.0135842
0.0145582
0.0155764
0.01664
0.01775
0.0189072
0.0201126
0.0213671
0.0226715
0.0240265
0.0254327
0.0268899
0.0283974
0.000217923
0.000367071
0.000589826
0.000786309
0.000968398
0.00114092
0.00130806
0.00147383
0.00164248
0.00181906
0.00201077
0.00223118
0.00250463
0.00282471
0.00318282
0.00357483
0.00399908
0.00445516
0.00494333
0.00546414
0.00601825
0.00660572
0.00722708
0.00788315
0.00857478
0.00930301
0.0100689
0.0108736
0.0117181
0.0126036
0.0135312
0.014502
0.0155169
0.0165772
0.0176837
0.0188374
0.0200393
0.0212902
0.022591
0.0239423
0.0253446
0.026798
0.0283025
0.000217773
0.000367095
0.0005901
0.000786857
0.000969216
0.00114194
0.00130917
0.00147488
0.00164324
0.0018192
0.00200975
0.00222771
0.00249749
0.00281478
0.0031705
0.00356034
0.00398246
0.00443639
0.00492233
0.00544086
0.0059927
0.00657785
0.00719686
0.00785044
0.00853955
0.00926514
0.0100283
0.0108301
0.0116718
0.0125543
0.0134788
0.0144463
0.015458
0.016515
0.017618
0.0187683
0.0199667
0.0212141
0.0225113
0.0238589
0.0252576
0.0267081
0.0282125
0.000217641
0.000367114
0.000590352
0.000787375
0.000970003
0.00114294
0.00131026
0.00147591
0.00164402
0.00181942
0.00200885
0.00222454
0.00249062
0.00280507
0.0031584
0.00354605
0.00396605
0.00441783
0.00490158
0.00541787
0.00596745
0.00655032
0.00716695
0.00781811
0.00850471
0.00922767
0.00998818
0.0107872
0.0116259
0.0125055
0.0134269
0.0143913
0.0153998
0.0164534
0.0175531
0.0186999
0.0198949
0.0211387
0.0224323
0.0237763
0.0251715
0.0266184
0.0281176
0.000217531
0.000367134
0.000590634
0.000787925
0.000970798
0.00114393
0.00131135
0.00147696
0.00164483
0.00181969
0.00200811
0.00222171
0.00248403
0.00279559
0.00314652
0.00353196
0.00394984
0.00439953
0.00488112
0.00539518
0.00594245
0.00652308
0.00713739
0.00778615
0.00847019
0.00919064
0.00994842
0.0107447
0.0115806
0.0124571
0.0133755
0.0143368
0.0153421
0.0163924
0.0174888
0.0186323
0.0198237
0.0210641
0.0223541
0.0236945
0.0250858
0.0265285
0.0280218
0.000217406
0.000367143
0.00059089
0.000788454
0.000971578
0.00114491
0.00131243
0.00147801
0.00164566
0.00182004
0.00200749
0.00221913
0.00247767
0.0027863
0.0031348
0.00351807
0.00393386
0.00438143
0.00486091
0.00537277
0.00591781
0.00649612
0.00710814
0.00775448
0.00843608
0.00915395
0.00990911
0.0107026
0.0115357
0.0124093
0.0133247
0.0142829
0.015285
0.016332
0.0174252
0.0185653
0.0197533
0.0209902
0.0222766
0.0236133
0.0250009
0.0264393
0.0279284
0.000217268
0.000367165
0.000591147
0.000788972
0.000972362
0.00114589
0.00131353
0.00147908
0.00164653
0.00182046
0.00200702
0.00221676
0.00247156
0.00277723
0.00312331
0.00350438
0.00391807
0.00436358
0.00484095
0.00535061
0.00589341
0.00646948
0.00707916
0.00772318
0.00840234
0.00911766
0.00987017
0.010661
0.0114912
0.012362
0.0132744
0.0142295
0.0152284
0.0162723
0.0173622
0.0184989
0.0196835
0.0209169
0.0221998
0.0235329
0.0249166
0.0263513
0.0278371
0.00021713
0.00036718
0.000591395
0.000789479
0.000973127
0.00114685
0.00131462
0.00148018
0.00164746
0.00182095
0.00200665
0.00221461
0.0024657
0.00276842
0.00311204
0.00349092
0.00390252
0.00434595
0.00482117
0.00532872
0.00586928
0.0064431
0.00705052
0.00769216
0.00836893
0.00908174
0.00983165
0.0106198
0.0114472
0.0123151
0.0132246
0.0141766
0.0151725
0.0162132
0.0172998
0.0184332
0.0196144
0.0208443
0.0221237
0.0234531
0.0248332
0.0262643
0.027747
0.000217006
0.00036721
0.000591617
0.000789966
0.000973871
0.00114783
0.00131572
0.00148128
0.0016484
0.00182148
0.00200636
0.00221259
0.00246006
0.00275979
0.00310095
0.00347764
0.00388717
0.00432853
0.00480169
0.00530708
0.00584542
0.00641703
0.00702218
0.00766151
0.00833588
0.00904617
0.00979357
0.010579
0.0114037
0.0122688
0.0131753
0.0141244
0.0151172
0.0161547
0.017238
0.0183681
0.0195459
0.0207724
0.0220482
0.0233741
0.0247505
0.0261779
0.0276567
0.000216866
0.000367215
0.000591841
0.000790468
0.000974629
0.00114879
0.00131681
0.00148239
0.00164937
0.00182205
0.00200613
0.00221072
0.00245465
0.00275137
0.00309007
0.00346456
0.00387201
0.00431133
0.00478243
0.00528571
0.00582183
0.00639125
0.00699415
0.00763119
0.00830312
0.00901103
0.00975582
0.0105387
0.0113606
0.0122229
0.0131265
0.0140726
0.0150623
0.0160967
0.0171768
0.0183037
0.0194781
0.0207012
0.0219734
0.0232957
0.0246684
0.0260916
0.0275645
0.000216742
0.00036724
0.000592089
0.00079096
0.000975376
0.00114976
0.00131792
0.00148353
0.00165035
0.00182267
0.00200595
0.00220895
0.00244944
0.00274313
0.00307935
0.00345167
0.00385705
0.00429436
0.00476341
0.00526456
0.00579851
0.00636571
0.00696641
0.00760114
0.00827074
0.00897619
0.00971846
0.0104987
0.011318
0.0121774
0.0130782
0.0140214
0.015008
0.0160393
0.0171162
0.0182398
0.019411
0.0206306
0.0218994
0.0232181
0.0245873
0.0260073
0.0274794
0.000216626
0.00036725
0.000592337
0.000791456
0.000976137
0.00115073
0.00131904
0.00148467
0.00165136
0.00182331
0.00200583
0.00220728
0.00244448
0.00273511
0.00306884
0.00343897
0.0038423
0.00427759
0.00474457
0.00524363
0.00577541
0.00634047
0.00693893
0.0075714
0.0082387
0.00894172
0.00968149
0.0104591
0.0112757
0.0121324
0.0130304
0.0139706
0.0149543
0.0159825
0.0170562
0.0181766
0.0193444
0.0205607
0.0218261
0.0231415
0.0245074
0.0259246
0.0273921
0.000216496
0.000367254
0.000592571
0.000791937
0.000976868
0.00115169
0.00132014
0.00148582
0.00165239
0.00182397
0.00200574
0.00220569
0.00243976
0.0027273
0.00305854
0.00342648
0.00382776
0.00426101
0.00472597
0.00522295
0.00575258
0.00631546
0.00691174
0.00754199
0.00820698
0.00890756
0.00964491
0.01042
0.0112339
0.0120879
0.012983
0.0139203
0.014901
0.0159262
0.0169968
0.0181139
0.0192786
0.0204915
0.0217537
0.0230661
0.02443
0.0258481
0.027329
0.000216378
0.00036728
0.000592802
0.000792426
0.000977616
0.00115265
0.00132126
0.00148696
0.00165342
0.00182463
0.00200568
0.00220421
0.00243532
0.0027197
0.00304843
0.00341418
0.00381338
0.00424465
0.00470759
0.0052025
0.00572996
0.00629074
0.00688487
0.0075129
0.00817554
0.00887382
0.0096087
0.0103812
0.0111926
0.0120438
0.0129361
0.0138706
0.0148483
0.0158704
0.0169379
0.0180519
0.0192133
0.0204231
0.0216823
0.0229919
0.0243536
0.02577
0.0272447
0.000216244
0.000367279
0.000593001
0.000792901
0.000978347
0.00115361
0.00132236
0.00148811
0.00165445
0.00182532
0.00200564
0.00220283
0.00243113
0.00271231
0.00303848
0.00340202
0.00379922
0.00422848
0.00468944
0.00518228
0.00570764
0.00626629
0.00685827
0.00748406
0.00814445
0.0088404
0.00957281
0.0103428
0.0111516
0.0120001
0.0128897
0.0138213
0.0147961
0.0158152
0.0168797
0.0179905
0.0191488
0.0203555
0.0216115
0.0229183
0.0242768
0.025688
0.0271487
0.000216126
0.000367301
0.000593235
0.000793375
0.000979087
0.00115457
0.00132347
0.00148926
0.00165547
0.00182601
0.00200566
0.00220156
0.00242725
0.00270512
0.00302874
0.00339007
0.00378522
0.00421251
0.00467148
0.00516229
0.00568556
0.00624206
0.00683189
0.00745554
0.00811369
0.00880727
0.00953729
0.0103048
0.011111
0.0119569
0.0128437
0.0137725
0.0147444
0.0157605
0.016822
0.0179297
0.0190849
0.0202885
0.0215415
0.022845
0.0241997
0.0256055
0.0270597
0.000215992
0.000367314
0.000593462
0.000793848
0.00097982
0.00115552
0.00132457
0.00149041
0.00165652
0.00182673
0.00200574
0.00220043
0.00242367
0.00269822
0.00301921
0.00337833
0.00377143
0.00419674
0.0046537
0.0051425
0.00566371
0.0062181
0.00680582
0.00742727
0.00808322
0.00877449
0.00950212
0.0102672
0.0110708
0.0119141
0.0127982
0.0137241
0.0146932
0.0157064
0.0167648
0.0178696
0.0190216
0.0202221
0.0214719
0.022772
0.0241228
0.025524
0.0269744
0.000215876
0.000367322
0.000593669
0.000794298
0.000980528
0.00115646
0.00132566
0.00149154
0.00165756
0.00182747
0.00200587
0.00219941
0.00242038
0.00269154
0.00300987
0.00336675
0.00375782
0.00418114
0.00463614
0.00512297
0.00564213
0.00619441
0.00678001
0.00739932
0.00805305
0.00874201
0.00946733
0.01023
0.011031
0.0118717
0.012753
0.0136763
0.0146425
0.0156528
0.0167082
0.0178099
0.018959
0.0201562
0.0214028
0.0226994
0.0240462
0.0254433
0.0268902
0.000215783
0.000367332
0.000593907
0.000794781
0.000981249
0.0011574
0.00132675
0.00149268
0.00165861
0.00182822
0.00200605
0.00219855
0.00241739
0.00268509
0.00300074
0.00335536
0.00374438
0.00416577
0.00461881
0.00510365
0.00562075
0.00617097
0.00675448
0.00737166
0.00802314
0.00870991
0.00943282
0.0101931
0.0109916
0.0118297
0.0127084
0.0136289
0.0145923
0.0155996
0.0166521
0.0177509
0.0188968
0.020091
0.0213342
0.0226272
0.0239701
0.0253631
0.0268057
0.000215674
0.000367331
0.000594122
0.000795246
0.000981958
0.00115833
0.00132784
0.00149382
0.00165965
0.00182902
0.0020063
0.0021978
0.00241464
0.00267886
0.00299178
0.00334415
0.00373114
0.00415056
0.0046017
0.00508457
0.00559968
0.00614776
0.0067292
0.00734423
0.00799357
0.00867806
0.00939869
0.0101565
0.0109526
0.0117881
0.0126641
0.0135819
0.0145425
0.015547
0.0165966
0.0176923
0.0188352
0.0200262
0.021266
0.0225553
0.0238945
0.025283
0.0267201
0.000215552
0.000367343
0.000594338
0.0007957
0.000982672
0.00115926
0.00132892
0.00149496
0.00166072
0.00182983
0.00200662
0.00219717
0.00241213
0.00267286
0.00298304
0.00333313
0.00371807
0.00413555
0.00458477
0.00506566
0.00557878
0.00612482
0.00670415
0.00731711
0.00796429
0.00864655
0.00936486
0.0101203
0.0109139
0.0117469
0.0126204
0.0135354
0.0144932
0.0154949
0.0165416
0.0176343
0.0187741
0.0199618
0.0211983
0.0224841
0.0238194
0.0252042
0.0266383
0.00021543
0.000367349
0.000594546
0.000796145
0.000983368
0.00116016
0.00132998
0.0014961
0.00166181
0.0018307
0.00200701
0.00219667
0.00240983
0.00266711
0.00297451
0.0033223
0.00370519
0.00412073
0.00456799
0.00504699
0.00555812
0.00610208
0.00667938
0.00729022
0.00793529
0.00861533
0.00933135
0.0100844
0.0108756
0.0117061
0.0125769
0.0134893
0.0144444
0.0154433
0.0164871
0.0175768
0.0187135
0.019898
0.0211311
0.0224134
0.0237452
0.025127
0.0265602
0.000215322
0.000367371
0.00059473
0.000796571
0.000984041
0.00116107
0.00133106
0.00149724
0.00166291
0.00183158
0.00200745
0.00219624
0.00240769
0.00266156
0.00296617
0.00331165
0.0036925
0.00410609
0.00455146
0.00502852
0.00553767
0.00607959
0.00665484
0.00726363
0.00790657
0.0085844
0.00929821
0.0100489
0.0108377
0.0116657
0.0125339
0.0134437
0.014396
0.0153921
0.016433
0.0175197
0.0186533
0.0198347
0.0210645
0.0223434
0.0236718
0.0250501
0.026478
0.000215198
0.000367368
0.000594916
0.000797013
0.000984728
0.00116198
0.00133212
0.00149839
0.00166403
0.00183249
0.00200794
0.00219591
0.0024057
0.00265621
0.00295802
0.00330118
0.00367997
0.00409163
0.00453512
0.00501028
0.00551743
0.00605735
0.00663057
0.0072373
0.00787808
0.00855382
0.00926534
0.0100138
0.0108001
0.0116256
0.0124913
0.0133985
0.0143481
0.0153414
0.0163794
0.0174632
0.0185937
0.0197719
0.0209984
0.022274
0.0235992
0.0249746
0.0264018
0.00021509
0.000367385
0.000595127
0.000797444
0.000985403
0.00116287
0.0013332
0.00149955
0.00166514
0.00183344
0.00200846
0.00219563
0.00240382
0.00265105
0.00295002
0.00329088
0.00366761
0.00407736
0.00451896
0.0049922
0.00549743
0.00603529
0.00660652
0.00721122
0.00784993
0.00852348
0.00923278
0.0099789
0.0107629
0.0115859
0.0124491
0.0133537
0.0143005
0.0152911
0.0163263
0.0174071
0.0185346
0.0197096
0.0209329
0.0222053
0.0235275
0.0249006
0.0263268
0.000214989
0.000367388
0.000595338
0.000797879
0.000986091
0.00116378
0.00133427
0.00150071
0.00166629
0.00183441
0.00200904
0.00219542
0.00240206
0.00264611
0.00294223
0.00328075
0.00365543
0.00406326
0.00450296
0.00497429
0.0054776
0.00601348
0.00658269
0.00718535
0.00782203
0.00849344
0.00920054
0.00994438
0.010726
0.0115467
0.0124074
0.0133092
0.0142535
0.0152413
0.0162736
0.0173515
0.0184759
0.0196479
0.020868
0.0221373
0.0234563
0.0248258
0.0262455
0.000214875
0.000367385
0.000595536
0.000798299
0.000986749
0.00116467
0.00133534
0.00150188
0.00166745
0.0018354
0.00200963
0.00219524
0.0024004
0.00264139
0.00293464
0.00327081
0.00364344
0.00404932
0.00448715
0.00495661
0.00545799
0.00599187
0.00655909
0.00715977
0.00779439
0.00846365
0.00916861
0.0099102
0.0106895
0.0115077
0.0123659
0.0132652
0.0142069
0.0151919
0.0162214
0.0172963
0.0184178
0.0195866
0.0208037
0.0220698
0.0233855
0.0247512
0.0261654
0.000214773
0.000367404
0.00059573
0.000798727
0.000987421
0.00116556
0.00133641
0.00150304
0.00166861
0.00183639
0.00201024
0.00219511
0.00239884
0.00263688
0.00292724
0.00326105
0.0036316
0.00403559
0.00447153
0.00493912
0.00543856
0.00597052
0.00653577
0.00713445
0.00776698
0.00843421
0.009137
0.00987635
0.0106534
0.0114691
0.0123248
0.0132216
0.0141606
0.0151429
0.0161695
0.0172417
0.0183602
0.019526
0.02074
0.022003
0.0233158
0.0246796
0.0260981
0.000214654
0.000367394
0.000595892
0.000799141
0.000988078
0.00116645
0.00133746
0.00150421
0.00166977
0.0018374
0.00201086
0.00219501
0.00239735
0.00263261
0.00292
0.00325142
0.00361994
0.004022
0.00445611
0.00492183
0.0054194
0.00594942
0.00651267
0.00710934
0.00773987
0.00840503
0.00910563
0.00984276
0.0106175
0.0114309
0.0122842
0.0131784
0.0141148
0.0150943
0.0161182
0.0171875
0.018303
0.0194659
0.0206768
0.0219368
0.0232467
0.0246074
0.0260192
0.000214551
0.00036741
0.000596088
0.000799553
0.000988743
0.00116734
0.00133853
0.00150538
0.00167092
0.00183841
0.00201151
0.00219495
0.00239597
0.00262855
0.00291295
0.00324199
0.00360843
0.00400859
0.00444085
0.00490473
0.00540043
0.0059285
0.00648977
0.00708449
0.00771302
0.00837608
0.00907456
0.00980949
0.0105819
0.011393
0.0122439
0.0131356
0.0140693
0.0150462
0.0160674
0.0171337
0.0182464
0.0194063
0.0206142
0.0218712
0.0231781
0.0245358
0.0259455
0.000214454
0.000367409
0.000596292
0.00079997
0.000989403
0.00116822
0.0013396
0.00150655
0.0016721
0.00183944
0.00201218
0.00219494
0.0023947
0.00262479
0.00290614
0.00323275
0.0035971
0.00399534
0.00442574
0.00488779
0.00538164
0.00590781
0.00646713
0.00705985
0.00768641
0.00834741
0.00904378
0.00977653
0.0105467
0.0113555
0.0122039
0.0130931
0.0140243
0.0149985
0.0160169
0.0170805
0.0181902
0.0193472
0.0205522
0.0218061
0.0231097
0.0244633
0.0258661
0.000214354
0.00036742
0.000596465
0.000800365
0.000990043
0.00116909
0.00134065
0.00150771
0.00167328
0.00184047
0.00201287
0.00219496
0.00239354
0.00262128
0.00289952
0.00322367
0.00358594
0.00398227
0.00441084
0.00487106
0.00536306
0.00588735
0.0064447
0.00703548
0.00766005
0.008319
0.00901332
0.0097439
0.0105118
0.0113182
0.0121642
0.013051
0.0139796
0.0149512
0.0159669
0.0170276
0.0181346
0.0192885
0.0204905
0.0217413
0.0230414
0.0243907
0.0257877
0.000214239
0.000367412
0.000596633
0.000800778
0.000990689
0.00116996
0.0013417
0.00150887
0.00167444
0.00184149
0.00201357
0.00219506
0.00239251
0.00261803
0.00289312
0.00321477
0.00357493
0.00396937
0.0043961
0.00485452
0.00534466
0.00586709
0.00642251
0.00701135
0.0076339
0.0082909
0.00898308
0.00971155
0.0104773
0.0112814
0.012125
0.0130092
0.0139353
0.0149043
0.0159172
0.0169753
0.0180793
0.0192304
0.0204293
0.0216769
0.0229734
0.0243191
0.0257125
0.000214138
0.00036741
0.000596812
0.000801181
0.000991327
0.00117082
0.00134275
0.00151003
0.00167559
0.00184254
0.00201429
0.0021952
0.00239158
0.00261502
0.0028869
0.00320605
0.0035641
0.00395661
0.00438155
0.00483816
0.0053265
0.00584702
0.00640052
0.00698742
0.00760803
0.008263
0.00895316
0.00967945
0.010443
0.0112447
0.012086
0.0129679
0.0138914
0.0148578
0.0158681
0.0169233
0.0180245
0.0191727
0.0203686
0.021613
0.0229067
0.0242505
0.0256485
0.000214049
0.00036742
0.000597012
0.000801585
0.000991977
0.0011717
0.0013438
0.00151119
0.00167677
0.00184359
0.00201506
0.0021954
0.00239077
0.00261225
0.00288091
0.00319751
0.00355343
0.00394404
0.00436716
0.00482195
0.00530848
0.00582717
0.00637872
0.00696374
0.00758241
0.00823538
0.00892346
0.00964764
0.010409
0.0112085
0.0120475
0.0129269
0.0138479
0.0148117
0.0158193
0.0168718
0.0179702
0.0191154
0.0203084
0.0215498
0.0228405
0.0241813
0.0255728
0.000213944
0.00036742
0.000597199
0.000801982
0.00099261
0.00117254
0.00134483
0.00151235
0.00167795
0.00184466
0.00201585
0.00219566
0.00239008
0.00260971
0.00287515
0.00318917
0.00354294
0.00393163
0.00435289
0.00480593
0.00529066
0.00580749
0.00635715
0.00694023
0.00755701
0.008208
0.00889405
0.00961613
0.0103753
0.0111726
0.0120092
0.0128862
0.0138048
0.014766
0.0157709
0.0168207
0.0179163
0.0190586
0.0202487
0.0214871
0.0227746
0.0241115
0.0254963
0.000213852
0.000367436
0.000597357
0.000802359
0.000993221
0.00117339
0.00134587
0.00151349
0.00167913
0.00184574
0.00201667
0.00219597
0.0023895
0.00260737
0.00286959
0.00318101
0.00353262
0.00391937
0.00433884
0.00479009
0.00527302
0.00578803
0.00633579
0.006917
0.00753185
0.00818086
0.00886493
0.00958493
0.0103419
0.011137
0.0119712
0.0128459
0.013762
0.0147207
0.0157229
0.01677
0.0178628
0.0190023
0.0201894
0.0214248
0.0227092
0.0240434
0.0254291
0.000213743
0.000367428
0.000597512
0.000802751
0.000993844
0.00117423
0.00134688
0.00151463
0.0016803
0.00184682
0.00201751
0.00219636
0.00238901
0.00260518
0.00286421
0.003173
0.00352244
0.00390728
0.00432496
0.00477445
0.00525557
0.00576876
0.00631463
0.00689397
0.00750687
0.008154
0.00883603
0.00955396
0.0103088
0.0111017
0.0119336
0.0128059
0.0137195
0.0146756
0.0156754
0.0167198
0.0178098
0.0189465
0.0201305
0.0213629
0.0226442
0.0239749
0.0253549
0.00021365
0.000367441
0.000597695
0.000803135
0.00099447
0.00117508
0.00134791
0.00151578
0.00168147
0.00184794
0.00201838
0.00219678
0.00238859
0.00260313
0.002859
0.00316517
0.00351244
0.00389536
0.00431123
0.00475894
0.0052383
0.00574964
0.00629367
0.00687113
0.00748218
0.00812734
0.00880738
0.00952326
0.010276
0.0110666
0.0118964
0.0127663
0.0136774
0.014631
0.0156282
0.0166699
0.0177572
0.018891
0.0200721
0.0213015
0.0225795
0.0239063
0.0252807
0.000213565
0.00036744
0.000597877
0.00080352
0.000995088
0.00117592
0.00134893
0.00151693
0.00168267
0.00184906
0.0020193
0.00219726
0.00238825
0.00260122
0.002854
0.00315753
0.00350261
0.00388359
0.00429764
0.00474357
0.00522118
0.00573075
0.00627289
0.00684849
0.00745768
0.00810092
0.00877899
0.00949283
0.0102434
0.0110319
0.0118594
0.0127269
0.0136357
0.0145868
0.0155814
0.0166204
0.0177049
0.0188359
0.0200142
0.0212405
0.0225154
0.0238395
0.025214
0.000213465
0.000367433
0.000598047
0.000803892
0.000995681
0.00117674
0.00134995
0.00151808
0.00168388
0.00185021
0.00202024
0.00219777
0.00238797
0.00259943
0.00284919
0.00315004
0.00349293
0.00387196
0.00428421
0.00472841
0.00520426
0.00571204
0.00625236
0.00682609
0.00743342
0.00807473
0.00875088
0.0094627
0.0102112
0.0109976
0.0118227
0.0126879
0.0135943
0.014543
0.015535
0.0165713
0.0176532
0.0187813
0.0199567
0.02118
0.0224519
0.0237732
0.0251448
0.000213378
0.000367449
0.000598214
0.000804271
0.000996289
0.00117756
0.00135096
0.00151922
0.00168508
0.00185135
0.00202119
0.0021983
0.00238775
0.00259774
0.00284458
0.00314274
0.0034834
0.00386052
0.00427096
0.0047134
0.00518748
0.00569351
0.00623205
0.00680392
0.00740933
0.0080488
0.008723
0.00943281
0.0101793
0.0109634
0.0117864
0.0126493
0.0135533
0.0144994
0.0154889
0.0165227
0.0176018
0.0187271
0.0198996
0.0211199
0.0223889
0.023707
0.0250744
0.000213274
0.000367436
0.000598348
0.000804636
0.000996882
0.00117838
0.00135197
0.00152037
0.00168628
0.00185252
0.00202215
0.00219887
0.00238756
0.00259613
0.00284014
0.00313557
0.00347404
0.0038492
0.00425787
0.00469857
0.00517093
0.0056752
0.00621192
0.00678192
0.0073855
0.00802309
0.00869532
0.00940314
0.0101475
0.0109295
0.0117503
0.012611
0.0135126
0.0144563
0.0154432
0.0164744
0.0175507
0.0186733
0.0198429
0.0210604
0.0223263
0.0236411
0.025005
0.000213186
0.000367448
0.000598517
0.000804999
0.000997484
0.0011792
0.00135298
0.00152152
0.00168748
0.00185368
0.00202314
0.00219945
0.00238741
0.0025946
0.0028359
0.00312859
0.00346481
0.00383805
0.00424492
0.00468389
0.00515454
0.00565703
0.00619196
0.00676015
0.00736189
0.00799758
0.0086679
0.00937373
0.0101161
0.010896
0.0117146
0.0125729
0.0134721
0.0144135
0.0153979
0.0164264
0.0175001
0.0186199
0.0197867
0.0210012
0.0222642
0.0235761
0.0249377
0.000213104
0.000367443
0.000598695
0.000805367
0.00099808
0.00118002
0.00135399
0.00152267
0.00168871
0.00185486
0.00202414
0.00220007
0.00238731
0.00259319
0.00283189
0.0031218
0.00345577
0.00382705
0.00423211
0.00466935
0.00513829
0.00563905
0.00617222
0.00673854
0.00733848
0.0079723
0.00864071
0.00934458
0.0100849
0.0108627
0.0116791
0.0125352
0.0134321
0.014371
0.0153529
0.0163789
0.0174499
0.0185669
0.019731
0.0209426
0.0222027
0.0235121
0.0248721
0.000213019
0.000367451
0.000598841
0.000805714
0.000998656
0.00118082
0.00135499
0.00152381
0.00168993
0.00185605
0.00202515
0.00220069
0.00238725
0.00259187
0.00282809
0.00311518
0.00344688
0.0038162
0.00421947
0.00465499
0.00512222
0.00562127
0.00615266
0.00671717
0.00731528
0.00794723
0.00861379
0.00931571
0.010054
0.0108297
0.0116439
0.0124978
0.0133924
0.0143289
0.0153083
0.0163317
0.0174001
0.0185144
0.0196756
0.0208845
0.0221418
0.0234484
0.0248049
0.000212917
0.000367438
0.000598982
0.000806081
0.00099924
0.00118163
0.00135598
0.00152495
0.00169114
0.00185722
0.00202615
0.00220134
0.00238723
0.00259065
0.00282453
0.00310874
0.00343813
0.00380551
0.00420698
0.0046408
0.00510632
0.00560367
0.0061333
0.006696
0.00729225
0.00792243
0.00858705
0.00928706
0.0100234
0.010797
0.011609
0.0124607
0.013353
0.014287
0.015264
0.0162848
0.0173506
0.0184623
0.0196208
0.0208269
0.0220814
0.0233851
0.0247378
0.000212833
0.000367448
0.000599149
0.000806436
0.000999817
0.00118242
0.00135699
0.0015261
0.00169234
0.00185841
0.00202717
0.00220201
0.00238725
0.00258951
0.00282117
0.00310248
0.00342957
0.00379495
0.00419465
0.00462675
0.00509059
0.0055862
0.00611411
0.00667498
0.00726946
0.00789779
0.00856058
0.00925862
0.00999292
0.0107645
0.0115744
0.0124239
0.0133138
0.0142455
0.01522
0.0162384
0.0173016
0.0184106
0.0195664
0.0207698
0.022022
0.0233242
0.0246802
0.000212757
0.000367447
0.000599315
0.000806795
0.00100041
0.00118323
0.00135798
0.00152724
0.00169355
0.00185959
0.00202821
0.0022027
0.00238733
0.00258849
0.00281806
0.00309642
0.00342114
0.00378456
0.00418247
0.00461283
0.005075
0.00556893
0.00609507
0.00665419
0.00724687
0.00787338
0.00853429
0.00923043
0.00996275
0.0107323
0.0115401
0.0123873
0.0132751
0.0142044
0.0151765
0.0161923
0.0172529
0.0183594
0.0195125
0.0207135
0.0219632
0.023263
0.0246135
0.000212667
0.00036744
0.000599472
0.000807144
0.00100098
0.00118402
0.00135896
0.00152838
0.00169477
0.00186079
0.00202925
0.00220342
0.00238746
0.0025876
0.00281517
0.00309055
0.0034129
0.00377431
0.00417039
0.00459909
0.00505957
0.0055518
0.00607624
0.00663353
0.00722447
0.00784917
0.00850825
0.00920249
0.00993283
0.0107004
0.0115061
0.0123511
0.0132366
0.0141636
0.0151333
0.0161466
0.0172047
0.0183085
0.0194592
0.0206576
0.0219051
0.023203
0.0245539
0.000212589
0.000367455
0.000599623
0.000807502
0.00100154
0.00118481
0.00135995
0.0015295
0.00169598
0.00186198
0.0020303
0.00220416
0.00238765
0.0025868
0.0028125
0.00308489
0.00340483
0.00376422
0.00415851
0.0045855
0.00504431
0.00553486
0.00605758
0.00661311
0.00720228
0.00782516
0.00848244
0.0091748
0.0099032
0.0106687
0.0114723
0.0123151
0.0131984
0.0141231
0.0150903
0.0161013
0.0171569
0.0182582
0.0194063
0.0206023
0.0218473
0.0231424
0.024488
0.000212495
0.000367441
0.000599744
0.000807837
0.00100211
0.00118559
0.00136092
0.00153062
0.00169719
0.00186317
0.00203136
0.00220493
0.00238789
0.0025861
0.00281
0.00307938
0.0033969
0.00375427
0.00414678
0.00457208
0.00502919
0.00551809
0.00603908
0.00659286
0.00718021
0.00780139
0.0084568
0.00914728
0.00987374
0.0106372
0.0114388
0.0122795
0.0131605
0.0140829
0.0150478
0.0160563
0.0171094
0.0182083
0.0193539
0.0205474
0.0217897
0.0230815
0.0244214
0.000212416
0.000367453
0.000599903
0.000808175
0.00100267
0.00118638
0.0013619
0.00153175
0.00169838
0.00186437
0.00203243
0.00220573
0.00238817
0.00258547
0.00280768
0.00307406
0.00338914
0.00374448
0.00413519
0.00455877
0.00501425
0.00550144
0.00602076
0.00657279
0.00715841
0.00777778
0.00843138
0.00912001
0.00984458
0.010606
0.0114056
0.0122441
0.0131229
0.014043
0.0150056
0.0160117
0.0170624
0.0181588
0.019302
0.020493
0.0217331
0.0230237
0.0243692
0.000212345
0.000367452
0.000600061
0.000808516
0.00100324
0.00118716
0.00136287
0.00153287
0.0016996
0.00186558
0.00203354
0.00220656
0.00238852
0.00258497
0.00280553
0.00306894
0.00338155
0.00373484
0.00412371
0.00454559
0.00499943
0.00548499
0.00600259
0.0065529
0.00713678
0.00775437
0.00840618
0.00909296
0.0098156
0.0105751
0.0113726
0.012209
0.0130856
0.0140035
0.0149638
0.0159675
0.0170158
0.0181098
0.0192505
0.0204392
0.021677
0.0229655
0.024306
0.00021226
0.000367447
0.000600214
0.00080885
0.00100378
0.00118792
0.00136384
0.00153399
0.00170081
0.0018668
0.00203465
0.00220742
0.00238891
0.00258454
0.00280352
0.00306398
0.00337412
0.00372535
0.0041124
0.00453259
0.00498477
0.00546868
0.00598461
0.00653322
0.00711534
0.00773116
0.00838122
0.00906616
0.0097869
0.0105445
0.0113398
0.0121742
0.0130487
0.0139643
0.0149223
0.0159236
0.0169696
0.0180611
0.0191995
0.0203859
0.0216213
0.0229066
0.0242394
0.00021217
0.000367447
0.000600334
0.000809178
0.00100433
0.00118868
0.00136479
0.00153509
0.00170201
0.001868
0.00203577
0.0022083
0.00238936
0.00258417
0.00280163
0.00305921
0.00336683
0.00371601
0.00410123
0.00451973
0.00497023
0.00545253
0.00596682
0.00651374
0.00709406
0.00770818
0.00835645
0.00903957
0.00975843
0.010514
0.0113074
0.0121397
0.013012
0.0139254
0.0148811
0.0158802
0.0169238
0.018013
0.0191491
0.0203333
0.0215672
0.0228534
0.024201
0.000212078
0.000367436
0.000600451
0.000809501
0.00100486
0.00118944
0.00136575
0.00153621
0.00170321
0.00186924
0.0020369
0.00220922
0.00238982
0.00258386
0.00279984
0.00305457
0.00335971
0.00370679
0.00409022
0.00450702
0.00495591
0.00543656
0.0059492
0.0064944
0.007073
0.00768538
0.00833185
0.00901315
0.00973014
0.0104838
0.0112752
0.0121054
0.0129756
0.0138868
0.0148403
0.0158371
0.0168784
0.0179653
0.0190992
0.0202814
0.0215136
0.0227982
0.0241369
0.000212022
0.000367452
0.000600618
0.000809832
0.00100541
0.0011902
0.0013667
0.00153732
0.00170441
0.00187046
0.00203805
0.00221014
0.00239033
0.00258358
0.00279815
0.00305012
0.00335272
0.00369773
0.00407933
0.00449445
0.00494171
0.00542072
0.0059317
0.00647526
0.00705213
0.00766275
0.00830746
0.00898696
0.0097021
0.0104539
0.0112433
0.0120715
0.0129395
0.0138486
0.0147998
0.0157943
0.0168334
0.0179181
0.0190498
0.0202299
0.0214599
0.0227413
0.0240733
0.000211958
0.000367446
0.000600785
0.000810167
0.00100596
0.00119096
0.00136765
0.00153843
0.00170564
0.00187171
0.00203923
0.0022111
0.00239087
0.00258339
0.00279657
0.00304586
0.00334591
0.00368882
0.00406857
0.00448199
0.00492763
0.00540503
0.0059144
0.00645626
0.00703143
0.00764032
0.00828328
0.00896099
0.00967428
0.0104242
0.0112116
0.0120377
0.0129037
0.0138106
0.0147597
0.015752
0.0167888
0.0178713
0.0190008
0.0201786
0.021406
0.0226831
0.0240075
0.000211887
0.000367454
0.000600913
0.000810479
0.00100648
0.0011917
0.00136859
0.00153953
0.00170685
0.00187295
0.0020404
0.00221206
0.00239143
0.00258323
0.00279506
0.00304177
0.00333925
0.00368004
0.00405796
0.0044697
0.00491371
0.00538952
0.00589726
0.00643747
0.00701091
0.00761806
0.00825933
0.00893526
0.00964672
0.0103947
0.0111802
0.0120043
0.0128682
0.013773
0.0147199
0.01571
0.0167446
0.0178249
0.0189521
0.0201276
0.0213522
0.0226264
0.023951
0.000211801
0.00036744
0.000601034
0.000810809
0.00100702
0.00119244
0.00136953
0.00154063
0.00170806
0.00187419
0.00204158
0.00221305
0.00239202
0.0025831
0.00279366
0.00303786
0.00333273
0.00367142
0.0040475
0.00445757
0.00489994
0.00537416
0.00588028
0.00641883
0.00699052
0.00759603
0.00823553
0.00890972
0.00961937
0.0103654
0.011149
0.0119711
0.012833
0.0137357
0.0146804
0.0156684
0.0167008
0.0177788
0.0189038
0.0200767
0.0212985
0.0225697
0.0238905
0.000211732
0.000367452
0.00060118
0.000811127
0.00100754
0.00119318
0.00137048
0.00154173
0.00170926
0.00187544
0.00204276
0.00221404
0.00239261
0.002583
0.00279231
0.00303414
0.00332639
0.00366291
0.00403717
0.00444554
0.00488632
0.00535891
0.00586344
0.00640034
0.00697036
0.00757415
0.00821196
0.00888436
0.0095922
0.0103364
0.0111181
0.0119382
0.012798
0.0136987
0.0146413
0.0156271
0.0166573
0.0177331
0.0188557
0.020026
0.0212449
0.0225124
0.0238279
0.000211671
0.000367451
0.000601328
0.000811449
0.00100808
0.00119393
0.00137142
0.00154284
0.00171048
0.00187669
0.00204396
0.00221504
0.00239324
0.00258296
0.00279107
0.00303062
0.00332019
0.00365457
0.00402698
0.00443364
0.00487282
0.00534384
0.00584673
0.00638202
0.00695036
0.00755245
0.00818854
0.00885921
0.00956526
0.0103076
0.0110874
0.0119056
0.0127634
0.013662
0.0146025
0.0155861
0.0166141
0.0176877
0.0188078
0.0199755
0.0211911
0.0224545
0.023763
0.000211597
0.000367444
0.000601466
0.000811762
0.0010086
0.00119467
0.00137235
0.00154394
0.0017117
0.00187795
0.00204516
0.00221605
0.00239389
0.00258297
0.00278993
0.0030273
0.00331417
0.00364637
0.00401688
0.00442189
0.00485946
0.00532889
0.00583021
0.00636383
0.00693051
0.00753095
0.00816535
0.00883428
0.00953855
0.0102791
0.011057
0.0118732
0.012729
0.0136256
0.014564
0.0155455
0.0165713
0.0176425
0.0187602
0.0199251
0.0211377
0.0223983
0.0237078
0.000211534
0.000367459
0.000601599
0.000812083
0.00100911
0.0011954
0.00137328
0.00154502
0.00171291
0.0018792
0.00204636
0.00221707
0.00239456
0.00258301
0.00278889
0.0030242
0.00330834
0.00363833
0.00400697
0.00441028
0.00484624
0.0053141
0.00581384
0.00634585
0.00691086
0.0075096
0.00814234
0.00880956
0.00951208
0.0102508
0.0110268
0.0118411
0.012695
0.0135895
0.0145258
0.0155052
0.0165287
0.0175976
0.0187128
0.019875
0.0210847
0.0223422
0.0236467
0.000211455
0.000367446
0.000601703
0.000812383
0.00100963
0.00119612
0.0013742
0.00154611
0.00171411
0.00188044
0.00204756
0.00221811
0.00239525
0.0025831
0.00278794
0.00302127
0.00330265
0.00363041
0.0039972
0.00439882
0.00483316
0.00529946
0.00579761
0.00632801
0.00689131
0.00748845
0.00811949
0.00878501
0.00948576
0.0102227
0.0109968
0.0118093
0.0126612
0.0135536
0.0144879
0.0154651
0.0164865
0.017553
0.0186656
0.0198252
0.0210323
0.0222877
0.0235939
0.000211391
0.000367459
0.000601843
0.000812685
0.00101015
0.00119685
0.00137512
0.0015472
0.0017153
0.0018817
0.00204876
0.00221915
0.00239595
0.00258323
0.00278707
0.00301854
0.00329713
0.00362266
0.00398756
0.00438747
0.00482023
0.00528493
0.0057815
0.00631033
0.00687202
0.00746746
0.00809683
0.00876066
0.00945971
0.0101948
0.0109672
0.0117777
0.0126276
0.0135181
0.0144503
0.0154253
0.0164445
0.0175086
0.0186188
0.0197758
0.0209803
0.0222331
0.0235347
0.000211357
0.000367451
0.000602002
0.000812997
0.00101066
0.00119757
0.00137604
0.00154829
0.00171651
0.00188295
0.00204998
0.0022202
0.0023967
0.00258343
0.00278632
0.00301601
0.0032918
0.00361505
0.00397802
0.00437623
0.0048074
0.00527055
0.00576557
0.00629278
0.00685288
0.00744665
0.00807437
0.00873651
0.00943382
0.0101672
0.0109377
0.0117463
0.0125943
0.0134828
0.014413
0.0153859
0.0164027
0.0174646
0.0185723
0.0197267
0.0209284
0.0221778
0.0234742
0.000211288
0.000367453
0.000602134
0.000813301
0.00101116
0.00119829
0.00137695
0.00154937
0.00171772
0.00188421
0.0020512
0.00222127
0.00239747
0.00258368
0.00278565
0.00301364
0.00328663
0.00360759
0.00396865
0.00436516
0.00479472
0.00525632
0.00574978
0.00627542
0.00683391
0.00742601
0.00805212
0.00871259
0.00940818
0.0101398
0.0109084
0.0117152
0.0125613
0.0134478
0.0143759
0.0153467
0.0163613
0.0174207
0.018526
0.0196777
0.0208765
0.0221225
0.0234145
0.000211194
0.000367457
0.000602228
0.000813595
0.00101166
0.00119899
0.00137786
0.00155044
0.00171891
0.00188545
0.00205242
0.00222235
0.00239827
0.00258397
0.00278508
0.00301142
0.00328162
0.00360029
0.00395941
0.00435422
0.00478216
0.00524223
0.00573415
0.00625824
0.00681508
0.00740559
0.00803004
0.00868885
0.00938274
0.0101126
0.0108794
0.0116844
0.0125286
0.0134131
0.0143391
0.0153077
0.0163201
0.0173772
0.01848
0.0196291
0.0208249
0.0220677
0.0233569
0.000211114
0.00036745
0.000602325
0.000813883
0.00101215
0.0011997
0.00137876
0.00155151
0.00172009
0.00188671
0.00205364
0.00222345
0.00239908
0.00258431
0.00278456
0.00300934
0.00327678
0.00359311
0.00395032
0.0043434
0.00476977
0.00522829
0.00571866
0.00624117
0.00679645
0.00738532
0.0080081
0.00866526
0.00935747
0.0100856
0.0108507
0.0116538
0.012496
0.0133786
0.0143025
0.0152691
0.0162792
0.017334
0.0184342
0.0195806
0.0207738
0.022014
0.0233017
0.000211074
0.000367467
0.000602479
0.000814181
0.00101266
0.00120041
0.00137967
0.00155259
0.00172128
0.00188795
0.00205488
0.00222457
0.00239994
0.00258467
0.00278412
0.0030074
0.00327208
0.00358608
0.00394135
0.00433272
0.0047575
0.00521445
0.00570329
0.00622429
0.00677799
0.0073652
0.00798637
0.00864188
0.00933241
0.0100588
0.0108222
0.0116234
0.0124637
0.0133443
0.0142663
0.0152306
0.0162386
0.017291
0.0183888
0.0195327
0.0207236
0.0219625
0.0232534
0.000211025
0.000367461
0.000602633
0.000814485
0.00101316
0.00120111
0.00138056
0.00155365
0.00172248
0.00188922
0.00205613
0.0022257
0.00240081
0.00258511
0.00278376
0.00300557
0.00326755
0.0035792
0.00393249
0.00432214
0.00474534
0.00520076
0.00568809
0.00620752
0.00675967
0.00734526
0.00796481
0.00861869
0.00930755
0.0100323
0.0107938
0.0115932
0.0124317
0.0133103
0.0142302
0.0151925
0.0161982
0.0172483
0.0183437
0.0194852
0.0206738
0.0219105
0.0231958
0.00021097
0.000367471
0.000602765
0.000814779
0.00101364
0.0012018
0.00138145
0.0015547
0.00172367
0.00189048
0.00205738
0.00222684
0.00240172
0.00258558
0.00278346
0.00300385
0.00326318
0.00357246
0.00392379
0.00431172
0.00473332
0.00518722
0.00567304
0.00619095
0.00674152
0.00732547
0.00794346
0.00859572
0.00928293
0.0100059
0.0107657
0.0115633
0.0123999
0.0132766
0.0141945
0.0151546
0.0161581
0.0172059
0.0182989
0.0194381
0.0206244
0.0218588
0.023142
0.000210899
0.000367456
0.000602865
0.000815072
0.00101412
0.00120249
0.00138233
0.00155576
0.00172486
0.00189172
0.00205863
0.002228
0.00240264
0.00258607
0.00278321
0.00300221
0.00325895
0.00356585
0.00391523
0.00430145
0.00472143
0.00517382
0.00565812
0.00617451
0.00672348
0.0073059
0.00792224
0.00857292
0.00925848
0.00997978
0.0107378
0.0115337
0.0123684
0.0132431
0.0141589
0.015117
0.0161183
0.0171638
0.0182546
0.0193915
0.0205755
0.0218079
0.0230901
0.000210846
0.00036747
0.000602997
0.000815361
0.00101462
0.00120319
0.00138322
0.00155682
0.00172603
0.00189299
0.00205988
0.00222916
0.00240357
0.00258658
0.00278298
0.00300066
0.00325488
0.00355939
0.00390679
0.00429127
0.00470969
0.00516053
0.00564334
0.00615821
0.00670566
0.00728644
0.00790123
0.00855026
0.00923419
0.00995381
0.0107102
0.0115042
0.012337
0.0132098
0.0141236
0.0150796
0.0160787
0.0171221
0.0182106
0.0193452
0.0205271
0.0217571
0.0230367
0.000210801
0.000367472
0.000603131
0.000815652
0.00101511
0.00120388
0.00138411
0.00155788
0.00172723
0.00189426
0.00206116
0.00223034
0.00240453
0.00258714
0.00278282
0.00299921
0.00325098
0.00355307
0.00389848
0.00428121
0.00469805
0.00514738
0.00562866
0.00614205
0.00668796
0.00726716
0.00788035
0.0085278
0.0092101
0.00992808
0.0106827
0.0114749
0.0123059
0.0131768
0.0140886
0.0150425
0.0160395
0.0170806
0.0181669
0.0192993
0.0204788
0.0217062
0.0229816
0.000210742
0.000367467
0.000603257
0.000815937
0.00101558
0.00120456
0.00138499
0.00155893
0.00172842
0.00189552
0.00206244
0.00223153
0.0024055
0.00258771
0.00278269
0.00299783
0.00324724
0.00354689
0.00389027
0.0042713
0.00468654
0.00513436
0.00561417
0.00612601
0.00667042
0.00724805
0.00785968
0.00850555
0.00918623
0.00990256
0.0106554
0.0114459
0.0122751
0.013144
0.0140539
0.0150056
0.0160005
0.0170394
0.0181235
0.0192536
0.0204307
0.0216553
0.0229269
0.000210696
0.000367484
0.000603379
0.000816231
0.00101605
0.00120523
0.00138586
0.00155997
0.0017296
0.00189679
0.00206371
0.00223272
0.00240649
0.0025883
0.00278261
0.00299654
0.00324368
0.00354087
0.00388223
0.0042615
0.00467516
0.00512147
0.0055998
0.00611016
0.00665304
0.00722907
0.00783917
0.00848346
0.00916254
0.00987719
0.0106283
0.0114171
0.0122444
0.0131115
0.0140193
0.0149691
0.0159619
0.0169986
0.0180805
0.0192084
0.0203833
0.0216065
0.0228817
0.000210632
0.000367473
0.000603471
0.000816503
0.00101652
0.0012059
0.00138672
0.00156101
0.00173078
0.00189805
0.00206498
0.00223392
0.00240749
0.00258891
0.00278255
0.00299532
0.00324027
0.00353497
0.00387432
0.00425186
0.00466391
0.00510872
0.00558556
0.00609443
0.00663575
0.00721028
0.00781879
0.00846152
0.00913899
0.00985202
0.0106015
0.0113885
0.012214
0.0130791
0.013985
0.0149328
0.0159235
0.0169581
0.0180378
0.0191634
0.020336
0.0215562
0.0228228
0.000210585
0.000367489
0.000603599
0.000816777
0.001017
0.00120658
0.0013876
0.00156205
0.00173194
0.00189931
0.00206626
0.00223512
0.00240848
0.00258953
0.00278254
0.00299419
0.00323704
0.00352923
0.00386654
0.00424232
0.0046528
0.00509607
0.00557145
0.00607884
0.00661867
0.00719163
0.00779859
0.00843975
0.00911567
0.00982703
0.0105748
0.0113601
0.0121837
0.013047
0.013951
0.0148967
0.0158854
0.0169179
0.0179954
0.0191188
0.0202893
0.0215079
0.0227771
0.000210568
0.000367484
0.000603748
0.000817062
0.00101748
0.00120725
0.00138846
0.0015631
0.00173313
0.00190058
0.00206756
0.00223634
0.00240951
0.00259019
0.00278258
0.00299315
0.003234
0.00352365
0.00385887
0.00423288
0.00464178
0.00508357
0.00555745
0.00606336
0.00660173
0.00717317
0.00777856
0.00841817
0.00909249
0.00980226
0.0105484
0.0113318
0.0121538
0.0130152
0.0139172
0.014861
0.0158475
0.016878
0.0179533
0.0190747
0.0202432
0.0214601
0.0227273
0.000210515
0.000367489
0.00060387
0.00081734
0.00101793
0.00120792
0.00138932
0.00156414
0.00173431
0.00190185
0.00206884
0.00223755
0.00241053
0.00259087
0.00278265
0.0029922
0.00323114
0.00351821
0.00385135
0.00422359
0.0046309
0.00507119
0.0055436
0.00604806
0.00658495
0.00715485
0.00775873
0.00839679
0.00906953
0.00977769
0.0105221
0.0113039
0.012124
0.0129836
0.0138837
0.0148255
0.01581
0.0168384
0.0179117
0.019031
0.0201976
0.021413
0.0226795
0.000210438
0.000367494
0.000603952
0.000817608
0.00101839
0.00120858
0.00139018
0.00156515
0.00173548
0.0019031
0.00207013
0.00223877
0.00241158
0.00259158
0.00278278
0.00299134
0.00322844
0.00351294
0.00384397
0.00421444
0.00462014
0.00505894
0.0055299
0.00603291
0.00656827
0.00713672
0.00773904
0.00837556
0.00904673
0.00975326
0.010496
0.0112761
0.0120945
0.0129522
0.0138504
0.0147902
0.0157728
0.0167991
0.0178704
0.0189877
0.0201523
0.0213654
0.0226268
0.000210376
0.000367505
0.000604052
0.000817871
0.00101884
0.00120923
0.00139103
0.00156619
0.00173664
0.00190437
0.0020714
0.00223999
0.00241262
0.0025923
0.00278294
0.00299054
0.00322592
0.0035078
0.00383673
0.00420541
0.00460952
0.0050468
0.00551632
0.00601787
0.0065518
0.00711874
0.00771949
0.00835447
0.00902408
0.009729
0.0104702
0.0112485
0.0120651
0.012921
0.0138174
0.0147553
0.0157358
0.0167602
0.0178294
0.0189448
0.0201076
0.0213196
0.0225859
0.000210352
0.000367517
0.000604188
0.000818145
0.00101931
0.00120989
0.00139188
0.00156722
0.0017378
0.00190562
0.0020727
0.00224122
0.00241369
0.00259304
0.00278315
0.00298985
0.00322355
0.00350284
0.00382963
0.0041965
0.004599
0.0050348
0.00550284
0.00600298
0.00653545
0.00710089
0.00770011
0.00833356
0.00900162
0.00970498
0.0104445
0.0112212
0.012036
0.0128901
0.0137846
0.0147205
0.0156992
0.0167215
0.0177888
0.018902
0.0200624
0.0212703
0.0225208
0.00021032
0.000367511
0.000604329
0.000818422
0.00101978
0.00121055
0.00139273
0.00156824
0.00173898
0.00190688
0.00207399
0.00224246
0.00241477
0.00259382
0.00278342
0.00298924
0.00322133
0.00349801
0.00382263
0.00418769
0.00458861
0.0050229
0.00548953
0.0059882
0.00651924
0.00708319
0.0076809
0.00831283
0.00897933
0.00968114
0.010419
0.011194
0.0120071
0.0128594
0.0137521
0.0146861
0.0156628
0.0166832
0.0177484
0.0188595
0.0200174
0.0212226
0.0224765
0.000210283
0.000367524
0.000604456
0.000818707
0.00102023
0.0012112
0.00139357
0.00156925
0.00174014
0.00190814
0.00207528
0.0022437
0.00241587
0.00259463
0.00278374
0.00298872
0.00321927
0.00349335
0.00381579
0.00417904
0.00457834
0.00501116
0.00547634
0.0059736
0.0065032
0.00706565
0.00766186
0.00829227
0.00895725
0.00965745
0.0103937
0.011167
0.0119784
0.012829
0.0137198
0.014652
0.0156267
0.016645
0.0177082
0.0188171
0.0199724
0.0211742
0.0224204
0.00021023
0.000367512
0.000604545
0.00081897
0.00102067
0.00121184
0.00139441
0.00157026
0.0017413
0.00190939
0.00207656
0.00224496
0.00241698
0.00259546
0.00278409
0.00298824
0.0032173
0.00348881
0.00380909
0.00417053
0.0045682
0.00499954
0.00546328
0.00595911
0.00648723
0.00704828
0.00764293
0.00827187
0.00893533
0.00963396
0.0103686
0.0111403
0.01195
0.0127987
0.0136877
0.014618
0.0155908
0.0166072
0.0176683
0.0187749
0.0199277
0.0211272
0.0223727
0.000210193
0.00036753
0.000604668
0.000819233
0.00102113
0.00121249
0.00139525
0.00157128
0.00174243
0.00191065
0.00207785
0.00224621
0.00241809
0.0025963
0.00278447
0.00298784
0.00321546
0.00348443
0.00380252
0.00416212
0.0045582
0.00498801
0.00545034
0.00594475
0.00647146
0.00703102
0.00762419
0.00825159
0.00891354
0.00961062
0.0103437
0.0111137
0.0119217
0.0127687
0.0136559
0.0145844
0.0155553
0.0165697
0.0176287
0.0187333
0.0198847
0.0210853
0.0223443
0.000210188
0.000367536
0.000604808
0.000819504
0.00102158
0.00121314
0.00139608
0.00157229
0.0017436
0.0019119
0.00207916
0.00224748
0.00241923
0.00259719
0.0027849
0.00298751
0.00321373
0.00348019
0.00379607
0.00415381
0.00454829
0.00497664
0.0054375
0.00593052
0.00645581
0.00701391
0.00760557
0.00823149
0.00889192
0.00958749
0.010319
0.0110874
0.0118936
0.0127389
0.0136244
0.0145509
0.0155199
0.0165324
0.0175895
0.0186923
0.0198424
0.0210418
0.022292
0.000210149
0.000367546
0.000604925
0.000819771
0.00102203
0.00121377
0.00139691
0.0015733
0.00174475
0.00191315
0.00208046
0.00224875
0.00242038
0.00259809
0.00278537
0.00298722
0.00321209
0.00347609
0.00378974
0.00414565
0.00453851
0.00496537
0.00542483
0.0059164
0.0064403
0.00699693
0.00758714
0.00821158
0.00887051
0.00956455
0.0102945
0.0110612
0.0118658
0.0127094
0.013593
0.0145178
0.0154849
0.0164955
0.0175507
0.0186519
0.0198008
0.021
0.0222537
0.000210085
0.000367555
0.000605002
0.000820029
0.00102245
0.0012144
0.00139774
0.00157428
0.0017459
0.00191441
0.00208176
0.00225002
0.00242154
0.00259901
0.00278587
0.002987
0.00321056
0.00347213
0.00378356
0.00413761
0.00452885
0.00495422
0.00541226
0.00590245
0.00642492
0.00698014
0.00756885
0.00819181
0.00884926
0.00954175
0.0102701
0.0110352
0.0118382
0.0126801
0.0135619
0.0144849
0.0154502
0.0164589
0.0175124
0.0186121
0.0197597
0.0209575
0.0222078
0.000210034
0.000367553
0.000605088
0.000820273
0.00102289
0.00121503
0.00139856
0.00157528
0.00174704
0.00191565
0.00208305
0.00225131
0.00242272
0.00259995
0.00278639
0.0029868
0.00320908
0.0034683
0.00377751
0.00412971
0.00451931
0.00494321
0.00539982
0.00588862
0.00640964
0.00696347
0.00755068
0.00817217
0.00882813
0.00951913
0.0102459
0.0110095
0.0118108
0.0126509
0.013531
0.0144523
0.0154157
0.0164227
0.0174745
0.0185726
0.0197187
0.0209147
0.0221617
0.000210022
0.000367575
0.00060523
0.000820532
0.00102333
0.00121566
0.00139937
0.00157629
0.00174817
0.0019169
0.00208436
0.0022526
0.0024239
0.00260089
0.00278693
0.00298665
0.00320769
0.00346463
0.00377158
0.00412191
0.0045099
0.00493229
0.00538747
0.0058749
0.00639455
0.00694691
0.00753267
0.0081527
0.00880721
0.00949668
0.010222
0.010984
0.0117836
0.0126221
0.0135005
0.0144199
0.0153816
0.0163869
0.0174369
0.0185334
0.0196776
0.0208707
0.0221115
0.000210025
0.000367585
0.000605378
0.000820802
0.00102377
0.00121629
0.00140019
0.00157728
0.00174932
0.00191816
0.00208567
0.0022539
0.0024251
0.00260188
0.00278751
0.00298655
0.00320639
0.00346111
0.00376577
0.00411422
0.00450059
0.00492149
0.00537528
0.00586128
0.00637957
0.00693051
0.00751482
0.00813339
0.00878641
0.00947443
0.0101982
0.0109585
0.0117566
0.0125934
0.0134701
0.0143878
0.0153478
0.0163513
0.0173997
0.0184943
0.0196365
0.020827
0.0220664
0.000209996
0.000367596
0.000605496
0.000821062
0.0010242
0.00121691
0.001401
0.00157827
0.00175047
0.00191941
0.00208699
0.0022552
0.0024263
0.00260287
0.00278811
0.00298648
0.00320517
0.00345773
0.0037601
0.00410666
0.0044914
0.00491083
0.0053632
0.00584784
0.00636473
0.00691425
0.00749716
0.00811427
0.00876583
0.00945236
0.0101745
0.0109334
0.0117298
0.012565
0.01344
0.014356
0.0153143
0.016316
0.0173626
0.0184553
0.019595
0.0207818
0.0220133
0.000209939
0.000367604
0.000605575
0.000821312
0.00102463
0.00121753
0.00140181
0.00157924
0.0017516
0.00192065
0.0020883
0.00225651
0.00242752
0.00260387
0.00278873
0.00298646
0.00320402
0.00345452
0.00375458
0.00409926
0.00448233
0.00490028
0.00535125
0.00583451
0.00634999
0.00689816
0.00747965
0.00809529
0.0087454
0.00943043
0.0101511
0.0109084
0.0117033
0.0125368
0.0134101
0.0143245
0.015281
0.016281
0.0173257
0.0184163
0.0195534
0.0207367
0.0219649
0.000209897
0.000367617
0.000605673
0.000821557
0.00102505
0.00121814
0.00140261
0.00158023
0.00175273
0.00192191
0.0020896
0.00225782
0.00242873
0.00260488
0.00278936
0.00298646
0.00320295
0.00345144
0.00374918
0.00409194
0.00447339
0.00488985
0.00533941
0.00582129
0.00633543
0.00688221
0.00746225
0.00807644
0.0087251
0.00940865
0.0101279
0.0108836
0.0116769
0.0125088
0.0133805
0.0142932
0.015248
0.0162462
0.017289
0.0183773
0.0195116
0.0206916
0.0219164
0.000209892
0.000367635
0.000605804
0.000821814
0.00102548
0.00121876
0.00140342
0.00158121
0.00175385
0.00192315
0.00209092
0.00225913
0.00242996
0.00260589
0.00279002
0.00298651
0.00320194
0.00344853
0.00374392
0.00408475
0.00446456
0.00487951
0.00532766
0.00580821
0.00632099
0.00686637
0.00744501
0.00805775
0.00870497
0.0093871
0.0101049
0.0108591
0.0116508
0.0124811
0.0133512
0.0142621
0.0152152
0.0162116
0.0172523
0.0183383
0.01947
0.020647
0.0218681
0.000209883
0.000367635
0.000605944
0.000822076
0.00102592
0.00121939
0.00140423
0.00158219
0.001755
0.0019244
0.00209224
0.00226045
0.00243119
0.00260693
0.0027907
0.00298661
0.00320103
0.00344577
0.00373878
0.00407767
0.00445583
0.00486931
0.00531608
0.00579522
0.00630667
0.0068507
0.00742795
0.00803925
0.00868503
0.00936573
0.010082
0.0108347
0.0116249
0.0124536
0.013322
0.0142313
0.0151826
0.0161771
0.0172159
0.0182996
0.0194289
0.0206042
0.0218282
0.000209866
0.000367649
0.000606064
0.000822342
0.00102634
0.00121999
0.00140502
0.00158315
0.00175613
0.00192565
0.00209355
0.00226176
0.00243243
0.00260799
0.00279142
0.00298675
0.00320021
0.00344318
0.0037338
0.00407073
0.00444722
0.00485923
0.0053046
0.00578241
0.00629251
0.00683515
0.00741103
0.0080209
0.00866527
0.0093445
0.0100593
0.0108105
0.0115991
0.0124263
0.0132931
0.0142007
0.0151503
0.0161429
0.0171796
0.0182612
0.0193883
0.0205616
0.0217819
0.000209857
0.000367664
0.000606185
0.0008226
0.00102677
0.0012206
0.00140582
0.00158413
0.00175724
0.00192689
0.00209486
0.00226309
0.00243367
0.00260903
0.00279214
0.00298692
0.00319945
0.00344073
0.00372897
0.00406394
0.00443875
0.00484925
0.00529324
0.00576972
0.00627843
0.00681976
0.00739422
0.00800268
0.00864563
0.00932342
0.0100368
0.0107865
0.0115736
0.0123992
0.0132644
0.0141703
0.0151181
0.0161089
0.0171436
0.018223
0.019348
0.0205192
0.0217373
0.000209832
0.000367669
0.000606292
0.000822848
0.00102719
0.00122121
0.00140661
0.0015851
0.00175836
0.00192813
0.00209617
0.0022644
0.00243491
0.0026101
0.00279289
0.00298714
0.00319877
0.00343843
0.00372427
0.00405726
0.00443039
0.00483941
0.00528198
0.00575712
0.00626452
0.00680448
0.00737757
0.00798461
0.00862616
0.00930256
0.0100145
0.0107627
0.0115483
0.0123723
0.0132359
0.0141401
0.0150862
0.016075
0.0171078
0.0181853
0.0193084
0.0204786
0.0216992
0.000209833
0.00036769
0.00060641
0.000823099
0.00102761
0.00122181
0.0014074
0.00158607
0.00175949
0.00192937
0.00209749
0.00226573
0.00243617
0.0026112
0.00279367
0.00298741
0.00319817
0.00343626
0.00371969
0.00405067
0.00442214
0.00482966
0.00527086
0.00574463
0.00625073
0.00678934
0.00736107
0.0079667
0.00860685
0.00928185
0.00999234
0.0107391
0.0115232
0.0123457
0.0132076
0.0141102
0.0150544
0.0160415
0.0170723
0.0181478
0.0192691
0.0204373
0.0216527
0.000209819
0.000367706
0.000606494
0.000823328
0.00102802
0.00122241
0.00140818
0.00158703
0.00176061
0.00193061
0.0020988
0.00226706
0.00243744
0.0026123
0.00279448
0.00298772
0.00319765
0.00343423
0.00371526
0.00404424
0.00441402
0.00482005
0.00525986
0.0057323
0.00623707
0.00677433
0.00734474
0.00794898
0.00858774
0.00926134
0.00997033
0.0107157
0.0114983
0.0123192
0.0131795
0.0140804
0.0150229
0.0160081
0.0170371
0.0181107
0.0192301
0.0203963
0.0216098
0.000209781
0.000367718
0.000606585
0.000823579
0.00102843
0.001223
0.00140896
0.00158798
0.00176172
0.00193184
0.00210011
0.00226838
0.00243871
0.00261342
0.00279531
0.00298807
0.00319719
0.00343233
0.00371098
0.00403795
0.00440601
0.00481056
0.00524898
0.00572009
0.0062235
0.00675949
0.00732854
0.00793139
0.00856877
0.00924095
0.00994855
0.0106924
0.0114736
0.0122929
0.0131516
0.0140509
0.0149916
0.015975
0.0170021
0.018074
0.0191915
0.0203561
0.021569
0.000209754
0.00036774
0.000606692
0.000823812
0.00102883
0.00122358
0.00140974
0.00158894
0.00176282
0.00193307
0.00210141
0.00226971
0.00243998
0.00261455
0.00279615
0.00298845
0.0031968
0.00343052
0.00370681
0.00403176
0.00439813
0.00480118
0.00523821
0.00570798
0.0062101
0.00674478
0.00731245
0.00791392
0.00854992
0.00922075
0.00992696
0.0106694
0.011449
0.0122668
0.013124
0.0140216
0.0149606
0.0159423
0.0169675
0.0180375
0.0191535
0.0203167
0.0215301
0.000209763
0.000367771
0.000606825
0.00082406
0.00102925
0.00122418
0.00141052
0.0015899
0.00176393
0.0019343
0.00210273
0.00227105
0.00244128
0.00261568
0.00279703
0.00298887
0.00319646
0.00342884
0.00370278
0.00402569
0.00439037
0.00479189
0.00522754
0.00569601
0.00619684
0.00673017
0.00729651
0.00789661
0.00853127
0.0092007
0.00990555
0.0106466
0.0114247
0.012241
0.0130966
0.0139924
0.0149298
0.0159097
0.0169332
0.0180015
0.0191157
0.0202773
0.0214869
0.000209771
0.000367786
0.00060696
0.000824313
0.00102967
0.00122479
0.00141131
0.00159085
0.00176504
0.00193554
0.00210405
0.00227239
0.00244257
0.00261685
0.00279793
0.00298934
0.00319619
0.00342724
0.00369887
0.00401973
0.0043827
0.00478274
0.00521703
0.00568414
0.00618369
0.00671572
0.00728074
0.00787947
0.00851276
0.00918087
0.00988428
0.0106239
0.0114006
0.0122154
0.0130693
0.0139636
0.0148993
0.0158774
0.0168992
0.0179658
0.0190785
0.0202391
0.0214507
0.000209775
0.000367809
0.000607086
0.000824572
0.00103007
0.00122537
0.00141207
0.00159179
0.00176615
0.00193677
0.00210536
0.00227374
0.00244388
0.00261803
0.00279887
0.00298985
0.00319598
0.00342575
0.0036951
0.00401391
0.00437517
0.00477371
0.00520661
0.00567243
0.00617068
0.00670139
0.00726511
0.00786249
0.00849443
0.00916115
0.0098632
0.0106014
0.0113766
0.0121899
0.0130423
0.013935
0.014869
0.0158454
0.0168655
0.0179305
0.0190415
0.0202002
0.021407
0.00020976
0.000367801
0.000607179
0.000824813
0.00103047
0.00122594
0.00141283
0.00159273
0.00176725
0.00193799
0.00210668
0.00227508
0.00244519
0.00261921
0.00279981
0.00299037
0.0031958
0.00342434
0.00369146
0.00400823
0.00436775
0.0047648
0.00519632
0.00566083
0.00615774
0.00668721
0.00724961
0.00784566
0.00847626
0.00914162
0.0098423
0.0105791
0.0113529
0.0121646
0.0130155
0.0139066
0.0148389
0.0158137
0.0168322
0.0178953
0.0190045
0.0201605
0.0213624
0.000209759
0.000367836
0.0006073
0.000825055
0.00103088
0.00122653
0.0014136
0.00159367
0.00176833
0.00193922
0.00210798
0.00227643
0.0024465
0.0026204
0.00280076
0.00299092
0.00319568
0.00342299
0.00368795
0.00400265
0.00436046
0.00475597
0.00518614
0.00564933
0.00614499
0.00667316
0.00723424
0.00782897
0.00845822
0.00912224
0.00982159
0.010557
0.0113292
0.0121396
0.0129889
0.0138784
0.0148091
0.0157823
0.016799
0.0178604
0.0189676
0.0201211
0.0213208
0.000209793
0.000367878
0.000607426
0.000825301
0.00103129
0.00122712
0.00141437
0.00159462
0.00176944
0.00194045
0.00210931
0.00227779
0.00244783
0.00262162
0.00280175
0.00299151
0.00319559
0.00342174
0.00368457
0.00399718
0.00435327
0.00474729
0.00517605
0.00563797
0.00613235
0.00665923
0.00721903
0.00781244
0.00844034
0.00910305
0.00980104
0.010535
0.0113059
0.0121147
0.0129626
0.0138504
0.0147796
0.0157511
0.0167661
0.0178258
0.018931
0.0200826
0.0212812
0.000209804
0.000367902
0.000607544
0.000825544
0.0010317
0.0012277
0.00141513
0.00159556
0.00177054
0.00194168
0.00211062
0.00227914
0.00244916
0.00262285
0.00280275
0.00299212
0.00319555
0.00342056
0.0036813
0.00399184
0.00434619
0.00473872
0.00516613
0.0056267
0.00611984
0.00664546
0.00720399
0.00779611
0.00842267
0.00908405
0.00978064
0.0105132
0.0112827
0.0120901
0.0129364
0.0138227
0.0147503
0.0157201
0.0167335
0.0177914
0.0188951
0.0200462
0.0212495
0.000209783
0.000367913
0.00060763
0.000825783
0.00103208
0.00122827
0.00141589
0.00159648
0.00177163
0.0019429
0.00211194
0.0022805
0.0024505
0.00262408
0.00280377
0.00299276
0.00319556
0.00341946
0.00367818
0.00398664
0.00433925
0.00473026
0.0051563
0.0056156
0.00610747
0.00663181
0.00718909
0.00777991
0.00840514
0.00906517
0.00976043
0.0104917
0.0112598
0.0120657
0.0129105
0.0137953
0.0147212
0.0156894
0.0167011
0.0177575
0.0188595
0.0200083
0.0212035
0.000209771
0.000367914
0.000607726
0.000826011
0.00103247
0.00122883
0.00141663
0.00159741
0.00177272
0.00194412
0.00211326
0.00228187
0.00245185
0.00262532
0.0028048
0.00299341
0.00319558
0.00341842
0.00367521
0.00398156
0.00433241
0.00472193
0.00514659
0.00560461
0.00609518
0.00661832
0.0071743
0.00776386
0.00838777
0.00904647
0.00974041
0.0104703
0.011237
0.0120414
0.0128847
0.013768
0.0146924
0.015659
0.0166691
0.0177237
0.0188239
0.0199713
0.0211677
0.000209798
0.000367967
0.000607864
0.000826254
0.00103288
0.00122942
0.00141739
0.00159835
0.0017738
0.00194535
0.00211458
0.00228324
0.00245319
0.00262656
0.00280583
0.00299409
0.00319566
0.00341745
0.00367236
0.00397659
0.00432571
0.00471369
0.00513701
0.00559373
0.00608307
0.00660494
0.00715969
0.00774794
0.00837054
0.00902793
0.00972058
0.0104491
0.0112144
0.0120174
0.0128593
0.013741
0.0146638
0.0156289
0.0166373
0.0176902
0.0187886
0.0199332
0.0211233
0.00020985
0.000368022
0.000607999
0.000826502
0.00103329
0.00122999
0.00141815
0.00159928
0.0017749
0.00194657
0.0021159
0.00228461
0.00245455
0.00262783
0.00280689
0.0029948
0.00319577
0.00341656
0.00366966
0.00397174
0.0043191
0.00470559
0.00512751
0.00558298
0.00607108
0.00659171
0.0071452
0.00773218
0.00835347
0.00900959
0.00970091
0.0104281
0.011192
0.0119936
0.012834
0.0137143
0.0146355
0.015599
0.0166057
0.0176568
0.0187532
0.0198952
0.0210817
0.000209876
0.000368045
0.000608123
0.000826742
0.00103367
0.00123056
0.0014189
0.00160021
0.00177599
0.00194779
0.00211722
0.00228598
0.00245591
0.00262911
0.00280797
0.00299553
0.00319593
0.00341575
0.00366707
0.00396703
0.00431262
0.00469759
0.00511819
0.00557234
0.00605923
0.00657861
0.00713089
0.00771661
0.0083366
0.00899142
0.0096814
0.0104072
0.0111698
0.01197
0.012809
0.0136877
0.0146075
0.0155692
0.0165743
0.0176236
0.018718
0.0198578
0.0210439
0.000209868
0.00036805
0.000608222
0.000826979
0.00103407
0.00123112
0.00141965
0.00160112
0.00177707
0.001949
0.00211854
0.00228735
0.00245728
0.00263038
0.00280906
0.00299628
0.00319612
0.00341501
0.00366466
0.00396248
0.00430627
0.00468974
0.00510896
0.00556185
0.00604746
0.00656568
0.00711672
0.00770118
0.00831988
0.00897339
0.00966208
0.0103866
0.0111478
0.0119466
0.0127841
0.0136614
0.0145796
0.0155398
0.0165432
0.0175906
0.0186832
0.0198216
0.021008
0.00020987
0.000368076
0.000608333
0.000827216
0.00103447
0.0012317
0.00142039
0.00160205
0.00177815
0.00195023
0.00211985
0.00228873
0.00245864
0.00263167
0.00281015
0.00299704
0.00319636
0.00341433
0.00366237
0.00395802
0.00430005
0.00468199
0.00509985
0.00555148
0.00603588
0.00655287
0.00710266
0.00768587
0.00830329
0.00895553
0.00964296
0.0103662
0.011126
0.0119234
0.0127595
0.0136353
0.014552
0.0155106
0.0165122
0.0175579
0.0186484
0.0197839
0.0209617
0.000209909
0.000368127
0.000608464
0.000827459
0.00103486
0.00123226
0.00142114
0.00160298
0.00177923
0.00195145
0.00212119
0.00229011
0.00246003
0.00263295
0.00281126
0.00299784
0.00319663
0.00341374
0.00366021
0.00395371
0.00429395
0.00467434
0.00509084
0.00554123
0.00602442
0.00654018
0.00708875
0.00767073
0.00828687
0.00893786
0.00962402
0.0103459
0.0111044
0.0119005
0.0127352
0.0136095
0.0145246
0.0154816
0.0164816
0.0175256
0.0186148
0.0197511
0.0209424
0.000209977
0.000368191
0.000608595
0.000827705
0.00103526
0.00123284
0.00142189
0.00160389
0.00178032
0.00195267
0.00212251
0.00229149
0.0024614
0.00263427
0.00281239
0.00299867
0.00319695
0.00341321
0.00365817
0.0039495
0.00428796
0.00466684
0.005082
0.00553108
0.00601308
0.00652765
0.00707503
0.00765576
0.00827063
0.00892038
0.00960526
0.0103258
0.011083
0.0118777
0.012711
0.0135839
0.0144974
0.0154529
0.0164514
0.0174939
0.0185818
0.0197171
0.0209012
0.00021002
0.000368215
0.000608722
0.000827958
0.00103565
0.0012334
0.00142263
0.00160481
0.0017814
0.00195389
0.00212384
0.00229288
0.00246279
0.00263558
0.00281355
0.00299953
0.00319732
0.00341277
0.00365627
0.00394545
0.00428209
0.00465946
0.00507326
0.0055211
0.00600189
0.00651524
0.00706144
0.00764096
0.00825457
0.00890306
0.00958662
0.010306
0.0110619
0.0118552
0.012687
0.0135585
0.0144706
0.0154245
0.0164214
0.0174625
0.0185493
0.0196838
0.0208688
0.000210027
0.000368212
0.000608827
0.000828194
0.00103604
0.00123395
0.00142337
0.00160572
0.00178248
0.0019551
0.00212516
0.00229426
0.00246419
0.00263691
0.00281471
0.0030004
0.00319772
0.00341239
0.00365451
0.00394155
0.00427636
0.00465221
0.00506465
0.00551124
0.00599078
0.006503
0.00704797
0.0076263
0.00823866
0.00888589
0.00956824
0.0102863
0.0110409
0.0118329
0.0126633
0.0135333
0.014444
0.0153964
0.0163919
0.0174316
0.018517
0.0196499
0.0208314
0.000210061
0.000368271
0.000608957
0.000828432
0.00103644
0.00123452
0.00142411
0.00160664
0.00178354
0.00195632
0.00212647
0.00229565
0.00246557
0.00263823
0.00281588
0.00300129
0.00319817
0.00341207
0.00365285
0.00393774
0.00427077
0.00464505
0.00505616
0.0055015
0.00597987
0.00649087
0.00703468
0.00761177
0.0082229
0.0088689
0.00955004
0.0102668
0.0110201
0.0118108
0.0126398
0.0135084
0.0144176
0.0153686
0.0163626
0.0174008
0.0184849
0.0196159
0.0207942
0.000210138
0.000368347
0.000609088
0.000828675
0.00103683
0.00123508
0.00142485
0.00160756
0.00178463
0.00195754
0.00212781
0.00229704
0.00246698
0.00263958
0.00281708
0.00300223
0.00319866
0.00341183
0.0036513
0.00393408
0.00426528
0.00463805
0.00504777
0.0054919
0.00596907
0.0064789
0.00702151
0.00759741
0.00820731
0.00885211
0.00953202
0.0102476
0.0109995
0.0117889
0.0126166
0.0134838
0.0143916
0.0153411
0.0163337
0.0173705
0.018453
0.0195822
0.0207592
0.000210196
0.00036838
0.000609217
0.000828917
0.00103722
0.00123564
0.00142559
0.00160847
0.00178571
0.00195876
0.00212914
0.00229843
0.00246839
0.00264094
0.0028183
0.00300319
0.00319919
0.00341165
0.00364984
0.00393052
0.00425992
0.00463116
0.00503956
0.0054824
0.00595841
0.00646709
0.00700854
0.00758326
0.00819195
0.00883552
0.00951417
0.0102285
0.0109792
0.0117672
0.0125936
0.0134594
0.0143658
0.0153139
0.016305
0.0173404
0.0184213
0.0195488
0.0207234
0.000210236
0.000368432
0.000609343
0.000829169
0.00103761
0.0012362
0.00142632
0.00160937
0.00178679
0.00195998
0.00213047
0.00229984
0.00246981
0.00264231
0.00281954
0.00300418
0.00319976
0.00341153
0.00364849
0.00392711
0.00425468
0.0046244
0.00503146
0.00547308
0.00594791
0.0064554
0.00699572
0.00756926
0.00817676
0.00881909
0.00949652
0.0102096
0.0109591
0.0117458
0.0125708
0.0134353
0.0143403
0.015287
0.0162767
0.0173106
0.01839
0.0195161
0.0206909
0.000210277
0.000368442
0.000609453
0.000829404
0.00103799
0.00123675
0.00142706
0.00161029
0.00178786
0.0019612
0.00213181
0.00230124
0.00247124
0.00264369
0.00282079
0.00300518
0.00320036
0.00341146
0.00364724
0.00392384
0.00424958
0.00461778
0.00502348
0.00546388
0.0059375
0.00644389
0.00698302
0.00755542
0.00816174
0.00880285
0.00947909
0.0101909
0.0109392
0.0117246
0.0125483
0.0134114
0.014315
0.0152603
0.0162486
0.0172811
0.0183589
0.0194835
0.0206556
0.000210333
0.00036851
0.000609589
0.000829644
0.00103839
0.00123732
0.00142779
0.00161121
0.00178892
0.00196242
0.00213312
0.00230265
0.00247266
0.00264507
0.00282205
0.00300621
0.00320101
0.00341144
0.00364608
0.00392067
0.00424462
0.00461126
0.00501564
0.00545481
0.00592728
0.0064325
0.00697052
0.00754174
0.00814689
0.00878679
0.00946186
0.0101725
0.0109194
0.0117036
0.0125261
0.0133878
0.0142901
0.015234
0.0162209
0.0172519
0.0183283
0.0194515
0.0206232
0.000210431
0.000368592
0.000609725
0.000829889
0.00103879
0.00123788
0.00142853
0.00161211
0.00179001
0.00196364
0.00213447
0.00230406
0.00247411
0.00264649
0.00282334
0.00300728
0.00320169
0.00341148
0.003645
0.00391762
0.00423976
0.00460489
0.00500791
0.00544588
0.0059172
0.00642128
0.00695816
0.00752825
0.00813222
0.00877096
0.00944484
0.0101543
0.0109
0.0116829
0.0125041
0.0133645
0.0142654
0.015208
0.0161934
0.0172229
0.0182978
0.0194192
0.0205875
0.000210513
0.000368644
0.000609878
0.000830142
0.00103917
0.00123844
0.00142926
0.00161303
0.00179109
0.00196486
0.00213581
0.00230549
0.00247557
0.00264791
0.00282466
0.00300838
0.0032024
0.00341158
0.00364399
0.00391471
0.00423503
0.00459865
0.00500037
0.00543708
0.00590727
0.00641021
0.006946
0.00751496
0.00811779
0.00875534
0.00942799
0.0101362
0.0108808
0.0116625
0.0124823
0.0133415
0.0142411
0.0151822
0.0161663
0.0171944
0.0182675
0.0193868
0.0205518
0.00021056
0.000368667
0.000609987
0.000830377
0.00103956
0.00123899
0.00143
0.00161392
0.00179217
0.00196609
0.00213716
0.00230691
0.00247703
0.00264934
0.00282598
0.00300949
0.00320315
0.00341172
0.00364309
0.00391194
0.00423046
0.00459255
0.00499293
0.00542845
0.00589748
0.00639934
0.006934
0.00750185
0.00810353
0.00873988
0.00941137
0.0101184
0.0108618
0.0116423
0.0124608
0.0133187
0.014217
0.0151568
0.0161394
0.0171659
0.0182373
0.0193544
0.0205171
0.000210618
0.000368722
0.000610112
0.000830618
0.00103995
0.00123955
0.00143073
0.00161484
0.00179324
0.00196731
0.0021385
0.00230834
0.0024785
0.00265079
0.00282732
0.00301061
0.00320393
0.0034119
0.00364225
0.0039093
0.00422599
0.00458658
0.00498564
0.00541998
0.00588784
0.00638862
0.00692216
0.00748889
0.00808943
0.00872466
0.00939499
0.0101009
0.010843
0.0116222
0.0124396
0.0132962
0.0141931
0.0151316
0.0161128
0.0171377
0.0182073
0.0193223
0.0204827
0.000210719
0.000368806
0.000610258
0.000830868
0.00104035
0.00124011
0.00143147
0.00161576
0.00179431
0.00196854
0.00213986
0.00230979
0.00247997
0.00265224
0.00282868
0.00301178
0.00320475
0.00341214
0.0036415
0.00390676
0.00422167
0.00458073
0.00497847
0.00541163
0.00587839
0.00637804
0.0069105
0.00747613
0.00807557
0.0087096
0.00937883
0.0100836
0.0108245
0.0116026
0.0124187
0.013274
0.0141696
0.0151067
0.0160864
0.0171096
0.0181775
0.0192905
0.020449
0.000210852
0.000368903
0.000610406
0.000831123
0.00104075
0.00124068
0.00143222
0.00161668
0.00179541
0.00196978
0.00214122
0.00231124
0.00248146
0.00265372
0.00283006
0.00301297
0.00320559
0.00341243
0.00364081
0.00390436
0.00421748
0.00457504
0.00497148
0.00540341
0.00586908
0.00636766
0.00689905
0.0074636
0.00806191
0.00869482
0.0093629
0.0100665
0.0108063
0.0115831
0.012398
0.0132521
0.0141464
0.0150821
0.0160603
0.017082
0.0181481
0.0192593
0.0204163
0.000210964
0.000368958
0.000610553
0.000831386
0.00104114
0.00124124
0.00143295
0.0016176
0.0017965
0.00197103
0.00214259
0.0023127
0.00248297
0.00265521
0.00283147
0.00301418
0.00320648
0.00341277
0.00364021
0.0039021
0.00421342
0.00456949
0.00496463
0.0053954
0.00585996
0.00635744
0.00688778
0.00745125
0.00804846
0.00868025
0.00934714
0.0100496
0.0107883
0.011564
0.0123777
0.0132304
0.0141234
0.0150577
0.0160345
0.0170547
0.0181193
0.0192291
0.0203861
0.000211045
0.000368993
0.000610682
0.000831634
0.00104153
0.00124179
0.00143369
0.0016185
0.00179759
0.00197226
0.00214397
0.00231416
0.00248449
0.00265672
0.00283289
0.00301541
0.00320739
0.00341316
0.00363971
0.0039
0.00420952
0.0045641
0.00495794
0.00538754
0.00585096
0.00634742
0.0068767
0.0074391
0.00803523
0.00866587
0.00933169
0.010033
0.0107706
0.011545
0.0123575
0.0132091
0.0141008
0.0150337
0.016009
0.0170278
0.0180908
0.0191997
0.0203563
0.000211136
0.000369063
0.000610825
0.000831881
0.00104194
0.00124236
0.00143443
0.00161943
0.00179867
0.00197352
0.00214534
0.00231564
0.00248601
0.00265824
0.00283432
0.00301667
0.00320834
0.00341358
0.00363927
0.00389802
0.00420577
0.00455884
0.00495141
0.00537984
0.00584219
0.00633759
0.00686579
0.00742714
0.00802219
0.00865173
0.00931648
0.0100167
0.0107531
0.0115264
0.0123377
0.013188
0.0140784
0.01501
0.0159839
0.0170012
0.0180632
0.0191712
0.0203287
0.000211294
0.000369187
0.000610984
0.000832139
0.00104234
0.00124293
0.00143518
0.00162037
0.00179979
0.00197478
0.00214674
0.00231713
0.00248756
0.00265977
0.00283579
0.00301797
0.00320933
0.00341407
0.00363892
0.00389618
0.00420215
0.00455375
0.00494501
0.00537232
0.0058336
0.00632793
0.0068551
0.0074154
0.00800939
0.00863786
0.00930152
0.0100007
0.0107359
0.0115081
0.0123182
0.0131673
0.0140564
0.0149866
0.0159591
0.0169752
0.018036
0.0191431
0.0202984
0.000211479
0.000369293
0.000611153
0.000832409
0.00104275
0.00124352
0.00143595
0.00162131
0.0018009
0.00197605
0.00214815
0.00231864
0.00248912
0.00266134
0.00283727
0.00301929
0.00321036
0.00341463
0.00363865
0.00389447
0.00419869
0.00454881
0.00493883
0.00536496
0.00582519
0.00631849
0.00684466
0.00740393
0.00799687
0.00862426
0.0092868
0.00998484
0.010719
0.0114901
0.012299
0.0131469
0.0140347
0.0149637
0.0159348
0.0169496
0.0180093
0.0191154
0.0202704
0.000211594
0.00036932
0.000611299
0.000832677
0.00104315
0.00124409
0.00143669
0.00162223
0.00180202
0.00197733
0.00214956
0.00232015
0.0024907
0.00266292
0.00283879
0.00302065
0.00321144
0.00341523
0.00363848
0.00389293
0.00419541
0.00454406
0.0049328
0.00535782
0.00581699
0.00630925
0.00683442
0.00739268
0.00798458
0.00861087
0.00927236
0.00996934
0.0107024
0.0114724
0.0122801
0.0131268
0.0140134
0.0149409
0.0159109
0.0169244
0.0179829
0.0190876
0.0202396
0.000211703
0.000369383
0.00061144
0.000832937
0.00104356
0.00124466
0.00143746
0.00162319
0.00180315
0.00197862
0.00215099
0.00232169
0.0024923
0.00266452
0.00284034
0.00302203
0.00321255
0.0034159
0.0036384
0.00389153
0.00419226
0.00453947
0.00492696
0.00535086
0.00580895
0.00630025
0.00682442
0.00738166
0.00797254
0.00859777
0.00925822
0.00995414
0.0106861
0.0114549
0.0122615
0.013107
0.0139924
0.0149188
0.0158874
0.0168996
0.0179566
0.0190593
0.0202078
0.000211882
0.000369513
0.000611621
0.000833212
0.00104399
0.00124525
0.00143823
0.00162416
0.00180427
0.00197992
0.00215243
0.00232325
0.00249391
0.00266615
0.00284189
0.00302346
0.00321371
0.00341662
0.00363841
0.00389027
0.0041893
0.00453504
0.00492132
0.00534411
0.00580118
0.00629147
0.00681463
0.00737088
0.00796074
0.00858494
0.00924438
0.00993927
0.0106701
0.0114379
0.0122433
0.0130876
0.0139717
0.0148968
0.0158642
0.016875
0.0179304
0.0190303
0.0201727
0.000212101
0.000369649
0.000611804
0.000833495
0.00104442
0.00124586
0.00143901
0.00162513
0.00180544
0.00198124
0.0021539
0.00232482
0.00249555
0.00266781
0.0028435
0.00302493
0.00321493
0.00341742
0.00363851
0.00388914
0.00418649
0.00453082
0.00491584
0.00533756
0.00579362
0.00628291
0.0068051
0.00736038
0.00794924
0.00857243
0.00923084
0.00992467
0.0106545
0.0114211
0.0122255
0.0130686
0.0139515
0.0148754
0.0158415
0.0168509
0.0179045
0.0190033
0.0201503
0.000212308
0.000369749
0.000611989
0.000833782
0.00104485
0.00124646
0.00143981
0.00162611
0.00180661
0.00198258
0.00215538
0.00232641
0.00249722
0.0026695
0.00284515
0.00302645
0.0032162
0.00341829
0.0036387
0.00388818
0.00418387
0.00452679
0.00491064
0.00533124
0.0057863
0.00627463
0.00679588
0.00735019
0.00793807
0.00856026
0.0092176
0.00991039
0.0106392
0.0114048
0.012208
0.0130499
0.0139316
0.0148543
0.0158191
0.0168269
0.0178789
0.0189754
0.0201154
0.000212489
0.000369826
0.000612155
0.000834075
0.00104528
0.00124707
0.00144061
0.00162709
0.00180779
0.00198394
0.00215689
0.00232803
0.00249892
0.00267122
0.00284684
0.00302801
0.00321754
0.00341924
0.00363902
0.00388739
0.00418145
0.00452298
0.00490562
0.00532517
0.00577924
0.0062666
0.00678692
0.00734029
0.0079272
0.00854838
0.0092047
0.00989649
0.0106243
0.0113887
0.0121909
0.0130317
0.0139122
0.0148336
0.0157971
0.0168034
0.0178534
0.0189475
0.0200849
0.000212692
0.000369937
0.000612337
0.000834364
0.00104572
0.00124769
0.00144143
0.00162812
0.001809
0.00198532
0.00215842
0.00232969
0.00250066
0.00267299
0.00284857
0.00302962
0.00321893
0.00342026
0.00363944
0.00388674
0.00417921
0.00451938
0.00490084
0.00531936
0.00577242
0.00625888
0.00677824
0.0073307
0.00791663
0.00853685
0.00919219
0.00988297
0.0106097
0.0113731
0.0121741
0.0130138
0.0138931
0.0148133
0.0157753
0.01678
0.0178283
0.0189203
0.0200559
0.000212953
0.000370082
0.000612544
0.000834675
0.0010462
0.00124834
0.00144227
0.00162916
0.00181022
0.00198673
0.00215999
0.00233139
0.00250244
0.0026748
0.00285034
0.0030313
0.0032204
0.00342138
0.00363996
0.00388624
0.00417718
0.00451599
0.00489632
0.00531379
0.00576592
0.00625143
0.0067699
0.00732139
0.00790645
0.00852568
0.00918005
0.00986985
0.0105955
0.0113579
0.0121578
0.0129963
0.0138745
0.0147933
0.015754
0.0167572
0.0178039
0.0188949
0.0200314
0.000213261
0.000370244
0.000612757
0.000834998
0.00104668
0.00124902
0.00144314
0.00163023
0.00181149
0.00198818
0.0021616
0.00233313
0.00250426
0.00267667
0.00285219
0.00303305
0.00322195
0.00342259
0.0036406
0.0038859
0.00417536
0.00451289
0.00489205
0.00530853
0.00575972
0.00624434
0.00676191
0.00731252
0.00789663
0.00851493
0.0091683
0.00985709
0.0105818
0.0113431
0.012142
0.0129793
0.0138561
0.0147738
0.0157331
0.016735
0.017781
0.0188737
0.0200227
0.000213568
0.000370381
0.000612997
0.000835355
0.00104717
0.0012497
0.00144403
0.00163133
0.0018128
0.00198967
0.00216326
0.00233492
0.00250616
0.0026786
0.00285412
0.00303488
0.0032236
0.00342391
0.00364138
0.00388576
0.00417377
0.00451002
0.00488811
0.00530357
0.00575386
0.00623757
0.00675427
0.007304
0.0078872
0.00850457
0.00915694
0.00984473
0.0105684
0.0113287
0.0121265
0.0129627
0.0138384
0.0147547
0.0157128
0.0167136
0.0177589
0.0188512
0.0199925
0.000213865
0.000370497
0.0006132
0.000835685
0.00104768
0.0012504
0.00144495
0.00163246
0.00181415
0.00199122
0.00216497
0.00233677
0.00250811
0.00268061
0.00285612
0.0030368
0.00322533
0.00342534
0.00364231
0.00388582
0.00417245
0.00450745
0.00488446
0.00529896
0.00574833
0.00623119
0.00674703
0.00729588
0.00787819
0.00849462
0.00914604
0.00983287
0.0105556
0.0113148
0.0121115
0.0129466
0.0138212
0.0147363
0.015693
0.0166927
0.0177368
0.0188269
0.0199613
0.0002142
0.000370654
0.000613435
0.000836047
0.00104823
0.00125115
0.00144591
0.00163365
0.00181555
0.00199282
0.00216674
0.0023387
0.00251015
0.0026827
0.00285821
0.00303881
0.00322719
0.00342689
0.00364338
0.00388606
0.00417137
0.00450519
0.00488115
0.00529473
0.00574319
0.00622522
0.00674018
0.00728818
0.00786959
0.00848514
0.00913561
0.00982147
0.0105432
0.0113014
0.012097
0.012931
0.0138044
0.0147183
0.0156738
0.0166723
0.0177148
0.0188021
0.0199322
0.000214639
0.000370878
0.000613705
0.000836442
0.00104881
0.00125195
0.00144694
0.00163492
0.00181703
0.00199451
0.00216862
0.00234073
0.00251228
0.0026849
0.00286042
0.00304096
0.00322917
0.0034286
0.00364462
0.00388652
0.0041706
0.00450326
0.00487822
0.00529088
0.0057385
0.00621966
0.0067338
0.00728095
0.00786152
0.00847612
0.00912567
0.00981059
0.0105313
0.0112885
0.012083
0.0129158
0.0137881
0.0147008
0.0156551
0.0166521
0.0176932
0.0187789
0.0199102
0.000215142
0.000371102
0.00061401
0.000836882
0.00104945
0.00125282
0.00144805
0.00163626
0.00181861
0.00199631
0.00217061
0.00234287
0.00251455
0.00268724
0.00286277
0.00304325
0.00323132
0.00343049
0.00364605
0.00388721
0.00417013
0.00450173
0.0048757
0.00528745
0.00573426
0.00621461
0.00672794
0.00727425
0.00785394
0.00846766
0.00911625
0.00980016
0.0105199
0.0112761
0.0120695
0.0129012
0.0137723
0.0146838
0.0156369
0.0166326
0.0176722
0.0187566
0.0198881
0.000215644
0.000371262
0.000614318
0.000837362
0.00105013
0.00125375
0.00144924
0.0016377
0.00182031
0.00199823
0.00217274
0.00234517
0.00251697
0.00268975
0.00286529
0.00304573
0.00323365
0.00343256
0.00364771
0.00388819
0.00417005
0.0045006
0.00487365
0.00528455
0.00573053
0.00621006
0.00672259
0.00726807
0.0078469
0.00845973
0.00910732
0.00979032
0.0105091
0.0112642
0.0120566
0.0128872
0.0137572
0.0146674
0.0156191
0.0166134
0.0176514
0.0187336
0.0198582
0.000216172
0.000371485
0.000614658
0.000837885
0.00105089
0.00125477
0.00145055
0.00163929
0.00182216
0.00200031
0.00217504
0.00234764
0.00251958
0.00269244
0.00286801
0.00304839
0.00323618
0.00343486
0.00364961
0.00388947
0.00417033
0.00449992
0.00487208
0.00528215
0.0057273
0.00620608
0.0067178
0.00726246
0.00784043
0.00845235
0.00909903
0.00978106
0.0104988
0.0112529
0.0120442
0.0128737
0.0137424
0.0146514
0.0156019
0.0165949
0.0176312
0.0187121
0.0198399
0.000217009
0.000371872
0.000615214
0.000838672
0.00105198
0.00125617
0.00145226
0.00164131
0.00182442
0.00200284
0.00217777
0.00235055
0.00252261
0.00269555
0.00287113
0.00305147
0.00323913
0.00343754
0.00365191
0.00389118
0.00417121
0.00449988
0.0048712
0.00528045
0.0057248
0.00620276
0.00671365
0.00725747
0.00783457
0.00844558
0.00909135
0.00977241
0.0104891
0.0112422
0.0120324
0.0128608
0.0137284
0.0146362
0.0155852
0.0165766
0.0176112
0.0186893
0.0198083
0.000217553
0.000371855
0.000615083
0.000838623
0.00105215
0.00125663
0.00145302
0.00164238
0.00182581
0.00200449
0.00217966
0.00235264
0.00252485
0.00269789
0.00287351
0.0030538
0.00324133
0.00343952
0.00365355
0.00389225
0.00417134
0.00449917
0.00486971
0.0052783
0.00572201
0.00619931
0.00670955
0.00725268
0.00782904
0.00843927
0.00908416
0.00976432
0.01048
0.0112321
0.0120212
0.0128484
0.0137147
0.0146212
0.0155689
0.0165588
0.0175916
0.018668
0.0197889
0.000220609
0.00037527
0.000620189
0.000844876
0.00105933
0.00126454
0.0014615
0.00165129
0.00183508
0.00201403
0.00218941
0.00236255
0.00253488
0.002708
0.00288366
0.00306396
0.00325145
0.00344956
0.00366346
0.00390218
0.00418175
0.00450934
0.00487912
0.00528656
0.00572894
0.00620474
0.00671334
0.00725471
0.00782923
0.00843755
0.00908047
0.00975865
0.0104725
0.0112227
0.0120101
0.0128356
0.0137003
0.0146051
0.0155513
0.0165398
0.0175714
0.0186467
0.0197671
0.000209571
0.000355138
0.000595669
0.000817725
0.00103041
0.00123442
0.00143052
0.00161967
0.00180295
0.00198146
0.0021564
0.00232904
0.00250076
0.00267304
0.00284758
0.00302629
0.00321151
0.00340643
0.00361593
0.00384855
0.00411908
0.00443964
0.0048048
0.0052092
0.0056497
0.00612455
0.00663303
0.00717496
0.00775066
0.0083607
0.00900585
0.00968684
0.010404
0.0111578
0.0119492
0.0127789
0.013648
0.0145575
0.0155083
0.0165016
0.0175379
0.0186186
0.0197457
0.113584
0.126317
0.380373
0.106071
0.0339944
0.0316663
0.0410405
0.0331715
0.0629478
0.193444
0.0343566
0.0407474
0.0500419
0.0645448
0.0419579
0.134485
0.102414
0.0339183
0.0368285
0.0357234
0.045023
0.0861384
0.0353122
0.124492
0.0473183
0.0286979
0.0202815
0.0368864
0.0273981
0.0762075
0.0351497
0.0811727
0.0227553
0.00787546
0.0357535
0.136027
0.114633
0.0444303
0.0372889
0.028612
0.121671
0.0210348
0.0246101
0.0676624
0.0232429
0.0494106
0.0339455
0.0513562
0.0323119
0.0746084
0.136757
0.0299598
0.106137
0.0832431
0.128439
0.0320241
0.043504
0.0494457
0.0951151
0.0487796
0.0496706
0.030878
0.03436
0.0226227
0.111817
0.0739654
0.0689279
0.121091
0.137849
0.0288622
0.0749069
0.0271893
0.0467672
0.0338262
0.130786
0.0438203
0.027963
0.0372553
0.0324568
0.037286
0.070387
0.0382975
0.0668992
0.0678769
0.0839
0.0337345
0.0910477
0.0606042
0.0225397
0.0586609
0.0304817
0.138751
0.064631
0.029475
0.0636903
0.137445
0.035896
0.0350637
0.0448592
0.00329108
0.134583
0.0471136
0.0100646
0.0836673
0.0639187
0.0552589
0.0252846
0.038674
0.119401
0.132407
0.0592056
0.125363
0.052842
0.0235692
0.0582564
0.0972542
0.0630978
0.031595
0.022194
0.057848
0.0351171
0.0596384
0.0598351
0.0274292
0.0793733
0.136894
0.141644
0.0343908
0.246292
0.123517
0.0336517
0.0521818
0.225957
0.0316988
0.0568109
0.0287948
0.0437044
0.0327019
0.0232167
0.0307672
0.0741043
0.168933
0.0331297
0.098663
0.133451
0.128739
0.127421
0.130888
0.033191
0.130503
0.113536
0.062717
0.036685
0.0564113
0.117541
0.1393
0.0356826
0.0695502
0.0817842
0.103985
0.033503
0.0461533
0.138716
0.030349
0.125108
0.137497
0.0773559
0.0339016
0.029937
0.13733
0.0359243
0.0369118
0.031303
0.0236813
0.0313072
0.0588097
0.0239885
0.0429417
0.139115
0.107678
0.138904
0.0373664
0.0501311
0.135818
0.133248
0.0328538
0.0446926
0.110605
0.105893
0.0369516
0.0600364
0.132972
0.0345918
0.120144
0.0297443
0.027216
0.138714
0.0696791
0.0513057
0.0333733
0.0452929
0.042559
0.0388807
0.34269
0.0317817
0.0580494
0.0785091
0.066466
0.137819
0.138614
0.0549872
0.0570426
0.0476211
0.128351
0.0351361
0.0142109
0.142513
0.0803672
0.138092
0.0457675
0.0326273
0.0688335
0.0284147
0.0451031
0.133883
0.0433013
0.122805
0.0225985
0.030847
0.0358387
0.136621
0.13386
0.0404467
0.0746999
0.0589114
0.032775
0.0371039
0.0420937
0.0259011
0.0460687
0.0570007
0.0398168
0.025711
0.0317087
0.109907
0.0400269
0.13226
0.13884
0.136937
0.031889
0.0342181
0.139677
0.0595196
0.02835
0.0742391
0.0578493
0.0802124
0.0302125
0.0327235
0.03057
0.044509
0.0344485
0.113285
0.0229404
0.033452
0.0709891
0.029136
0.11995
0.0676881
0.0353076
0.0525526
0.132179
0.0233867
0.136026
0.0398238
0.0347224
0.0622115
0.0901693
0.0204666
0.0484015
0.0379605
0.0263387
0.325225
0.0417173
0.0577187
0.0416288
0.0626232
0.0847993
0.0243533
0.0373601
0.0350137
0.0776277
0.110302
0.0591218
0.0516986
0.124094
0.0421089
0.0824494
0.0419483
0.035527
0.138109
0.131571
0.0234795
0.122938
0.0330205
0.131253
0.0474725
0.0508537
0.0430981
0.0281618
0.127761
0.0787146
0.0403845
0.0321174
0.0925328
0.0353267
0.0470874
0.289092
0.0466864
0.0748674
0.139418
0.136764
0.131485
0.0708879
0.0832601
0.0701624
0.0581315
0.0870355
0.0776928
0.0888966
0.0611227
0.123594
0.0380128
0.138068
0.0374391
0.0293698
0.0334958
0.0421451
0.0341601
0.090588
0.0343833
0.0711948
0.0272361
0.0444352
0.0274573
0.111928
0.0780628
0.0501646
0.0290988
0.0646074
0.131296
0.0213878
0.139587
0.0815848
0.0879626
0.0401313
0.0225037
0.0423225
0.0343047
0.0444593
0.039247
0.0362644
0.103182
0.0836746
0.139068
0.0342458
0.0295591
0.0346223
0.0418835
0.0397676
0.13889
0.0245035
0.139289
0.0513183
0.0406712
0.006365
0.137575
0.0238341
0.0597608
0.0391153
0.0456263
0.0601201
0.0813926
0.0637416
0.0235859
0.0340727
0.0859908
0.109131
0.0438089
0.0872955
0.0552971
0.0523836
0.0299994
0.050683
0.137517
0.0250789
0.0240655
0.0290935
0.0763871
0.0352672
0.131619
0.0426696
0.0361137
0.0503756
0.136474
0.0334307
0.0297128
0.0276208
0.0924814
0.03095
0.0598059
0.0366656
0.136226
0.07193
0.0478856
0.0249491
0.0255063
0.0355871
0.138181
0.0568487
0.0292331
0.0330189
0.0288222
0.0685556
0.124449
0.121904
0.0261479
0.0155292
0.0337357
0.0284955
0.139417
0.0608084
0.115689
0.0359617
0.126278
0.0373313
0.0531846
0.0240206
0.0364517
0.0422046
0.100009
0.162022
0.0525095
0.0515041
0.0509642
0.0267531
0.0657748
0.047666
0.0315749
0.0470793
0.0492949
0.0560598
0.00788008
0.043741
0.022598
0.081724
0.0576418
0.0448228
0.0345199
0.0324941
0.0571712
0.137025
0.0304061
0.366412
0.038434
0.0545261
0.0289358
0.0526558
0.0604031
0.0418229
0.13841
0.0306303
0.0467224
0.139652
0.0483255
0.125602
0.0240995
0.138012
0.043206
0.0356104
0.0276824
0.0407368
0.0273117
0.0286877
0.0412943
0.0892009
0.0335695
0.0226063
0.0215026
0.0485363
0.0596623
0.0518198
0.107458
0.0381416
0.0232159
0.137475
0.0440373
0.029454
0.137558
0.0350718
0.0364476
0.0536038
0.0328292
0.0288098
0.0249396
0.0986455
0.0828852
0.0863697
0.139506
0.0309812
0.120892
0.128136
0.139578
0.137686
0.0933904
0.0724391
0.134848
0.0842793
0.135025
0.0972355
0.0819309
0.0159938
0.0281775
0.0746716
0.0501149
0.0745113
0.0267458
0.248566
0.037056
0.0788837
0.116291
0.0544159
0.0332304
0.0625477
0.112365
0.0469257
0.0349573
0.0928499
0.136497
0.104399
0.0592948
0.0359053
0.121655
0.0777747
0.0346794
0.0915096
0.0318202
0.138921
0.018177
0.137832
0.139883
0.0491251
0.0802317
0.0769818
0.018362
0.138529
0.117858
0.0803394
0.0327611
0.109815
0.0229409
0.0209085
0.0448233
0.0355195
0.109775
0.0189516
0.0637475
0.0530686
0.0502768
0.24734
0.0706724
0.0512504
0.0369196
0.0511569
0.0544723
0.0933557
0.134062
0.0582319
0.0793899
0.0326178
0.035355
0.0692265
0.0636368
0.0325903
0.0373016
0.0220064
0.136661
0.0489764
0.0322789
0.106861
0.0255786
0.0511735
0.128417
0.0456806
0.037501
0.136443
0.127315
0.0630361
0.088807
0.0443367
0.102984
0.0393158
0.027913
0.134245
0.0316206
0.128346
0.0485686
0.13691
0.0386483
0.0713652
0.042523
0.136316
0.0418825
0.139594
0.132224
0.0261098
0.136981
0.025292
0.0433479
0.0371651
0.0253472
0.113083
0.0650138
0.0331912
0.00926203
0.0614403
0.0381674
0.131723
0.13459
0.0836114
0.0437492
0.0638788
0.0344903
0.0758559
0.0545483
0.0317225
0.0404866
0.128686
0.137018
0.0299263
0.0413628
0.049364
0.0316132
0.0462486
0.139866
0.0797632
0.0811237
0.033325
0.0379097
0.0368968
0.0318727
0.137757
0.0332456
0.303039
0.0383046
0.0755522
0.0258493
0.127213
0.058602
0.118159
0.0564307
0.0762212
0.0359328
0.0709376
0.0396339
0.0797215
0.0436693
0.0670822
0.0257187
0.0173892
0.00321781
0.0347415
0.0693154
0.139156
0.0362947
0.0412121
0.0504964
0.102664
0.124557
0.0317504
0.0579481
0.03829
0.0406361
0.0732511
0.0752691
0.0640643
0.129305
0.0820946
0.0526856
0.0584414
0.0711518
0.0775569
0.0514836
0.0297124
0.0770589
0.0940782
0.0383107
0.0314066
0.045676
0.0376229
0.0881511
0.0381907
0.131387
0.13734
0.0974732
0.117113
0.0231797
0.0252486
0.0172167
0.143904
0.0571012
0.0401655
0.0518923
0.0634689
0.0422593
0.0341326
0.0507977
0.051541
0.0358924
0.140379
0.0258466
0.0771905
0.0955647
0.075628
0.131117
0.0234202
0.0503438
0.0359481
0.0330018
0.125278
0.00749232
0.125548
0.0720439
0.133332
0.0724125
0.112666
0.205731
0.037416
0.139301
0.0490023
0.0364821
0.0583744
0.00648586
0.0355228
0.0742083
0.0283813
0.0586118
0.0323367
0.0316477
0.122462
0.119985
0.115073
0.0625487
0.0343088
0.0267475
0.0265735
0.0434627
0.0257933
0.0776194
0.105682
0.0520546
0.0431498
0.0486185
0.086823
0.0635271
0.0244246
0.0381882
0.0332666
0.0715208
0.0470757
0.0313311
0.0477107
0.0344289
0.0253319
0.135479
0.0464734
0.0558142
0.0298011
0.140003
0.139993
0.0733508
0.0028551
0.0755242
0.126223
0.0451124
0.03982
0.0782251
0.031848
0.0562338
0.0545331
0.1704
0.00325429
0.039828
0.0266591
0.00953293
0.0322741
0.0451448
0.0738488
0.0360799
0.0366546
0.131237
0.102042
0.0374411
0.128148
0.0418605
0.140003
0.132418
0.0442312
0.0450675
0.0790482
0.0603818
0.0495436
0.033145
0.129067
0.0436836
0.0675383
0.123797
0.0428316
0.0616939
0.0350691
0.0414084
0.122228
0.0665633
0.12563
0.0419768
0.138487
0.138274
0.138219
0.0324138
0.0760075
0.140353
0.135299
0.136746
0.0379647
0.0236728
0.131807
0.0284715
0.169588
0.0483082
0.139979
0.102633
0.101394
0.127537
0.135987
0.0411175
0.0392751
0.0996594
0.0938117
0.0634519
0.0829559
0.128775
0.0383939
0.0498458
0.103661
0.0770593
0.0360141
0.127016
0.0949888
0.0721593
0.0300603
0.0569868
0.0372356
0.0248378
0.139078
0.0848306
0.0391329
0.0678794
0.0246994
0.035816
0.0323209
0.0262918
0.084892
0.0660534
0.05078
0.157329
0.135163
0.138153
0.0337096
0.0208441
0.0177212
0.063683
0.0674841
0.0907043
0.0641562
0.0299463
0.0592111
0.0589549
0.0286825
0.133885
0.0695234
0.0393039
0.0426368
0.0282091
0.0849063
0.0383759
0.0985863
0.130379
0.0519827
0.0057234
0.025521
0.0332566
0.0113853
0.0588071
0.0344689
0.124994
0.0619755
0.140013
0.038701
0.0400916
0.089083
0.373947
0.0902421
0.0511854
0.0347875
0.0257935
0.0715419
0.0885554
0.0351611
0.080159
0.0327923
0.0642806
0.033614
0.118861
0.115615
0.0316586
0.0842667
0.0154552
0.0372275
0.0238066
0.0335098
0.0453187
0.0386402
0.137937
0.0821404
0.0372891
0.0619706
0.0411879
0.0570836
0.0370197
0.0320359
0.0734012
0.0415992
0.0221221
0.135122
0.113967
0.0493985
0.0909925
0.0415895
0.0186327
0.0917651
0.132728
0.0858445
0.133499
0.0965282
0.110251
0.0925103
0.0492868
0.136063
0.120596
0.135008
0.122422
0.145474
0.070634
0.0423657
0.107138
0.0238152
0.0395658
0.0603062
0.0545603
0.033411
0.137613
0.0770107
0.00552958
0.135474
0.0363857
0.134787
0.00402304
0.069418
0.0760423
0.0337322
0.0733711
0.066164
0.0282928
0.0803013
0.0670628
0.0249834
0.128024
0.0312398
0.0486478
0.0290158
0.13869
0.134589
0.146394
0.0393372
0.137398
0.135801
0.212156
0.0692871
0.0357862
0.133398
0.149297
0.0392112
0.0382617
0.0475192
0.0463447
0.0406859
0.133352
0.0561026
0.0564611
0.050132
0.0245473
0.0550375
0.131143
0.138687
0.032549
0.137425
0.0642494
0.154646
0.133497
0.138493
0.125005
0.0354637
0.129431
0.0339437
0.124413
0.0728414
0.0373664
0.101318
0.0245803
0.136521
0.0991572
0.12623
0.132395
0.051522
0.0317963
0.0272795
0.0409707
0.107622
0.132536
0.048274
0.0379732
0.09228
0.136149
0.0319734
0.0828977
0.0326285
0.0273771
0.107699
0.139922
0.0445269
0.145154
0.0496921
0.0954033
0.0527246
0.0355677
0.0772246
0.0835211
0.302016
0.0660006
0.0387565
0.129836
0.0280954
0.0633674
0.0508266
0.135582
0.0812186
0.044528
0.0406485
0.13703
0.0624167
0.140972
0.0547922
0.0298111
0.0590447
0.0826886
0.0511724
0.137858
0.136968
0.125
0.0881506
0.0302192
0.0494647
0.0240995
0.0873738
0.134356
0.032163
0.0122942
0.137114
0.0277045
0.0253282
0.0317865
0.0367097
0.0763094
0.137411
0.0466516
0.0229619
0.138014
0.00615013
0.087106
0.072275
0.0995332
0.0336729
0.0346332
0.0680871
0.137544
0.136135
0.0651546
0.0473321
0.0836142
0.139207
0.0121213
0.0370495
0.0378689
0.121195
0.0303504
0.0902763
0.0206244
0.139095
0.0338364
0.0990461
0.0427901
0.0392088
0.0505742
0.0440941
0.152807
0.122793
0.0739696
0.0315806
0.0969032
0.13874
0.0320378
0.171204
0.136277
0.135694
0.0491099
0.0414318
0.137923
0.0457786
0.137875
0.06292
0.0367751
0.0226273
0.0466896
0.0669139
0.0384006
0.0765518
0.0909421
0.0601561
0.138792
0.0660217
0.0967542
0.0835505
0.0468939
0.0339215
0.0330251
0.0374311
0.0587851
0.0415237
0.110808
0.0422201
0.113366
0.0575684
0.0701412
0.131554
0.0721221
0.0746008
0.117155
0.025669
0.0906812
0.0589347
0.0755364
0.03486
0.113229
0.111882
0.00513669
0.0751658
0.134338
0.165246
0.0404976
0.0320271
0.0363516
0.0762662
0.0640745
0.0397248
0.129707
0.0260597
0.0212827
0.0733955
0.0598986
0.0390584
0.0253599
0.0426653
0.0308267
0.126266
0.0276094
0.136225
0.0673056
0.0214606
0.0296564
0.0635693
0.0442153
0.0714771
0.0621026
0.0560119
0.0332091
0.0672078
0.0485625
0.0253934
0.042877
0.133911
0.0375977
0.117593
0.135264
0.109274
0.0324003
0.133804
0.0455713
0.100488
0.0547273
0.125573
0.0727587
0.135144
0.0771526
0.03185
0.0754715
0.13979
0.0718327
0.0458436
0.0267307
0.0455968
0.0269813
0.0579537
0.0325901
0.110911
0.0597724
0.0821559
0.023466
0.0606112
0.0554062
0.0342449
0.0287714
0.12703
0.0516736
0.0650714
0.13963
0.034993
0.0230252
0.125621
0.0617718
0.0688939
0.0317551
0.0501857
0.0702653
0.08264
0.0348845
0.0547224
0.129436
0.129078
0.039587
0.0428227
0.0638319
0.0400972
0.0688113
0.0342416
0.0910526
0.0320311
0.137795
0.137864
0.131053
0.0338194
0.0030121
0.0257791
0.10751
0.0354936
0.0395013
0.0784203
0.138389
0.0393183
0.0969006
0.138138
0.0214889
0.116262
0.109461
0.0310368
0.137437
0.0128281
0.118452
0.0314822
0.099333
0.131267
0.0300207
0.138913
0.137399
0.0487023
0.0307448
0.0368726
0.138111
0.0626344
0.0830205
0.0399354
0.0348826
0.0352419
0.0742589
0.0503053
0.0339867
0.0663213
0.0301385
0.0727096
0.00134471
0.0867728
0.277457
0.139289
0.125923
0.0740132
0.0396107
0.0604887
0.116676
0.0504041
0.112279
0.0408157
0.0582476
0.131257
0.0633834
0.0923463
0.0586807
0.0712952
0.0626546
0.0556314
0.0530447
0.0346232
0.0296899
0.0308566
0.116513
0.347167
0.120261
0.0742387
0.0376265
0.176672
0.122978
0.0550505
0.0307185
0.0106996
0.0231334
0.0975595
0.137743
0.137087
0.137166
0.038703
0.0373916
0.0546516
0.0730642
0.082885
0.139613
0.0545781
0.103348
0.0604498
0.0900638
0.0327772
0.051296
0.113337
0.106169
0.0334578
0.0173225
0.0235333
0.0323809
0.0910052
0.0334563
0.0433985
0.0345446
0.423036
0.131269
0.0596172
0.0385827
0.0718476
0.138523
0.080588
0.0424369
0.034186
0.137975
0.0434478
0.0361619
0.0335929
0.0278399
0.0365805
0.136911
0.0293463
0.0353011
0.0546473
0.0334281
0.0181842
0.0238382
0.0754347
0.0915587
0.140055
0.113867
0.0304499
0.139099
0.0893179
0.0272549
0.0148452
0.0836746
0.0521866
0.0573706
0.0805535
0.0411833
0.0451282
0.0587873
0.00222309
0.0647246
0.0630863
0.0660923
0.0245959
0.0700895
0.051374
0.131262
0.0314237
0.0660526
0.11107
0.0947827
0.0366005
0.049927
0.00801935
0.0999601
0.121504
0.137034
0.0615845
0.00216198
0.050932
0.145588
0.0650081
0.0459766
0.138983
0.0321669
0.0610952
0.0996667
0.0346634
0.139263
0.137547
0.0727399
0.0291207
0.0170276
0.0353213
0.0977604
0.0799712
0.126242
0.0651268
0.0427332
0.0258579
0.0261966
0.064219
0.0371931
0.0396918
0.0535274
0.0343885
0.0214974
0.100526
0.0854283
0.0375034
0.0267479
0.0983902
0.108032
0.0723229
0.130047
0.137999
0.0228847
0.0431799
0.031077
0.102217
0.0676076
0.0308829
0.0506206
0.0687314
0.0641755
0.139474
0.133617
0.139658
0.0357989
0.0439782
0.0280424
0.0360675
0.0409092
0.0331106
0.0323236
0.010013
0.0697015
0.0612769
0.136332
0.030803
0.0407752
0.042033
0.025102
0.0304192
0.184603
0.139831
0.134305
0.0405615
0.0500678
0.0132967
0.0217689
0.0320598
0.0516032
0.0402982
0.0701497
0.0177092
0.0909992
0.135315
0.0357155
0.0700524
0.0314908
0.0385702
0.0502729
0.313327
0.122046
0.0659955
0.0144007
0.0282892
0.0336342
0.108961
0.123368
0.033101
0.108959
0.0408535
0.135736
0.0456622
0.0525233
0.0280575
0.0736045
0.136702
0.035512
0.0443649
0.11067
0.0880957
0.122336
0.0633034
0.0342439
0.135922
0.0873623
0.0432637
0.0923181
0.138119
0.0427383
0.0680644
0.139044
0.0382657
0.0553436
0.110125
0.030718
0.0799613
0.0301671
0.0329339
0.0381665
0.0830117
0.137041
0.0827758
0.122628
0.094175
0.03971
0.0367441
0.069703
0.139802
0.0956141
0.0429002
0.0259237
0.0573866
0.0316345
0.138842
0.0359714
0.0855836
0.00184368
0.0475842
0.138031
0.0686678
0.033127
0.101987
0.0343879
0.143742
0.0479191
0.0670735
0.04147
0.136085
0.0732099
0.110696
0.126758
0.0794811
0.0752402
0.0500114
0.0442434
0.070229
0.0354787
0.138682
0.0312965
0.139431
0.0856016
0.0429262
0.134539
0.0682353
0.108468
0.0936654
0.094714
0.10139
0.139919
0.0567097
0.110185
0.137211
0.11381
0.132559
0.00568362
0.0252517
0.0654984
0.038092
0.0742014
0.0365188
0.0432735
0.0391277
0.0752511
0.0525465
0.0378211
0.0832991
0.140004
0.0634284
0.0339327
0.122302
0.0591033
0.0317759
0.0297253
0.0471812
0.0326779
0.100666
0.0334872
0.0810459
0.0310441
0.0893122
0.103746
0.046748
0.138207
0.114332
0.0526111
0.0916782
0.0494263
0.0378531
0.101803
0.0723314
0.0516584
0.145666
0.0848392
0.0330881
0.0764212
0.0444006
0.00985624
0.082851
0.123462
0.12186
0.117892
0.0314138
0.0461575
0.0826573
0.026456
0.0402419
0.104997
0.0538571
0.039517
0.104668
0.0804564
0.358809
0.0973749
0.0220182
0.0232405
0.134355
0.0583231
0.0864212
0.0763942
0.0689991
0.0795695
0.138345
0.0112628
0.158796
0.048267
0.0370021
0.0325507
0.0420844
0.107713
0.0341269
0.0429865
0.0417849
0.039055
0.0244668
0.0785166
0.0515015
0.105957
0.0575776
0.116745
0.00400948
0.35449
0.084092
0.0313677
0.0106416
0.098278
0.080104
0.0747119
0.13874
0.108098
0.131631
0.032038
0.0957357
0.0528599
0.0364544
0.0490315
0.0550905
0.0510855
0.038464
0.0393142
0.126259
0.12928
0.0221501
0.0369977
0.123169
0.121482
0.134762
0.0456025
0.0462351
0.067413
0.0941083
0.0778235
0.0566484
0.055888
0.0508729
0.0453623
0.0303838
0.139884
0.138005
0.0718238
0.0623389
0.0316808
0.0902233
0.0886967
0.0445768
0.0421665
0.0378907
0.119141
0.0345449
0.0611714
0.136144
0.0493932
0.082453
0.0262751
0.00670521
0.0341834
0.0962786
0.0351353
0.0492697
0.0717972
0.00942685
0.0604021
0.102933
0.136515
0.13185
0.0617979
0.0120623
0.0322518
0.00999559
0.0832657
0.0787802
0.0341155
0.0461034
0.0403711
0.138838
0.120332
0.0402422
0.0362072
0.0752095
0.0381849
0.0652822
0.137455
0.0585174
0.0976804
0.103193
0.0569741
0.0554537
0.134696
0.0354789
0.0382505
0.0665936
0.0294521
0.00479319
0.0729302
0.0249864
0.0377355
0.103772
0.0228001
0.0257462
0.0329032
0.136006
0.0539374
0.0457901
0.0368116
0.060774
0.0218868
0.108135
0.13866
0.0276184
0.136605
0.0517156
0.0729015
0.0421155
0.0352103
0.0388159
0.106542
0.119513
0.0753561
0.0386108
0.0929959
0.0214103
0.138167
0.0538601
0.13521
0.0331113
0.0641162
0.14734
0.0790071
0.0427292
0.0761936
0.0148328
0.0326754
0.0240608
0.139313
0.0923759
0.0392285
0.08667
0.0463644
0.137202
0.0574236
0.0326571
0.0308144
0.0206238
0.0468316
0.07884
0.037397
0.00535056
0.104351
0.0413269
0.140172
0.0363135
0.0980731
0.0239621
0.0380473
0.139161
0.00987793
0.0273268
0.0620378
0.0312985
0.00800146
0.0523988
0.117893
0.00427885
0.138887
0.132612
0.0389646
0.0491645
0.0668259
0.128971
0.211293
0.130693
0.116044
0.0585567
0.124559
0.0388573
0.0994788
0.0278622
0.106639
0.0335151
0.0415135
0.0336561
0.0892158
0.127925
0.0410024
0.0350229
0.0333102
0.0751927
0.0776267
0.0919227
0.0894053
0.0301887
0.111294
0.139242
0.025895
0.107797
0.12041
0.140014
0.13956
0.0332862
0.00274958
0.0916701
0.137403
0.0441904
0.136819
0.072324
0.0171605
0.136838
0.0676031
0.109051
0.0667617
0.0283166
0.0447995
0.0176227
0.0363022
0.0236664
0.0357207
0.0724497
0.0294197
0.0271539
0.0526612
0.00865373
0.0323814
0.0937518
0.0917114
0.0755054
0.134707
0.0848077
0.075817
0.0370737
0.0426039
0.0391646
0.142407
0.0816473
0.0304839
0.0925111
0.111886
0.0334231
0.10994
0.122978
0.0290241
0.0324057
0.0387085
0.0361525
0.0287854
0.138748
0.0478061
0.0142505
0.139968
0.0326816
0.0447789
0.0912049
0.0394944
0.0739978
0.0555332
0.137903
0.102179
0.0345626
0.0633683
0.0580612
0.0461305
0.0322547
0.0914237
0.0325983
0.137566
0.110979
0.0389364
0.087784
0.090462
0.140004
0.0318536
0.0473183
0.190931
0.0541309
0.0320462
0.128119
0.0458112
0.046184
0.133635
0.13544
0.0341796
0.0353018
0.0469365
0.0485899
0.0345083
0.105592
0.0343704
0.0521858
0.136195
0.107926
0.0411389
0.0412377
0.0339137
0.111423
0.0339152
0.0668273
0.0914783
0.0653451
0.0433783
0.0289458
0.139701
0.0312089
0.0549679
0.0311125
0.135921
0.0908617
0.015316
0.0154341
0.0347661
0.136537
0.108489
0.0675151
0.0708694
0.0427171
0.0398974
0.0458356
0.0537503
0.115928
0.107307
0.0372025
0.0234304
0.0278375
0.0375082
0.0198734
0.0745473
0.138432
0.0360112
0.0541555
0.0243809
0.137597
0.0808037
0.0422559
0.0511236
0.0798538
0.0401621
0.0626619
0.0478711
0.00814586
0.341338
0.0656756
0.0706309
0.0394134
0.097491
0.139397
0.0788245
0.134989
0.0351104
0.13006
0.0300553
0.0963653
0.0189488
0.138637
0.0349472
0.0300601
0.0235189
0.0573252
0.060753
0.078552
0.139073
0.0743933
0.100874
0.0734772
0.0367538
0.0326242
0.139234
0.0474686
0.137731
0.0615192
0.0301503
0.0804485
0.08605
0.0372322
0.140396
0.0795571
0.0302468
0.0525795
0.0286509
0.135789
0.0553193
0.0724015
0.0331715
0.0435314
0.139636
0.059063
0.0976499
0.0185792
0.125319
0.0931263
0.0851957
0.0347276
0.0253035
0.0274814
0.00635334
0.0533512
0.0423439
0.118423
0.137649
0.029079
0.112866
0.0707655
0.130395
0.0970131
0.10746
0.138979
0.0334466
0.0465758
0.0403238
0.00258458
0.0629721
0.0977853
0.0724184
0.0664079
0.0804031
0.0342726
0.0284232
0.036156
0.0412052
0.0736189
0.0685626
0.0467922
0.108326
0.125144
0.0415646
0.108223
0.120434
0.102485
0.0258267
0.0324201
0.0662463
0.0309594
0.128981
0.0441175
0.0465483
0.0319495
0.133301
0.0557116
0.0324655
0.137567
0.0623865
0.133039
0.0461464
0.134814
0.120637
0.0350138
0.0699915
0.103911
0.138675
0.0723187
0.0327339
0.0331149
0.0628842
0.157347
0.0373507
0.137026
0.0153141
0.0270157
0.0333541
0.0423247
0.0775203
0.121731
0.088693
0.0447449
0.13432
0.0348394
0.0410137
0.113923
0.0746084
0.145059
0.033026
0.0349286
0.14001
0.0586515
0.0340875
0.0521366
0.0600063
0.0415233
0.0308541
0.137568
0.132555
0.0836036
0.0935108
0.0308067
0.0532549
0.0500576
0.0955259
0.0928453
0.0745043
0.0407511
0.0617257
0.0383386
0.0672798
0.120304
0.131051
0.0307165
0.0691769
0.0361479
0.0416963
0.0667096
0.0805184
0.127471
0.26071
0.0309984
0.0271629
0.0399186
0.0293711
0.0625476
0.0359483
0.100428
0.0291311
0.0607773
0.0715792
0.0584919
0.0258586
0.102785
0.135562
0.0444338
0.0338159
0.106873
0.030138
0.134355
0.0428295
0.0750293
0.13902
0.038183
0.136972
0.0582861
0.119625
0.030964
0.0284978
0.133571
0.00894131
0.0367158
0.0455499
0.08469
0.0631289
0.127153
0.124896
0.0339071
0.0368154
0.0366479
0.108559
0.0921612
0.0481569
0.0938789
0.0198475
0.303767
0.0746081
0.0409681
0.0602163
0.131063
0.0391557
0.128047
0.0395774
0.066135
0.0285295
0.128533
0.0348978
0.137082
0.0528626
0.0285602
0.0324382
0.0962284
0.110598
0.0206783
0.0152563
0.0432037
0.0661282
0.0324605
0.0869049
0.123678
0.0484404
0.0402707
0.0301514
0.122088
0.0446791
0.0137097
0.126392
0.0375134
0.0155511
0.0507046
0.0621588
0.0442111
0.0714514
0.0766913
0.0133887
0.0334515
0.00160272
0.138271
0.0585566
0.139758
0.0811789
0.0337823
0.0430669
0.138697
0.0376603
0.031897
0.035145
0.132153
0.119804
0.0448332
0.0654751
0.137281
0.0547259
0.132932
0.0605573
0.00726798
0.051622
0.0469638
0.13999
0.111894
0.135248
0.0295411
0.101883
0.0459657
0.0394701
0.0326829
0.0650426
0.0338971
0.0494655
0.139974
0.0372066
0.127921
0.0345372
0.0327089
0.031452
0.0608579
0.0352399
0.0858248
0.0779383
0.0564647
0.0535309
0.0873436
0.129573
0.0563927
0.0355433
0.0332806
0.0358418
0.0743143
0.0321712
0.0285018
0.0775058
0.0440373
0.0802017
0.036058
0.0477019
0.0991891
0.0424609
0.0873579
0.0439795
0.0423728
0.081077
0.138763
0.0384944
0.105018
0.0484208
0.0674231
0.0875561
0.134173
0.0378268
0.0600388
0.0408362
0.111142
0.0366275
0.0451196
0.0418262
0.0266181
0.0844698
0.139808
0.0722511
0.069311
0.033173
0.0553781
0.139959
0.0355997
0.0301915
0.0632809
0.0364858
0.0462055
0.0557117
0.0448415
0.157515
0.0720175
0.0643425
0.0602078
0.0379795
0.0423587
0.0299317
0.067298
0.031804
0.0283907
0.0361588
0.0286704
0.117235
0.0584631
0.0930742
0.0522735
0.0336644
0.0524141
0.0286935
0.0350413
0.0949802
0.110125
0.0954209
0.0548455
0.0349184
0.0212364
0.0514586
0.0354107
0.0504649
0.0751705
0.180884
0.0251698
0.0579229
0.0535439
0.0311151
0.0519743
0.0327387
0.0307197
0.139177
0.0546436
0.111106
0.0444407
0.0313424
0.0796362
0.0358365
0.035907
0.050172
0.139798
0.06821
0.0923777
0.0354225
0.0869903
0.0612423
0.135017
0.0519095
0.128721
0.0245636
0.13496
0.058626
0.026717
0.0278876
0.040967
0.0480842
0.0673443
0.0988181
0.123883
0.13671
0.0860046
0.0506908
0.0575726
0.0348507
0.0957276
0.0753314
0.0286901
0.0408558
0.139466
0.0305474
0.0688805
0.389174
0.0349835
0.139776
0.139567
0.0467975
0.0365238
0.118147
0.0407084
0.0211291
0.129466
0.0358358
0.0419103
0.0479238
0.0665541
0.0437953
0.137776
0.0375709
0.0259945
0.0366463
0.0465756
0.135323
0.0606305
0.00883489
0.0172905
0.0337065
0.0827875
0.0832463
0.0650703
0.0341506
0.0473901
0.130467
0.0654944
0.139055
0.135175
0.00540062
0.0460282
0.105214
0.0474083
0.0785378
0.0350048
0.13952
0.104738
0.0359296
0.0368174
0.0540144
0.0214444
0.0562651
0.0288776
0.0317485
0.0375787
0.0298641
0.02987
0.044271
0.0312852
0.0414086
0.020441
0.030473
0.132024
0.0695945
0.0465931
0.0938216
0.035123
0.118173
0.138768
0.0793137
0.0105926
0.0754259
0.0370161
0.0408179
0.0326618
0.038751
0.0740608
0.0893627
0.0381656
0.0297303
0.1389
0.0222896
0.0556494
0.037495
0.113512
0.185409
0.139806
0.0568619
0.051903
0.0282597
0.0773517
0.130464
0.0243807
0.105058
0.0524343
0.0536808
0.0273114
0.0366099
0.0599961
0.132728
0.0443133
0.0501606
0.023247
0.0221384
0.0399328
0.0526233
0.0301103
0.0268988
0.0385308
0.301613
0.0690982
0.0558465
0.183643
0.0393626
0.0338119
0.137612
0.0790155
0.0328108
0.0545873
0.0450418
0.138473
0.0345953
0.0341908
0.06895
0.21607
0.0370118
0.0243117
0.0785055
0.0631726
0.138818
0.0524886
0.0655661
0.121191
0.101975
0.11283
0.0398371
0.0312512
0.0812433
0.140054
0.0336242
0.0301995
0.11398
0.0553859
0.0323819
0.108425
0.11422
0.153988
0.0619093
0.0374206
0.0408701
0.138999
0.0356788
0.0879263
0.0362375
0.0333831
0.0429589
0.0431976
0.0534786
0.00409319
0.0243548
0.0357465
0.13456
0.0420231
0.135657
0.0352938
0.0973218
0.0318057
0.0270637
0.0358421
0.0689789
0.0237375
0.0853279
0.0315188
0.0910406
0.0365165
0.0450162
0.128011
0.132268
0.135671
0.055904
0.0349308
0.0771653
0.0351523
0.0453838
0.0264955
0.03048
0.0330037
0.0365361
0.0387031
0.038697
0.120017
0.127756
0.0295662
0.0927211
0.0460685
0.0427071
0.0767524
0.0586135
0.126605
0.0398017
0.0292651
0.0549368
0.138052
0.125581
0.0330857
0.019106
0.0398839
0.0323368
0.0830246
0.0839541
0.0414399
0.0412705
0.0384773
0.120651
0.0951785
0.0342016
0.0946648
0.127362
0.0794427
0.108372
0.0760613
0.137843
0.0331161
0.0264842
0.0299428
0.0419802
0.0902837
0.0551252
0.0936982
0.0518492
0.107387
0.0395288
0.078654
0.0851914
0.0556861
0.0276175
0.0578477
0.0341052
0.0627517
0.0247665
0.0928522
0.0713684
0.138596
0.0278628
0.139637
0.0430332
0.0206717
0.0438976
0.0370695
0.0209559
0.111017
0.0370795
0.0577638
0.0393294
0.0323469
0.04434
0.0725611
0.0714179
0.0400803
0.0302895
0.0468885
0.0382111
0.131509
0.0322477
0.0511331
0.0599085
0.0236712
0.094744
0.136586
0.0337806
0.0504227
0.132043
0.00750161
0.04248
0.0493695
0.0720542
0.0638193
0.0441192
0.0585596
0.0381641
0.0339942
0.0352639
0.0493051
0.0414177
0.0159555
0.0521725
0.0281037
0.0390232
0.123722
0.0386666
0.0677646
0.0366452
0.0555463
0.137913
0.0548457
0.0293882
0.0610702
0.0480397
0.139929
0.0373835
0.0825178
0.0560131
0.110769
0.113304
0.0385018
0.0440611
0.0348654
0.183557
0.0465151
0.0532835
0.0855236
0.0798396
0.0309858
0.103312
0.0309808
0.0436522
0.0295271
0.118173
0.039526
0.156861
0.14115
0.0410365
0.0372798
0.131272
0.0628512
0.0363796
0.0539867
0.0289672
0.0233456
0.0397071
0.03868
0.355548
0.0456633
0.0450274
0.0535347
0.139464
0.0488107
0.0205775
0.0545221
0.040638
0.139912
0.0747398
0.0729287
0.0454386
0.131355
0.0444479
0.123736
0.0552174
0.0377984
0.0873238
0.0298032
0.0689092
0.00343136
0.0925959
0.0917394
0.0332497
0.0686104
0.0334994
0.139147
0.0823455
0.047883
0.034056
0.0528797
0.0162769
0.0462302
0.0551932
0.0673255
0.13943
0.104313
0.0835999
0.0251128
0.0345933
0.0325292
0.0864107
0.113838
0.0996784
0.0296763
0.139324
0.137561
0.0655679
0.1353
0.0301851
0.102695
0.0411969
0.140018
0.137098
0.0343224
0.139421
0.145313
0.0398904
0.0793892
0.0829643
0.0281835
0.0573332
0.0227093
0.0679675
0.0376097
0.0609184
0.134181
0.0447739
0.105141
0.036946
0.180844
0.0590759
0.138586
0.0353527
0.0369222
0.163317
0.0370568
0.0981873
0.0520402
0.134991
0.0298808
0.115163
0.0354524
0.033356
0.0480397
0.0352022
0.034089
0.0764849
0.0707791
0.0472877
0.102682
0.114218
0.0604118
0.0520682
0.111686
0.0562633
0.114499
0.0566127
0.0500939
0.0226373
0.0415328
0.0256196
0.0337698
0.134606
0.0359554
0.106514
0.135875
0.0508246
0.040446
0.033497
0.0387542
0.0403817
0.0986676
0.137703
0.0894449
0.0294601
0.0356719
0.0352914
0.03617
0.0591479
0.0383142
0.032835
0.00229806
0.0646816
0.0312711
0.110197
0.0968586
0.0297961
0.0500756
0.0423576
0.0690781
0.0415987
0.13341
0.0329262
0.0741849
0.0340765
0.0724846
0.139127
0.037526
0.0312067
0.0682234
0.0306248
0.0343501
0.0436742
0.0776509
0.087583
0.0299663
0.0434744
0.134567
0.0354411
0.0875562
0.0770429
0.0927483
0.040097
0.11755
0.137833
0.139947
0.0376616
0.064576
0.0943877
0.0629593
0.0488303
0.0960245
0.0332773
0.0704304
0.0284019
0.0280281
0.067601
0.0345341
0.0407796
0.023005
0.138556
0.0469054
0.0358144
0.0349419
0.117544
0.0347009
0.0715514
0.074721
0.0360784
0.0695294
0.138595
0.0704558
0.0591791
0.133465
0.0436165
0.0987494
0.0831937
0.0405261
0.0316227
0.0244649
0.134908
0.11568
0.0471153
0.130214
0.0366853
0.0776037
0.0428693
0.030019
0.0224141
0.0595429
0.0482731
0.0313372
0.100063
0.138285
0.0433962
0.139277
0.0357963
0.038698
0.0923851
0.0497615
0.0859436
0.0402771
0.0339614
0.138111
0.0233025
0.0227398
0.0190602
0.0773496
0.069388
0.0254582
0.0349586
0.0408862
0.0227083
0.0539097
0.0324088
0.0404954
0.0740219
0.0315012
0.0321563
0.029869
0.142114
0.138257
0.0385319
0.144213
0.137899
0.0414266
0.134887
0.0255192
0.10751
0.0892784
0.0359241
0.0300782
0.113543
0.0305939
0.0341441
0.116262
0.129994
0.304148
0.0270322
0.0435224
0.0333155
0.0493817
0.0351569
0.124659
0.0591898
0.0385543
0.0363065
0.0476495
0.0301036
0.0239538
0.0960389
0.0262732
0.0302245
0.0497232
0.0368245
0.0587633
0.0610922
0.053617
0.014534
0.0542275
0.030507
0.121746
0.0859709
0.0546832
0.0500788
0.0483527
0.0290385
0.0288598
0.0245815
0.112265
0.0629912
0.0640194
0.122663
0.0421487
0.0483944
0.109975
0.0488355
0.0523773
0.0396197
0.0361079
0.137528
0.116433
0.0824109
0.0264607
0.0284399
0.0470848
0.102457
0.0516363
0.0321249
0.135609
0.0376377
0.00507317
0.0653448
0.0620703
0.0433197
0.134132
0.0310467
0.0996446
0.0386886
0.0721863
0.0369363
0.0790881
0.0710913
0.0583181
0.0636978
0.0349788
0.109294
0.0872412
0.398126
0.0306546
0.0359868
0.0403762
0.132158
0.122805
0.0941512
0.0738277
0.0711485
0.0430533
0.112653
0.0956161
0.104982
0.0328482
0.138596
0.0396623
0.00784111
0.0661398
0.0166782
0.0359237
0.0984194
0.0471913
0.138457
0.0409442
0.0430787
0.299508
0.139209
0.0466298
0.136524
0.0342341
0.0968069
0.0305373
0.0220106
0.0460515
0.0352629
0.0526274
0.139537
0.0365104
0.0280898
0.0349321
0.0686098
0.0216842
0.0845326
0.0041083
0.0325346
0.0579233
0.0545368
0.0367071
0.0656092
0.137828
0.138507
0.135737
0.043093
0.00762444
0.0633899
0.05801
0.11437
0.0478879
0.10785
0.0300964
0.0720507
0.13415
0.0393686
0.11693
0.0398779
0.0981059
0.0626195
0.0522705
0.0893607
0.138863
0.0728228
0.0628923
0.139708
0.0292426
0.0251879
0.0240885
0.0998084
0.0339703
0.029477
0.039898
0.138945
0.0607601
0.11948
0.0423766
0.0346838
0.135006
0.0564268
0.0724818
0.0327418
0.0936705
0.0954624
0.0339298
0.0394119
0.137068
0.136048
0.00359374
0.0327243
0.0311313
0.032485
0.02773
0.047278
0.0380458
0.0484765
0.0869351
0.139018
0.0543283
0.0410453
0.0311801
0.0598599
0.0395935
0.0559308
0.132514
0.0852055
0.104461
0.0343328
0.102507
0.0970601
0.0372119
0.0892599
0.0417812
0.0515229
0.0381039
0.0520905
0.138309
0.0342922
0.0491784
0.13839
0.044311
0.160836
0.0407595
0.028124
0.125272
0.0325566
0.13836
0.0189971
0.0752839
0.0423984
0.0582746
0.040321
0.135734
0.133361
0.0819742
0.134259
0.0318671
0.0520152
0.137652
0.0975317
0.034085
0.0431527
0.0928341
0.138247
0.137873
0.136521
0.118404
0.0353344
0.0292483
0.114632
0.00393605
0.103784
0.0390923
0.0635707
0.0563186
0.135043
0.0531511
0.0283775
0.0143361
0.109974
0.0939177
0.0942603
0.0201853
0.0694445
0.0360903
0.0720777
0.0767426
0.0351947
0.0362844
0.0751255
0.0712934
0.0666767
0.0350124
0.233155
0.0372644
0.115636
0.138538
0.0355725
0.0939016
0.136535
0.027008
0.0518541
0.0367937
0.0471414
0.112409
0.0250583
0.0568445
0.0323233
0.0460742
0.0355387
0.0670135
0.0902537
0.111598
0.0999546
0.0391803
0.0294397
0.0791056
0.0586751
0.00495882
0.0338281
0.118034
0.139051
0.0813148
0.0603238
0.0510746
0.052373
0.13688
0.0734825
0.0439366
0.123886
0.106804
0.0396401
0.0295295
0.0992179
0.0335932
0.0366229
0.137797
0.0469162
0.0779834
0.0344298
0.133607
0.0440675
0.0207595
0.132873
0.0396491
0.0194703
0.0461525
0.116547
0.0507035
0.0376699
0.0296782
0.0332622
0.0384968
0.100484
0.0375193
0.0446099
0.0422102
0.0432522
0.135441
0.0026118
0.118953
0.0348761
0.0839594
0.138353
0.11977
0.134356
0.119687
0.032794
0.117415
0.136462
0.0545019
0.132806
0.0329309
0.0751239
0.0639715
0.050819
0.0371519
0.106677
0.055361
0.0741053
0.0574731
0.129955
0.0428581
0.118782
0.0313421
0.134394
0.0313669
0.0810764
0.0722585
0.0276967
0.0396804
0.0568726
0.0348713
0.0707229
0.058831
0.0575237
0.0799012
0.0942022
0.0274174
0.0310703
0.104268
0.0690872
0.0402047
0.0285493
0.0346061
0.137276
0.0424977
0.0907241
0.0309454
0.0793625
0.0557749
0.137717
0.0467923
0.13704
0.0752758
0.032657
0.0751851
0.124998
0.101087
0.0319709
0.116964
0.0293692
0.0391817
0.0353436
0.0353462
0.134701
0.0836764
0.0504695
0.138909
0.0724006
0.0680919
0.0561248
0.0542507
0.136695
0.0308045
0.394325
0.129335
0.139944
0.129097
0.0753352
0.0869832
0.308307
0.139443
0.0374962
0.0336413
0.0351561
0.0329578
0.029499
0.0356784
0.0339716
0.0305549
0.039436
0.122496
0.0336113
0.0875426
0.0506038
0.0737101
0.0222085
0.00463576
0.13972
0.0429008
0.135889
0.0298679
0.30057
0.0436459
0.048853
0.12544
0.0162774
0.0931843
0.0322664
0.0443955
0.136581
0.0475686
0.0479607
0.0851693
0.0385162
0.029311
0.00466342
0.138459
0.0597603
0.0234055
0.0320216
0.030816
0.0359034
0.139985
0.0376934
0.0895123
0.135308
0.0861526
0.0373777
0.0549497
0.0768085
0.100527
0.0421943
0.0435084
0.0561131
0.131238
0.0255586
0.00454725
0.0672771
0.138543
0.0253
0.336981
0.0389487
0.105696
0.0345659
0.0221168
0.038654
0.0375096
0.0636346
0.0391947
0.135495
0.13838
0.0129771
0.136505
0.0334426
0.0442088
0.0717349
0.0768077
0.11296
0.0710657
0.0400345
0.128401
0.115894
0.0368189
0.0318555
0.137675
0.0299357
0.139544
0.0307236
0.0624635
0.024162
0.0349072
0.0582757
0.0285588
0.0543319
0.0737777
0.0307283
0.0623489
0.054201
0.0243088
0.135036
0.119738
0.0505597
0.0793529
0.00368244
0.0310701
0.0280072
0.0956109
0.053995
0.025487
0.102207
0.07692
0.0500933
0.0366521
0.139591
0.0349262
0.0674465
0.0375408
0.0348362
0.0320587
0.0355172
0.0669718
0.0334066
0.139428
0.19031
0.0599787
0.0500628
0.0607863
0.0262047
0.113143
0.135219
0.0291831
0.0330302
0.0504042
0.0384691
0.139673
0.140003
0.036936
0.0277376
0.0376886
0.0508489
0.0260683
0.0688506
0.139861
0.038709
0.0230215
0.0498486
0.0478174
0.0352512
0.0891189
0.0589078
0.136011
0.0889532
0.0275663
0.13034
0.0857506
0.0377495
0.0403493
0.0483122
0.0352903
0.130348
0.0257259
0.0282226
0.0909459
0.00988082
0.139478
0.08585
0.029148
0.110112
0.0396639
0.0113476
0.0617612
0.0958287
0.0829582
0.0820905
0.138487
0.037776
0.0401214
0.114803
0.0278966
0.0429154
0.103132
0.038905
0.085678
0.0307177
0.120299
0.0538229
0.0463869
0.0657566
0.138062
0.020641
0.0619963
0.0387565
0.0547191
0.0119594
0.0298122
0.0728338
0.0333753
0.0350162
0.0488313
0.100075
0.0619742
0.0748712
0.0564259
0.13888
0.132543
0.101836
0.0614489
0.0761704
0.0552853
0.0628695
0.0360128
0.0787579
0.0560517
0.133509
0.0562698
0.0526162
0.041644
0.0101975
0.131916
0.0286081
0.0331709
0.028938
0.0299972
0.0198549
0.0202579
0.0595368
0.035015
0.0371558
0.0795075
0.137423
0.0500371
0.0614207
0.352951
0.112385
0.00147312
0.139144
0.0478231
0.0621974
0.0323446
0.0477345
0.102964
0.129425
0.0329062
0.0143607
0.038208
0.0850126
0.0262682
0.139772
0.047622
0.0359524
0.0309606
0.0465815
0.0401707
0.0227219
0.0153758
0.0947864
0.0219487
0.0614404
0.0308085
0.139205
0.0741105
0.025449
0.138033
0.0294025
0.0235906
0.0373833
0.0834217
0.0354106
0.0502334
0.0301797
0.0383424
0.038567
0.122414
0.0438343
0.026326
0.0371333
0.0452109
0.139316
0.0271118
0.129966
0.0214584
0.0284585
0.033162
0.076776
0.0459178
0.135099
0.0760619
0.088283
0.0879282
0.116342
0.0279227
0.121369
0.0265117
0.0419432
0.0229684
0.0819955
0.134062
0.0925748
0.139772
0.0618521
0.0458267
0.044908
0.0818987
0.128124
0.0363014
0.0414821
0.0710266
0.056826
0.0317499
0.0729142
0.139999
0.0848938
0.131989
0.0352951
0.0215491
0.0362795
0.0758553
0.0289912
0.0293586
0.0428871
0.13622
0.0815353
0.0860316
0.0853011
0.121943
0.0357497
0.124703
0.0535521
0.0444596
0.068661
0.0499484
0.0829782
0.128063
0.0911986
0.0746027
0.0457924
0.069064
0.136275
0.0715172
0.0575134
0.0245223
0.0357143
0.137015
0.0282215
0.0311951
0.033291
0.031385
0.024075
0.0329228
0.0407727
0.0758428
0.0973144
0.0569761
0.0236771
0.0496538
0.0606449
0.0358896
0.0518089
0.0835014
0.0297903
0.113412
0.0493035
0.0235287
0.066029
0.0229094
0.0663275
0.0653933
0.13628
0.0769291
0.0352456
0.142265
0.0453847
0.138455
0.00489025
0.139414
0.0421233
0.0316053
0.138952
0.0767134
0.0331291
0.0336662
0.139477
0.0341315
0.0367271
0.0498774
0.0319147
0.135567
0.0481146
0.0330523
0.0255148
0.0390613
0.0303377
0.134438
0.129781
0.0379797
0.142331
0.0344905
0.111096
0.00708608
0.139073
0.0395473
0.032058
0.00486317
0.0298162
0.13639
0.0355987
0.0823115
0.00896928
0.0961871
0.027476
0.116448
0.139987
0.00225286
0.0671134
0.0718671
0.103753
0.0455899
0.0354383
0.0754906
0.0701411
0.0411577
0.0551805
0.0290638
0.0806766
0.0329429
0.0884056
0.0336493
0.0613407
0.0312529
0.140017
0.0410869
0.049912
0.0506154
0.0420167
0.0416443
0.0633488
0.0916374
0.0419072
0.104926
0.0896504
0.0249929
0.10927
0.0253623
0.100647
0.0317107
0.0431508
0.270112
0.0772604
0.0292814
0.0260991
0.0488183
0.160143
0.0078107
0.0688707
0.0479793
0.0348636
0.0361404
0.0297419
0.0301401
0.0341998
0.090561
0.0432313
0.0285418
0.108053
0.13829
0.0854009
0.0116618
0.030783
0.0400664
0.0780446
0.0547678
0.124165
0.0310781
0.122307
0.0727956
0.0722159
0.0292249
0.0147926
0.0342429
0.0302956
0.111974
0.0415229
0.140006
0.0128222
0.0392185
0.030198
0.139398
0.0334146
0.0733461
0.135738
0.0411615
0.0725526
0.041641
0.0287204
0.034206
0.0221403
0.0456755
0.117446
0.139836
0.0277173
0.0225692
0.0607853
0.0930664
0.0304312
0.0035288
0.0480257
0.0796283
0.048818
0.0338965
0.042804
0.033273
0.0440029
0.00201843
0.06964
0.0477547
0.0371122
0.077753
0.0570431
0.00467306
0.0572252
0.00426962
0.131408
0.0488923
0.138819
0.0505607
0.0202113
0.0557321
0.0544891
0.0813106
0.0324607
0.0648318
0.0564223
0.0875834
0.0367051
0.0268436
0.122825
0.0356049
0.002483
0.0514454
0.137972
0.0299628
0.0602672
0.0443126
0.0347259
0.0463669
0.0655748
0.0345468
0.0197751
0.0445241
0.098667
0.135533
0.222298
0.0486591
0.00729107
0.0446303
0.0333423
0.0219347
0.0319455
0.0275964
0.034354
0.0359731
0.0797135
0.0488752
0.110712
0.0237909
0.0742393
0.0402136
0.141413
0.0353531
0.0383872
0.0268024
0.0323745
0.0149533
0.0407841
0.00857227
0.0840869
0.127102
0.0317386
0.0817637
0.045031
0.114336
0.0834707
0.0174987
0.0579203
0.0568894
0.280872
0.13897
0.036051
0.0364181
0.138
0.0450492
0.0282351
0.0342528
0.009277
0.0422767
0.0837743
0.137391
0.0359977
0.00741137
0.0588976
0.00860165
0.0653556
0.115156
0.0305665
0.136693
0.0659545
0.0999075
0.0368517
0.0623094
0.0396674
0.0609818
0.0601818
0.0142007
0.0712098
0.0376693
0.0451413
0.037089
0.0732259
0.028313
0.0270208
0.0479345
0.136742
0.0325856
0.0840565
0.0742667
0.0373987
0.142366
0.0736536
0.023101
0.125943
0.0385162
0.126381
0.0622494
0.0531518
0.0320015
0.136881
0.134022
0.0322094
0.021062
0.138254
0.0123976
0.0816267
0.134433
0.025809
0.0321324
0.0469311
0.139433
0.0690433
0.131927
0.0285987
0.0348057
0.0513066
0.0482862
0.101759
0.175807
0.139843
0.0258933
0.0331846
0.0669112
0.0213288
0.0673299
0.149277
0.0130891
0.0424291
0.131183
0.035435
0.0842871
0.0976042
0.0209134
0.13803
0.0337922
0.0496743
0.00729636
0.0330759
0.0619249
0.0623789
0.138208
0.0892254
0.021121
0.106758
0.0567308
0.0575569
0.0323224
0.0557601
0.0276676
0.0398528
0.0264186
0.0973061
0.0543245
0.136076
0.0287487
0.0826296
0.0273746
0.12952
0.0355676
0.00122271
0.0387846
0.0014522
0.139084
0.133201
0.136647
0.0585254
0.0393617
0.123196
0.0546111
0.00201965
0.023317
0.131602
0.130562
0.0304208
0.15031
0.0752033
0.035463
0.109327
0.0789365
0.0348592
0.0553661
0.0514731
0.104791
0.111589
0.0576844
0.0702509
0.138833
0.00244575
0.0406801
0.0975155
0.0502787
0.13781
0.0231856
0.055299
0.026318
0.0399137
0.0810855
0.0262791
0.0399883
0.0403499
0.100446
0.0360822
0.0393969
0.0715773
0.137331
0.155954
0.139734
0.0745976
0.0317438
0.0407971
0.0414896
0.0590384
0.0360821
0.0526502
0.13682
0.0293759
0.135762
0.133988
0.0607266
0.137185
0.0895406
0.028137
0.0393489
0.117114
0.116711
0.0892308
0.0334254
0.0402826
0.139011
0.10928
0.0226604
0.0344663
0.19284
0.0281335
0.0379169
0.138561
0.0349558
0.0445484
0.0423731
0.0729057
0.00354025
0.0317757
0.0493482
0.097618
0.047372
0.0754443
0.0284597
0.129523
0.0621715
0.0490359
0.0361484
0.0606043
0.0738653
0.128342
0.0515477
0.0345397
0.0343018
0.0476748
0.0681387
0.0850455
0.0774296
0.0626171
0.0393698
0.138103
0.05811
0.0593303
0.00473717
0.0519623
0.117268
0.031831
0.032537
0.0316919
0.031344
0.0309512
0.0500192
0.0251795
0.0460415
0.0300043
0.108075
0.128613
0.0439884
0.101856
0.0364881
0.0918368
0.0817391
0.0390399
0.0420922
0.144241
0.047266
0.0309785
0.0379794
0.0763553
0.0508267
0.0368122
0.0151113
0.0318165
0.136554
0.0939696
0.0782988
0.0292766
0.0607352
0.136215
0.0356195
0.0360425
0.139863
0.0547
0.00664778
0.0529983
0.0388338
0.0329367
0.0359333
0.0482543
0.077726
0.0762632
0.136874
0.065873
0.0360117
0.0434968
0.0467999
0.0318346
0.0216827
0.0381417
0.0656077
0.112017
0.0230469
0.0734153
0.0300172
0.029218
0.0232464
0.038866
0.0422003
0.0832091
0.0631426
0.0406829
0.13414
0.0378389
0.0251654
0.0205878
0.128523
0.0444096
0.0471295
0.116327
0.0290752
0.0726147
0.0334349
0.115642
0.0443815
0.243381
0.112599
0.0701996
0.0104004
0.0115303
0.0785818
0.0702788
0.0345825
0.0350877
0.0326539
0.0678249
0.0990569
0.0553301
0.275355
0.132621
0.0621146
0.0435799
0.0290825
0.0290191
0.0280283
0.0824244
0.0240978
0.00158628
0.0375087
0.0421217
0.0474956
0.0389743
0.0934097
0.035084
0.139277
0.0428715
0.116843
0.0536312
0.0408703
0.1057
0.0198726
0.036339
0.03566
0.0550113
0.0319208
0.0351333
0.0681188
0.0253301
0.0684015
0.0673132
0.135818
0.0369708
0.0477637
0.139092
0.0476735
0.0324204
0.0475856
0.0365356
0.0439796
0.137937
0.0589392
0.0110124
0.109403
0.0303537
0.0425325
0.0396166
0.0302049
0.101699
0.147973
0.0836541
0.0308278
0.0702524
0.0448422
0.138004
0.0365587
0.102526
0.0778149
0.029225
0.140016
0.0390585
0.0292733
0.045317
0.0395432
0.139328
0.13464
0.106026
0.0707594
0.0269455
0.135727
0.0611828
0.108154
0.0692653
0.127035
0.0337239
0.136742
0.124805
0.0247609
0.0493852
0.130615
0.036331
0.041529
0.00288576
0.032048
0.0928942
0.0412207
0.0530552
0.0531041
0.0358956
0.0389785
0.0321503
0.0393708
0.0328791
0.0344122
0.0286383
0.128216
0.0328168
0.0348254
0.0327008
0.0896413
0.0291321
0.0894194
0.039986
0.0163818
0.0302003
0.0113703
0.0532206
0.132624
0.0686148
0.0298162
0.0639297
0.0788509
0.037543
0.028334
0.00161263
0.0220123
0.0369423
0.0482736
0.140019
0.135054
0.0388024
0.0491425
0.0315798
0.0459059
0.133753
0.0999175
0.132169
0.0639627
0.028225
0.0315726
0.0328408
0.00178406
0.137271
0.054281
0.0583616
0.0990298
0.0659264
0.0319026
0.0550356
0.0767908
0.139693
0.140018
0.0325113
0.0662731
0.0529087
0.109887
0.00309987
0.139423
0.0626016
0.0227482
0.134501
0.0495655
0.0353519
0.0524487
0.0808471
0.137094
0.0850568
0.0855101
0.033655
0.0395231
0.0712078
0.0961771
0.0640374
0.0522153
0.0549685
0.136684
0.11579
0.0350319
0.0866877
0.0372045
0.0378997
0.105698
0.0542817
0.0933153
0.0557171
0.135685
0.0292751
0.133749
0.20645
0.0516081
0.0230204
0.139476
0.0477107
0.0762212
0.0687941
0.0627751
0.0367558
0.0239283
0.0721676
0.021015
0.035495
0.0670208
0.0963793
0.11946
0.0348608
0.119963
0.138745
0.0205565
0.0315349
0.0243275
0.136907
0.0447238
0.136842
0.0656042
0.0352217
0.0118931
0.0509784
0.0354592
0.0327541
0.0364589
0.0447141
0.0298922
0.0312332
0.127384
0.0295186
0.0340389
0.0334502
0.113104
0.0250592
0.138741
0.0497615
0.0917952
0.0604469
0.0797701
0.0587918
0.0133511
0.0635485
0.0281334
0.121246
0.0306958
0.0606536
0.123255
0.0359091
0.0301113
0.0562484
0.0479146
0.212258
0.0244231
0.064081
0.0555664
0.125266
0.025516
0.05264
0.0398586
0.120162
0.0355374
0.132712
0.0524301
0.123144
0.137232
0.0896987
0.0252798
0.125032
0.0347063
0.0368572
0.0529012
0.138178
0.0500538
0.0979101
0.30731
0.0450561
0.0356077
0.0363271
0.138055
0.139197
0.0734747
0.104969
0.0348823
0.0636079
0.121773
0.0572336
0.00625756
0.0410345
0.137815
0.0460102
0.0413082
0.367332
0.0364799
0.0532597
0.033726
0.0458985
0.0352129
0.0901371
0.0316943
0.0456099
0.0529634
0.0579996
0.0273672
0.115899
0.0877416
0.0566815
0.0151629
0.125327
0.0330642
0.0430143
0.030927
0.0779981
0.128007
0.0700437
0.065581
0.0819626
0.0754336
0.0968373
0.0914302
0.0178737
0.077551
0.0410847
0.0361949
0.138802
0.0727898
0.0319827
0.0784981
0.0338062
0.136893
0.0508502
0.0405865
0.0321438
0.0429906
0.0309909
0.0480595
0.101017
0.128741
0.138074
0.0483051
0.0524532
0.0619351
0.053741
0.0669742
0.0437775
0.141297
0.0937121
0.0402369
0.0291558
0.0222631
0.0716843
0.0278488
0.0301598
0.0493976
0.0336953
0.0563011
0.0247937
0.0565468
0.0485456
0.0290903
0.136385
0.0719163
0.0657261
0.0661135
0.0276733
0.0590236
0.0352553
0.0365571
0.137267
0.0260004
0.112142
0.0372697
0.037487
0.0334697
0.0235846
0.0374164
0.0751028
0.0315481
0.0662928
0.0569698
0.0357276
0.036062
0.131742
0.0119838
0.0638225
0.138001
0.0334738
0.0553227
0.0675421
0.0649713
0.0655816
0.0273127
0.0511357
0.0315283
0.0663556
0.0346136
0.0593047
0.0388754
0.0749088
0.0714341
0.062017
0.0987076
0.119933
0.136469
0.0355169
0.0522755
0.055602
0.0324513
0.00416704
0.0634582
0.0337536
0.0457788
0.0183538
0.0508169
0.0370494
0.0278249
0.0415259
0.0577776
0.039321
0.0431151
0.0318038
0.0638362
0.074846
0.00460227
0.0394816
0.0392551
0.0382346
0.114723
0.0384297
0.0742734
0.0510769
0.107463
0.101837
0.0611018
0.0339563
0.0989776
0.0777097
0.0249804
0.0377095
0.0712153
0.100828
0.034784
0.0340419
0.0690626
0.029515
0.0981251
0.0502703
0.034246
0.111772
0.0457671
0.0177694
0.0331756
0.118033
0.0350406
0.0656521
0.0446414
0.00457908
0.0373648
0.114952
0.0398091
0.11299
0.113203
0.0121265
0.0747104
0.0436496
0.0592347
0.0334836
0.0987013
0.0709667
0.122283
0.035212
0.0477914
0.0399036
0.0815736
0.0120878
0.0489885
0.0295009
0.0730043
0.0444695
0.139341
0.00971815
0.0348018
0.032171
0.138817
0.0208458
0.0755408
0.0518162
0.134218
0.139946
0.0761104
0.0488532
0.0134049
0.0480958
0.125815
0.0365002
0.0446985
0.139715
0.0671073
0.0338316
0.0568916
0.0405573
0.061733
0.0613885
0.118278
0.0610519
0.0750561
0.0557993
0.0597756
0.0517751
0.0308731
0.0347095
0.135972
0.0546573
0.00281422
0.0386729
0.0251775
0.0546052
0.0144573
0.0607976
0.0809301
0.0931266
0.0401036
0.0723494
0.0830883
0.06047
0.0811889
0.0669414
0.0335712
0.110168
0.0722846
0.1378
0.0335105
0.139705
0.135327
0.0344412
0.0663787
0.0512693
0.0890877
0.0560091
0.0677196
0.0299111
0.0392961
0.137161
0.0936056
0.0310838
0.0323748
0.134475
0.135243
0.0498516
0.054617
0.0493355
0.13879
0.129865
0.0347888
0.137778
0.0356445
0.0341972
0.0550708
0.0345015
0.0443174
0.0597805
0.102351
0.137678
0.137787
0.139966
0.132061
0.0434944
0.0727659
0.13328
0.0304106
0.0435353
0.0319703
0.0455313
0.0303213
0.0418249
0.0433784
0.0782929
0.0359668
0.0262382
0.0264669
0.0514343
0.0287321
0.0264884
0.138022
0.0380308
0.00784518
0.0731548
0.0350829
0.139066
0.136398
0.074142
0.0309948
0.138984
0.0222898
0.0363099
0.0429128
0.0309226
0.0381547
0.0177616
0.0588067
0.0566833
0.0316918
0.0644222
0.136733
0.137766
0.100477
0.036262
0.0803921
0.136
0.0967201
0.0620241
0.035831
0.0888602
0.0391004
0.0295933
0.0536366
0.0453288
0.0175144
0.13965
0.111743
0.038529
0.116772
0.0553953
0.0473449
0.03413
0.0320629
0.146938
0.06293
0.0395547
0.139737
0.0268151
0.0463284
0.0594912
0.138142
0.052566
0.0496274
0.034801
0.0806717
0.0664793
0.0368362
0.0498213
0.0211647
0.0415192
0.0510646
0.0405739
0.0870035
0.035919
0.0399092
0.0309007
0.0527763
0.139911
0.0316548
0.0433721
0.0798119
0.0371299
0.0910346
0.0336646
0.028468
0.125953
0.0461847
0.106315
0.139319
0.0338949
0.0494993
0.0715959
0.109045
0.139984
0.058489
0.0337117
0.0420585
0.0340339
0.0237094
0.134938
0.045468
0.126031
0.140003
0.0315554
0.037997
0.0277846
0.184942
0.0363784
0.0368877
0.0822824
0.10723
0.0656406
0.0685995
0.0665163
0.136154
0.0339477
0.0220472
0.123368
0.0470431
0.107262
0.104936
0.0405053
0.0337156
0.0720321
0.129049
0.102902
0.0582791
0.0578164
0.035039
0.132082
0.0351206
0.0323165
0.137819
0.0638532
0.0701494
0.0343156
0.0576606
0.031136
0.0282372
0.0536908
0.024038
0.0798055
0.0597763
0.0337398
0.134993
0.139891
0.0220354
0.0345965
0.00310846
0.0638592
0.139854
0.047218
0.0319107
0.066332
0.0388078
0.0319712
0.00713333
0.100902
0.13953
0.0337734
0.0346071
0.0649113
0.0400946
0.101809
0.0675707
0.0320601
0.121904
0.0382888
0.062953
0.0383527
0.0532791
0.0542944
0.0685854
0.0314329
0.0312762
0.128345
0.0451238
0.0128629
0.0275063
0.0175832
0.0874339
0.0373885
0.0773385
0.0288989
0.043612
0.00669614
0.0821956
0.0302524
0.138405
0.0720155
0.0411308
0.13837
0.0294938
0.0846588
0.0312196
0.0591004
0.12476
0.0367603
0.0705309
0.0347768
0.0739381
0.0809124
0.208041
0.128765
0.0569834
0.0291665
0.0398406
0.0282167
0.0472416
0.087925
0.136548
0.0488808
0.0675259
0.0317821
0.0383199
0.0360891
0.0345413
0.0337283
0.0391307
0.0598096
0.0306206
0.0992414
0.0893129
0.127284
0.0590235
0.0798838
0.0225278
0.0746285
0.0891484
0.0307675
0.135257
0.0410723
0.0101661
0.0388707
0.040087
0.00709388
0.115202
0.033029
0.0295718
0.0582127
0.0581016
0.130897
0.0433212
0.00254364
0.0543287
0.0439012
0.0291603
0.0496521
0.0791676
0.0952743
0.0920412
0.137812
0.10035
0.080247
0.00568959
0.00291363
0.111296
0.0425879
0.0334344
0.029755
0.0300157
0.130114
0.0306775
0.034029
0.130264
0.0332315
0.0387514
0.0481751
0.135849
0.030531
0.0288454
0.0425889
0.101868
0.00976504
0.0968107
0.139155
0.0497716
0.0528056
0.0338938
0.0333243
0.0485851
0.0435174
0.00272362
0.0279579
0.139235
0.0419983
0.0988533
0.0741712
0.042804
0.00324672
0.032614
0.132588
0.0225844
0.0639568
0.0316152
0.030258
0.0254083
0.0614267
0.0289997
0.0539212
0.0266245
0.0575337
0.0303388
0.0124634
0.109954
0.00385368
0.0744725
0.103038
0.105137
0.0401293
0.137698
0.138315
0.0727321
0.0312675
0.0313052
0.0561379
0.0311585
0.0696868
0.00415441
0.0336302
0.0255201
0.0341127
0.0542952
0.0293154
0.040324
0.0539205
0.0413653
0.0296131
0.0714562
0.0330884
0.0593107
0.0783119
0.0717726
0.0761607
0.0365277
0.130189
0.0685355
0.0798404
0.0353903
0.138382
0.0701115
0.0220545
0.13997
0.0449903
0.0315967
0.0319498
0.0227504
0.0363558
0.0150653
0.0448145
0.0502685
0.11398
0.0307928
0.0860584
0.0829683
0.0499785
0.0216298
0.384345
0.0597379
0.0522217
0.0734957
0.0381254
0.0365258
0.045824
0.0438569
0.0345992
0.00763103
0.0365053
0.0302383
0.135816
0.00649139
0.0903333
0.042384
0.0688845
0.0766326
0.0389023
0.0411523
0.0308614
0.0572236
0.0194414
0.10063
0.021731
0.0502583
0.0630702
0.0611357
0.0519167
0.0406085
0.0969902
0.0669289
0.0931909
0.0177304
0.0326456
0.10416
0.0303069
0.138775
0.0377068
0.139019
0.0293155
0.139704
0.0609414
0.0800795
0.0282153
0.0476862
0.0847505
0.134129
0.139319
0.0306874
0.0537313
0.0787133
0.0450356
0.0452492
0.0764837
0.0326308
0.0743685
0.0500532
0.0776476
0.132511
0.0513754
0.129475
0.0540203
0.0481935
0.0435869
0.0450502
0.0751425
0.0429588
0.034827
0.0456315
0.0359194
0.0360243
0.101957
0.0315523
0.120083
0.119133
0.117277
0.0773006
0.0451593
0.0206481
0.0923066
0.0239405
0.0401365
0.0540915
0.11444
0.265957
0.0753059
0.0353458
0.0262913
0.00704207
0.0832952
0.00489772
0.045131
0.0348847
0.133794
0.125814
0.0935185
0.00919363
0.0295794
0.140012
0.0218456
0.0359968
0.0708396
0.034265
0.036687
0.0397791
0.0297208
0.065951
0.00323592
0.0357013
0.0756529
0.114744
0.0644402
0.138801
0.0402551
0.0447306
0.0539623
0.0335973
0.0369813
0.321248
0.0696346
0.139892
0.0470328
0.0267236
0.042054
0.0761367
0.0335024
0.138193
0.0299245
0.0422852
0.0750594
0.023066
0.122688
0.133994
0.0841059
0.0330452
0.0381774
0.0647338
0.138043
0.0295527
0.0738287
0.0469097
0.125628
0.142128
0.0335741
0.0533777
0.017862
0.0310992
0.0374535
0.0508058
0.0651048
0.0611006
0.0524321
0.0359263
0.0862544
0.137286
0.0435976
0.139702
0.023312
0.0596612
0.0446193
0.082455
0.026845
0.0968948
0.0351081
0.133268
0.020617
0.121371
0.0375788
0.0397733
0.0351221
0.101447
0.00121468
0.0434301
0.0550206
0.0899614
0.123038
0.0332471
0.0362832
0.0499497
0.0834947
0.0738749
0.0393045
0.0155811
0.0453358
0.0704149
0.136639
0.0992999
0.325229
0.0768338
0.0299035
0.13759
0.0512455
0.0424167
0.0430397
0.0742086
0.074872
0.0413849
0.0645521
0.0673409
0.111995
0.0427031
0.0458671
0.0721826
0.0433762
0.0546474
0.120576
0.13411
0.0349367
0.0396031
0.033357
0.133313
0.0203678
0.0526414
0.0303065
0.0282774
0.0309751
0.0427773
0.00220591
0.0273728
0.0394916
0.0543803
0.11981
0.0997778
0.00578106
0.0348071
0.0515886
0.0676038
0.0523591
0.110004
0.0367993
0.107775
0.0474486
0.0337211
0.138148
0.038308
0.138336
0.078191
0.13744
0.0293757
0.0349685
0.0464074
0.0760182
0.0707747
0.116882
0.0471163
0.0296488
0.0374551
0.0839078
0.0620119
0.0557927
0.0901738
0.127395
0.029259
0.0841236
0.0286882
0.0332371
0.12865
0.0393027
0.0535111
0.0929089
0.0711947
0.0323277
0.0434169
0.0767637
0.0248371
0.0459655
0.00441412
0.0410047
0.135639
0.035776
0.0539223
0.0478119
0.0306053
0.13784
0.0763077
0.0435158
0.054362
0.113234
0.0793489
0.0872578
0.0109863
0.0350731
0.035699
0.0582701
0.0221248
0.0232685
0.0483913
0.035367
0.0463027
0.0369634
0.124943
0.0522901
0.0489483
0.0321431
0.0539452
0.0692074
0.119931
0.0442187
0.0353607
0.0255165
0.0501875
0.0479559
0.0356431
0.0352173
0.0323627
0.128155
0.0401542
0.034284
0.111249
0.139387
0.07729
0.0801332
0.0261245
0.139262
0.0712738
0.127706
0.00421996
0.0554447
0.0749907
0.0333827
0.0866868
0.0681181
0.0529035
0.0544383
0.104063
0.135495
0.0881202
0.0385421
0.0880587
0.0114128
0.138164
0.0229733
0.0390442
0.139595
0.213411
0.0931993
0.109568
0.0363596
0.0299739
0.0716728
0.0611127
0.0476013
0.0321257
0.0397837
0.0788864
0.0322975
0.0229777
0.0647373
0.13773
0.0322546
0.0885165
0.133174
0.0376697
0.167395
0.0896627
0.318278
0.0454571
0.0518025
0.139477
0.0416792
0.0638347
0.0338009
0.13465
0.0240917
0.0395289
0.0878906
0.0377965
0.101318
0.043097
0.0342202
0.0714343
0.0546056
0.121176
0.0372839
0.105084
0.0331977
0.0259752
0.040541
0.0597102
0.0944943
0.0355064
0.0345939
0.0835274
0.0413032
0.139661
0.0410303
0.136293
0.071568
0.0800731
0.0343436
0.0335046
0.0508974
0.0107089
0.0371637
0.129614
0.0371385
0.0358121
0.0361163
0.0464171
0.045505
0.12757
0.0689021
0.0779452
0.0326161
0.0678596
0.120364
0.0298996
0.0139216
0.0113316
0.131387
0.0466142
0.0330072
0.0325152
0.0547904
0.036839
0.0341973
0.0266119
0.0592179
0.282655
0.0478427
0.0425649
0.00509517
0.00615321
0.0729102
0.0254837
0.117907
0.0289769
0.0483608
0.0219801
0.0322793
0.0270878
0.065857
0.0268591
0.03251
0.0510806
0.0645269
0.0726329
0.0440892
0.030744
0.0293762
0.0269455
0.054891
0.0792401
0.139821
0.0300986
0.0865145
0.134455
0.0290689
0.0318361
0.107285
0.121481
0.0310032
0.0661932
0.0337585
0.138217
0.0425442
0.0229544
0.0156103
0.0337789
0.0699627
0.050478
0.0535643
0.0652217
0.0335725
0.0081508
0.0778841
0.0972505
0.131365
0.0373835
0.0330416
0.0291263
0.059961
0.0305953
0.0765422
0.0107434
0.0402348
0.0366311
0.0291655
0.0766433
0.0462772
0.0370532
0.384605
0.137626
0.0850596
0.0790571
0.0323464
0.392142
0.039334
0.0288596
0.0149309
0.0319336
0.0755724
0.0416582
0.024452
0.0128272
0.034086
0.0819435
0.133588
0.0217394
0.0642802
0.0495277
0.135115
0.0900836
0.0355798
0.0220441
0.0689618
0.0342709
0.199327
0.0835235
0.0406693
0.0373169
0.0299058
0.0310408
0.0339521
0.0920672
0.0742674
0.0358187
0.111723
0.0665254
0.0649892
0.12754
0.0380381
0.0357545
0.135638
0.057208
0.0324303
0.028657
0.0310636
0.0639629
0.00918037
0.0712835
0.0540753
0.127177
0.0592891
0.140956
0.130029
0.0622624
0.0325492
0.120331
0.0949206
0.0712999
0.0632012
0.0423341
0.0671519
0.0390872
0.0385846
0.0287525
0.0303152
0.0377808
0.106961
0.0786469
0.0284197
0.0730337
0.080324
0.0549005
0.0458008
0.0339342
0.0796581
0.0567664
0.0556803
0.0304093
0.0706774
0.0290019
0.035673
0.0779761
0.0642906
0.0779469
0.0600633
0.0274079
0.0651395
0.0276665
0.0308893
0.132785
0.0818579
0.0390369
0.00632565
0.0238219
0.112331
0.0978001
0.0398204
0.0704844
0.124683
0.0690847
0.0620975
0.0556102
0.0280556
0.0422665
0.0699587
0.136675
0.0752155
0.077457
0.060678
0.0229851
0.0229647
0.0411585
0.0501655
0.0313352
0.13685
0.0110293
0.012304
0.0423768
0.13405
0.0431967
0.0243744
0.0307164
0.0578844
0.0691438
0.060925
0.0423233
0.112866
0.0192913
0.0674867
0.117677
0.0330452
0.129753
0.0243249
0.0829156
0.133545
0.0332871
0.0517042
0.0316795
0.0610348
0.0360161
0.0259693
0.125776
0.0451792
0.139704
0.0603775
0.031243
0.104286
0.214776
0.0334592
0.0452837
0.075577
0.0494371
0.0729179
0.0752518
0.054153
0.0544444
0.0317276
0.0329467
0.27869
0.072332
0.138038
0.0567608
0.0642096
0.0425368
0.0411517
0.138565
0.0790564
0.0705236
0.0242889
0.0104097
0.28025
0.0242783
0.0106442
0.0323684
0.0933317
0.134437
0.0838131
0.0321902
0.0215086
0.0646116
0.063146
0.0281795
0.0972605
0.0263856
0.025041
0.0664591
0.0844549
0.0699438
0.0243306
0.12625
0.0445464
0.133103
0.0330936
0.029822
0.0974939
0.14002
0.0603902
0.0303961
0.0426739
0.0570807
0.0364219
0.133928
0.138706
0.0947757
0.0343581
0.137308
0.137358
0.0208731
0.0633173
0.0543124
0.0406068
0.025283
0.0441956
0.00283798
0.00336456
0.145188
0.117663
0.0428589
0.13828
0.0338408
0.0718912
0.0296655
0.0293989
0.0522172
0.0321161
0.0602599
0.0263527
0.0530021
0.139494
0.0335235
0.0498795
0.0323979
0.113655
0.0303509
0.0762862
0.0707133
0.0446237
0.0324386
0.0325773
0.0475447
0.0496862
0.0313982
0.136898
0.132977
0.05428
0.187362
0.0640963
0.0945492
0.034936
0.0325405
0.025091
0.0544697
0.0187839
0.0913206
0.0415002
0.0306452
0.0888451
0.13958
0.026877
0.0376098
0.0682041
0.0374031
0.0464008
0.0344021
0.0189825
0.00421427
0.058719
0.129531
0.0404477
0.0319101
0.0489977
0.0439592
0.0725851
0.0344036
0.037178
0.00323558
0.0365296
0.11921
0.0524697
0.0530129
0.0392385
0.0427326
0.0734404
0.0339771
0.215975
0.0306785
0.134188
0.131122
0.0375255
0.0913172
0.135154
0.0439564
0.145874
0.0487613
0.0327379
0.0503778
0.0258726
0.0352165
0.0399357
0.0250646
0.131453
0.0273573
0.0311825
0.0617529
0.0277891
0.0310418
0.0618225
0.0436263
0.0695311
0.0374099
0.0124134
0.0485858
0.133862
0.0580524
0.031586
0.116469
0.0406301
0.0206287
0.0496456
0.022017
0.13205
0.0699471
0.138303
0.0878279
0.0618898
0.0541688
0.0237585
0.0237316
0.0363511
0.0863393
0.123986
0.0631401
0.0406337
0.066343
0.0609148
0.114634
0.0461143
0.0374248
0.0658566
0.0481642
0.136096
0.0264866
0.0969147
0.0138015
0.124833
0.0469529
0.0615661
0.0480304
0.0341954
0.06644
0.0320271
0.063213
0.114683
0.0292518
0.0263789
0.0326234
0.111629
0.0353432
0.0322926
0.0222609
0.122448
0.0315244
0.0627217
0.0843096
0.00363917
0.0227389
0.0756056
0.0342978
0.029566
0.0316609
0.0329804
0.0284938
0.0350144
0.0446529
0.0962969
0.0339767
0.0358303
0.0349824
0.0591451
0.0112406
0.0701524
0.101363
0.0803622
0.0590787
0.0312588
0.0831258
0.0442431
0.0294344
0.0418679
0.0375716
0.00789771
0.0282992
0.331483
0.0279923
0.136309
0.0401399
0.0650692
0.0362298
0.0279295
0.0670528
0.0547788
0.0310246
0.0242384
0.111137
0.0334608
0.0384486
0.0398666
0.0378799
0.0380134
0.0259279
0.0336767
0.0285825
0.0333208
0.0273774
0.138304
0.0352675
0.0340675
0.0641288
0.0272752
0.0377723
0.00886144
0.135203
0.0886959
0.102799
0.0343597
0.0516603
0.0706567
0.0787023
0.125889
0.0576692
0.0300314
0.062505
0.0452499
0.0352415
0.041553
0.0684642
0.116021
0.0409324
0.0254227
0.0320815
0.046018
0.0428595
0.0551918
0.0395202
0.0257596
0.0234191
0.0675522
0.0377773
0.0278762
0.05152
0.0664977
0.0980963
0.0508452
0.136391
0.0748338
0.0488192
0.0632459
0.0482805
0.0765499
0.0217728
0.0584294
0.0842943
0.0214379
0.034529
0.0276694
0.0298689
0.0467008
0.0488475
0.0984101
0.0761951
0.0288004
0.121046
0.0289894
0.0504236
0.0698075
0.0551645
0.129402
0.0953949
0.0781868
0.0575252
0.0416147
0.0967223
0.103503
0.136994
0.0724185
0.048427
0.0345214
0.0528068
0.0328862
0.104959
0.0669038
0.133977
0.0635872
0.051148
0.136259
0.0327727
0.0426652
0.0783361
0.021569
0.138204
0.0385171
0.0361248
0.0411488
0.0444412
0.0365605
0.0528
0.0364834
0.0391101
0.0267528
0.0300125
0.0621914
0.0807866
0.018924
0.0914918
0.0222227
0.0273002
0.0651065
0.0514877
0.0405948
0.0406741
0.0239345
0.0680453
0.0316487
0.0885922
0.041916
0.0729059
0.0267522
0.138557
0.13278
0.0314956
0.0346111
0.0392129
0.035195
0.0593754
0.0346644
0.128473
0.0425757
0.0246168
0.0320466
0.0714897
0.0618943
0.0420722
0.058459
0.02569
0.0285709
0.0404938
0.0319318
0.0257984
0.0269634
0.0657288
0.104342
0.0248731
0.0913607
0.0168568
0.0468202
0.139326
0.0347063
0.00183996
0.0704243
0.127277
0.0464398
0.0330717
0.0423672
0.0582847
0.126335
0.0404355
0.0562382
0.0389863
0.0684206
0.138206
0.040146
0.0334191
0.0612712
0.105328
0.0771919
0.124017
0.0796842
0.0908498
0.0324486
0.134954
0.0592008
0.0688814
0.138008
0.117621
0.0268045
0.0142244
0.0422374
0.125218
0.0959483
0.0318323
0.0389782
0.0770928
0.115056
0.083034
0.104783
0.112668
0.0209793
0.0239615
0.0451433
0.0413212
0.0488496
0.128848
0.0308551
0.024077
0.0999384
0.0283538
0.131823
0.031412
0.017446
0.139369
0.0774395
0.120136
0.137601
0.0567247
0.0360721
0.0341363
0.049657
0.0791985
0.029822
0.0854037
0.139338
0.0900303
0.0264817
0.139585
0.0367371
0.0485845
0.0443284
0.0340211
0.0401949
0.0335128
0.0379947
0.0342589
0.0314972
0.0413633
0.0679121
0.0902411
0.0369301
0.044344
0.030653
0.0643121
0.0443976
0.138615
0.0464574
0.0385695
0.132374
0.0327816
0.009074
0.0496581
0.140011
0.083574
0.140018
0.100483
0.0561711
0.0293335
0.0325464
0.0426799
0.121763
0.028675
0.029644
0.033287
0.0431944
0.128947
0.0459004
0.0268665
0.114538
0.031841
0.0500713
0.0712607
0.123921
0.0793376
0.131078
0.0555627
0.0481833
0.0249008
0.034562
0.0603972
0.0754461
0.0301169
0.0430362
0.0577807
0.383917
0.0904864
0.097975
0.030929
0.0704574
0.0964659
0.0584755
0.0390174
0.0404599
0.136868
0.0720095
0.0260105
0.137574
0.0683662
0.0327642
0.116152
0.0385268
0.0213418
0.033754
0.0482827
0.00607068
0.121559
0.0653205
0.0162155
0.034347
0.00173062
0.0317149
0.126203
0.0208602
0.130123
0.0510953
0.0528016
0.138651
0.0629762
0.0487294
0.0206788
0.0483463
0.0389903
0.0387914
0.0309784
0.0600381
0.0287945
0.103446
0.133047
0.137474
0.0663105
0.0379692
0.0296288
0.0377095
0.0309319
0.0327515
0.0738823
0.0513421
0.038656
0.0320169
0.0253547
0.0418934
0.0342201
0.0301858
0.0350239
0.0194896
0.0315305
0.0367429
0.0531371
0.0924856
0.137216
0.057809
0.0310469
0.0710767
0.137392
0.111991
0.049331
0.115568
0.054798
0.0361747
0.138917
0.00453313
0.0233672
0.0619363
0.0678202
0.0723457
0.0264159
0.045586
0.0284695
0.0132762
0.031672
0.0272246
0.0803449
0.127668
0.0690166
0.135972
0.00346738
0.113502
0.0554616
0.0413649
0.263351
0.245261
0.0355809
0.0778778
0.136428
0.141134
0.0649168
0.0697255
0.0805438
0.0499542
0.0334329
0.0315998
0.0474965
0.127629
0.0451217
0.139525
0.103395
0.0291082
0.0504795
0.117111
0.0266032
0.133712
0.0468428
0.0625429
0.0730074
0.0270773
0.0408542
0.0574526
0.0957304
0.0328522
0.051768
0.0715201
0.206453
0.0210303
0.0552873
0.0691025
0.0637822
0.0230335
0.0297169
0.0312054
0.0306093
0.0641428
0.0358067
0.0680428
0.138169
0.0691953
0.0312522
0.0612922
0.104427
0.0699223
0.0367623
0.139468
0.0521811
0.127549
0.0738587
0.00712819
0.0549853
0.0230868
0.0316837
0.0454413
0.0350925
0.0841085
0.0742138
0.0920596
0.130133
0.0330142
0.0449726
0.0357671
0.0763808
0.0658567
0.0432363
0.0602581
0.0358922
0.0280262
0.0343322
0.0300409
0.0369635
0.138499
0.00256928
0.138735
0.0339616
0.136585
0.0309721
0.0217594
0.0304305
0.111932
0.0323302
0.0547451
0.0218883
0.135603
0.0670032
0.116045
0.138388
0.067092
0.0540301
0.0320281
0.0249091
0.0353795
0.101027
0.0820246
0.0436851
0.0452148
0.0375689
0.0628281
0.0340406
0.058038
0.0384347
0.0597665
0.0650297
0.0179179
0.022845
0.0228033
0.0807364
0.13992
0.122461
0.0388917
0.134457
0.0275248
0.0228119
0.0260114
0.0781377
0.00344902
0.047746
0.0830777
0.0561639
0.312308
0.126314
0.0720806
0.135589
0.0324076
0.0328697
0.0563181
0.098683
0.0495542
0.291604
0.117712
0.0934188
0.0141273
0.111779
0.0541162
0.0326237
0.119207
0.0662196
0.0563743
0.0455605
0.120883
0.0727779
0.0576287
0.0313316
0.133123
0.126806
0.125915
0.139679
0.00510002
0.0326748
0.13609
0.0149196
0.077559
0.0315722
0.0259876
0.0257225
0.0328657
0.139842
0.0353144
0.0403187
0.061948
0.0389658
0.0565122
0.00263664
0.137863
0.043447
0.0342513
0.0851108
0.124404
0.0372038
0.0834012
0.0405066
0.077927
0.0450531
0.118612
0.0299539
0.0463702
0.078903
0.0575841
0.0286861
0.036862
0.0714084
0.0540429
0.082954
0.13599
0.0462238
0.0722684
0.0277736
0.0721679
0.0744866
0.0366642
0.105914
0.0959412
0.0582968
0.0923078
0.037248
0.139646
0.103982
0.0295568
0.0315638
0.0187209
0.049297
0.0700975
0.0782251
0.032929
0.138314
0.023677
0.0380484
0.136521
0.0293803
0.107529
0.0254867
0.0772629
0.111626
0.0333278
0.0474429
0.0258064
0.0665837
0.13975
0.0354721
0.136538
0.0300928
0.0448255
0.0619183
0.0583274
0.0343416
0.0282726
0.0718453
0.0306254
0.135382
0.0869916
0.0422458
0.0355528
0.0899146
0.0238558
0.0711864
0.124184
0.128512
0.0676717
0.0537988
0.0408248
0.0349553
0.046226
0.0738108
0.00776556
0.111474
0.11954
0.121542
0.0671551
0.138962
0.0464095
0.0440898
0.116298
0.0984613
0.138201
0.0442649
0.0704986
0.0794901
0.0398165
0.0265095
0.136565
0.0438786
0.0369764
0.139359
0.114213
0.0201813
0.0636787
0.0632854
0.0343104
0.0283325
0.0372903
0.0627573
0.0474249
0.0457086
0.130166
0.0548184
0.0363974
0.034232
0.193472
0.0306515
0.0463665
0.127174
0.0349415
0.080537
0.0546812
0.0984031
0.0693792
0.0749932
0.0299462
0.0764896
0.0520796
0.0733605
0.0244381
0.0359487
0.0411159
0.0425284
0.0812565
0.133788
0.0884723
0.0504079
0.0467582
0.106354
0.0769393
0.137278
0.0239315
0.0809197
0.112584
0.0505357
0.0638985
0.0316423
0.0309805
0.0705882
0.00535503
0.0331357
0.126675
0.0717886
0.00964096
0.119613
0.11487
0.0430459
0.0240622
0.0776583
0.0570399
0.0214049
0.108394
0.0321223
0.0151261
0.104742
0.0265155
0.0322438
0.023795
0.0317676
0.0533356
0.0278904
0.0963046
0.00524011
0.0446605
0.0822335
0.137047
0.0684093
0.0612254
0.0283505
0.0341323
0.041398
0.0965544
0.040941
0.0326879
0.0672304
0.0363634
0.0544341
0.0317456
0.13474
0.123813
0.0381689
0.0232707
0.0217386
0.0423777
0.144498
0.0479299
0.0900129
0.024842
0.0779382
0.0980673
0.0631762
0.0309449
0.0103377
0.0845348
0.0138036
0.163446
0.135808
0.0301364
0.030209
0.0834724
0.077906
0.0570795
0.0644291
0.0349734
0.0581345
0.0517773
0.0643858
0.127964
0.0412725
0.13493
0.0348949
0.0683873
0.126762
0.0688915
0.130316
0.127962
0.0554685
0.061934
0.12579
0.0847958
0.138563
0.046345
0.13854
0.0338501
0.121989
0.0354177
0.0496427
0.0565195
0.0689817
0.139909
0.0247052
0.0362325
0.114962
0.0281663
0.136353
0.100574
0.0227697
0.0539971
0.0728514
0.113918
0.0343389
0.0736245
0.0609714
0.0418909
0.11511
0.0342614
0.135064
0.0745777
0.057727
0.0324948
0.139288
0.0683067
0.035409
0.0277761
0.0724691
0.0632965
0.0346694
0.0365454
0.0328528
0.0210255
0.0259716
0.0287786
0.0915826
0.052014
0.00607479
0.0622079
0.0377663
0.0622654
0.130117
0.0258706
0.0623395
0.133353
0.0240668
0.0404409
0.0798444
0.0366458
0.024343
0.0420146
0.116178
0.0513545
0.0332815
0.0385446
0.0289751
0.0318169
0.0288345
0.0550555
0.0342058
0.0734293
0.0846875
0.0381143
0.105347
0.00838453
0.0275404
0.0214486
0.0423709
0.0389217
0.0801214
0.0249485
0.139885
0.0199933
0.071648
0.0533822
0.0356323
0.0247007
0.124858
0.0452766
0.043569
0.0210074
0.0311429
0.102941
0.0732002
0.326652
0.0407131
0.135036
0.0513326
0.0337434
0.036522
0.0689496
0.0362278
0.0210172
0.096581
0.0409445
0.0998494
0.14002
0.037373
0.0366216
0.0284281
0.0382965
0.0629068
0.0391846
0.0321749
0.0451823
0.0941798
0.108616
0.0370825
0.0122294
0.119679
0.051607
0.0934163
0.0303867
0.140002
0.0598477
0.03205
0.0941296
0.0601933
0.0600233
0.0801121
0.0599539
0.0781404
0.13828
0.13156
0.0654235
0.0230454
0.138771
0.0395834
0.0638695
0.0369394
0.0249345
0.0583265
0.137391
0.137042
0.137373
0.0465503
0.0403937
0.0335036
0.0404302
0.129102
0.0342519
0.0296167
0.133608
0.0379328
0.0527588
0.0410207
0.0334487
0.104108
0.078368
0.137095
0.0333099
0.0380595
0.0330363
0.0355413
0.0642067
0.0458024
0.0363928
0.0833397
0.0341692
0.266562
0.104892
0.0431238
0.137604
0.103629
0.0733518
0.133467
0.00238422
0.00357388
0.00284136
0.014669
0.0580326
0.121475
0.0275736
0.0310918
0.0390659
0.106591
0.0320842
0.132156
0.11838
0.106831
0.0523566
0.0853839
0.0376973
0.0636416
0.0779608
0.0874521
0.138336
0.0787421
0.0993465
0.0746865
0.0401266
0.0397286
0.0260765
0.0441876
0.0212362
0.106244
0.0570252
0.0297023
0.0257217
0.0489184
0.035087
0.0341098
0.134398
0.0590713
0.100479
0.126958
0.139765
0.0588285
0.0572037
0.0109245
0.106399
0.067207
0.0663374
0.0883212
0.0551323
0.125308
0.0790276
0.0643449
0.139378
0.013077
0.136814
0.024471
0.0702019
0.159906
0.0813088
0.0452833
0.114793
0.0998951
0.030274
0.0864097
0.0454559
0.0660434
0.0443089
0.0228249
0.0902687
0.0817532
0.0809262
0.110417
0.0713038
0.111731
0.0305628
0.0913688
0.0584708
0.0375177
0.123844
0.0316413
0.0755172
0.0330486
0.0357959
0.134691
0.0258947
0.0359943
0.0467967
0.129776
0.0312566
0.0407479
0.12672
0.0333665
0.0372187
0.00210567
0.0331584
0.0274579
0.115019
0.0289806
0.0200355
0.0265714
0.0755465
0.0463538
0.0098512
0.0531895
0.0258145
0.0253777
0.0290054
0.108061
0.0645783
0.0534832
0.0698301
0.277947
0.102556
0.13234
0.0340091
0.0294236
0.0579469
0.0466437
0.0331149
0.123779
0.0333854
0.0555999
0.128841
0.120255
0.0700273
0.0342931
0.138616
0.0588178
0.00666414
0.0489371
0.044927
0.0391128
0.0603683
0.0277702
0.00185708
0.0758185
0.138635
0.0264427
0.0310668
0.0373565
0.138831
0.0367903
0.0858928
0.0608011
0.0635015
0.0792386
0.0334317
0.0303359
0.0314665
0.134952
0.0983872
0.0524298
0.0327721
0.0612042
0.138778
0.0535566
0.0260853
0.138351
0.0320266
0.0714599
0.0415072
0.129855
0.0379818
0.124554
0.0888714
0.0603784
0.0563358
0.138945
0.0517516
0.111315
0.0400468
0.0463256
0.0789291
0.085443
0.0771846
0.036383
0.0437156
0.0651846
0.0284675
0.123945
0.134471
0.0466795
0.138419
0.0392725
0.0367095
0.0630618
0.0122443
0.0317117
0.137723
0.0402911
0.0362195
0.0381916
0.0242188
0.040827
0.0354246
0.0893442
0.0414544
0.108005
0.137355
0.160834
0.13697
0.0322343
0.03217
0.0831043
0.0353008
0.0353135
0.0948946
0.0363371
0.034917
0.0501394
0.0458765
0.0470784
0.0495289
0.104926
0.125408
0.0146575
0.0358947
0.0354522
0.10247
0.0365856
0.063963
0.0736528
0.0358973
0.0430189
0.0802363
0.0970178
0.0382577
0.0536275
0.141148
0.0622762
0.0513229
0.0366666
0.139994
0.0258584
0.139016
0.104193
0.118701
0.0292076
0.0259937
0.0334267
0.0580852
0.138167
0.137665
0.0942001
0.0507144
0.0620685
0.108156
0.0586075
0.044319
0.097089
0.0313724
0.118644
0.0144816
0.0621115
0.033447
0.0354397
0.122971
0.0620607
0.0702564
0.1388
0.117268
0.0247373
0.0307069
0.0352633
0.0249974
0.044162
0.0380257
0.0248204
0.0836319
0.133057
0.0339317
0.05792
0.139293
0.0398515
0.0484663
0.126306
0.105092
0.0327269
0.0470324
0.00844986
0.0303613
0.0145972
0.0617682
0.0876271
0.00910226
0.0423333
0.0675505
0.0231397
0.00420799
0.139831
0.132089
0.0454329
0.0534264
0.0222303
0.0685453
0.0684674
0.0394826
0.0245093
0.00866107
0.0219073
0.0585043
0.0385767
0.0571226
0.0310106
0.0292736
0.0449897
0.0690954
0.0326572
0.0643486
0.025265
0.139412
0.0330822
0.132271
0.0938965
0.0306494
0.0635338
0.0368595
0.0113463
0.010591
0.0385972
0.0376675
0.0290674
0.112711
0.135731
0.0410406
0.140009
0.0242545
0.00255192
0.0782508
0.036559
0.138527
0.0402303
0.138223
0.0551592
0.0388799
0.0384304
0.0475199
0.0779752
0.022349
0.0820336
0.0378402
0.0791794
0.0724984
0.0414559
0.0361989
0.0314786
0.0943922
0.0493094
0.138927
0.0560056
0.0399951
0.0267291
0.0184615
0.112682
0.0427478
0.0704728
0.0991669
0.128434
0.0728111
0.130666
0.0556732
0.0444877
0.140004
0.0400286
0.135988
0.00845693
0.0658297
0.102758
0.00219048
0.0534239
0.0891883
0.0994721
0.0400646
0.0188803
0.0389187
0.174447
0.135939
0.0647716
0.0317641
0.0238364
0.138824
0.0521437
0.0309395
0.0522701
0.0823184
0.138987
0.0629978
0.0936663
0.0588243
0.0326532
0.0316282
0.0145371
0.00416043
0.0282156
0.0304156
0.0521167
0.137689
0.137693
0.036471
0.0618763
0.0247548
0.138949
0.0114647
0.0242754
0.137053
0.0369438
0.0653159
0.0252901
0.0592541
0.0328499
0.0351723
0.0254065
0.0506513
0.0254793
0.113651
0.0803387
0.0242825
0.139605
0.0653799
0.0328671
0.0792192
0.132394
0.0482488
0.081552
0.0413111
0.0236213
0.0329852
0.126043
0.125072
0.0364566
0.0368593
0.0293499
0.101816
0.0281159
0.0405422
0.0400308
0.0594366
0.0776458
0.06827
0.0169405
0.0508957
0.0117645
0.0550074
0.0754445
0.0682542
0.117554
0.131931
0.135435
0.0297428
0.0881102
0.0772881
0.0376409
0.0344411
0.0985522
0.0548418
0.014569
0.0512539
0.0553113
0.0949256
0.10724
0.0376564
0.0239855
0.0410429
0.104267
0.120677
0.048199
0.0295028
0.0380141
0.0581834
0.114596
0.0299455
0.0341033
0.117502
0.0947574
0.0669511
0.0360395
0.0804339
0.0499703
0.00561374
0.0913446
0.0378833
0.0344142
0.133137
0.0885159
0.0281074
0.0371259
0.0568598
0.136294
0.138323
0.113016
0.0289724
0.0520474
0.0315716
0.0309046
0.030696
0.0190898
0.0493533
0.0343324
0.00574315
0.068106
0.128332
0.0843165
0.0772505
0.135522
0.0524044
0.0736575
0.0318929
0.0611809
0.0605444
0.117661
0.0505241
0.0998787
0.0220415
0.0400565
0.0210629
0.0310191
0.0278003
0.0826652
0.143508
0.0385816
0.139234
0.0686923
0.037623
0.138524
0.055049
0.0614619
0.0545091
0.0473899
0.0402572
0.139436
0.0341457
0.0380224
0.0514055
0.0664755
0.0945597
0.00651217
0.0575376
0.0659402
0.0523493
0.00242111
0.0342019
0.0318509
0.0772268
0.366841
0.035617
0.0348599
0.134327
0.092135
0.0362066
0.0632648
0.0635885
0.136925
0.0364597
0.126269
0.134169
0.0393276
0.0330012
0.0801126
0.0293803
0.134098
0.138549
0.0423173
0.0730447
0.0700726
0.0395884
0.0522188
0.0499373
0.0377033
0.0560363
0.0524271
0.033516
0.06763
0.118582
0.0850696
0.0301737
0.133079
0.0283918
0.0395294
0.0791921
0.0377767
0.0320022
0.0295243
0.0883939
0.138296
0.105225
0.0314044
0.0496422
0.037472
0.0383412
0.0315515
0.0652339
0.0421063
0.0349734
0.0397529
0.0231346
0.0319379
0.0631465
0.0633464
0.0481051
0.0484661
0.0664611
0.13469
0.0350007
0.0706658
0.0843058
0.0616049
0.017162
0.0496137
0.137061
0.0506539
0.0389743
0.0346872
0.0358327
0.0658987
0.0715245
0.135232
0.0467549
0.138126
0.0847955
0.0283773
0.0369611
0.066653
0.0313518
0.0770407
0.058203
0.0375063
0.0263125
0.139958
0.0374762
0.118501
0.0615682
0.0809972
0.136365
0.0529883
0.0301662
0.120299
0.0875584
0.0747791
0.111631
0.0703774
0.0329328
0.0870661
0.069738
0.0329378
0.140021
0.0348235
0.0764782
0.137703
0.0676424
0.0299693
0.0467263
0.134559
0.0622324
0.0675935
0.133038
0.0497607
0.0685029
0.0371489
0.0737431
0.105869
0.136775
0.0947787
0.0323535
0.0550791
0.0504123
0.0358813
0.0366222
0.153762
0.0351994
0.0993803
0.0416246
0.2032
0.0471024
0.126565
0.0864558
0.139112
0.177433
0.0385345
0.0386536
0.0381544
0.0384819
0.0569923
0.104497
0.0875859
0.079602
0.0386215
0.123851
0.13871
0.0748653
0.0315441
0.111739
0.0329695
0.0288589
0.0581729
0.0360223
0.0767065
0.0868879
0.0782157
0.0743229
0.0342304
0.00206546
0.131099
0.0334198
0.0329938
0.0560165
0.0332169
0.0335972
0.0404125
0.129109
0.109371
0.0445709
0.135023
0.1326
0.127256
0.0379012
0.0925621
0.0481174
0.0306733
0.0300047
0.0326543
0.101289
0.0254143
0.0292712
0.120455
0.00391397
0.0381709
0.035004
0.0543773
0.0311956
0.0771429
0.0371323
0.0557042
0.0509005
0.127963
0.0914087
0.0278683
0.0287956
0.0384228
0.102451
0.0397988
0.0376682
0.0650887
0.0521831
0.0252388
0.0292138
0.031613
0.0858804
0.0352049
0.0298964
0.029686
0.0362145
0.0355727
0.0539053
0.0320841
0.0636723
0.0281653
0.015217
0.031132
0.0853793
0.0705695
0.0833004
0.0292781
0.0697434
0.135302
0.117545
0.115539
0.0731079
0.0788158
0.131117
0.120787
0.0501397
0.0221166
0.114796
0.0329546
0.069447
0.0273439
0.0345964
0.117123
0.0519474
0.0302268
0.0478527
0.0367133
0.0284015
0.132412
0.0543359
0.0217542
0.0773553
0.0604019
0.119447
0.0710412
0.0465018
0.0955537
0.0331623
0.0812667
0.30116
0.0545924
0.0638988
0.0407791
0.0686642
0.119442
0.0795794
0.0748907
0.0310018
0.138574
0.0541385
0.0683124
0.102938
0.0401656
0.0878283
0.13669
0.0198516
0.0997861
0.036926
0.058396
0.108107
0.0717774
0.00370784
0.0882271
0.10392
0.0319108
0.0119048
0.0905724
0.030041
0.0720548
0.0300909
0.0412203
0.0333578
0.0343774
0.0018323
0.0675144
0.0202448
0.120865
0.0430942
0.0866762
0.00282277
0.130116
0.0994736
0.0302791
0.0359443
0.040737
0.0404165
0.0646493
0.149804
0.0337138
0.137911
0.0358679
0.0290749
0.128513
0.0760766
0.0435676
0.0435197
0.00350966
0.0318095
0.0498879
0.057672
0.031307
0.0304573
0.0212855
0.0465278
0.101214
0.0639563
0.0370517
0.0312955
0.0863079
0.0762908
0.0750757
0.139946
0.0567231
0.0403342
0.0377794
0.13976
0.115306
0.0312627
0.0276407
0.138793
0.0390539
0.0220755
0.139224
0.0330126
0.029664
0.0754587
0.0450542
0.137641
0.0602127
0.0125368
0.00578224
0.00687394
0.0313975
0.033197
0.134152
0.0933168
0.139599
0.0569635
0.0366362
0.0409625
0.0309218
0.0359321
0.066919
0.34337
0.0647545
0.0740708
0.0210159
0.0607365
0.0349127
0.0501005
0.0270245
0.0759452
0.336548
0.0406251
0.0792524
0.131107
0.0842654
0.0828839
0.139853
0.0854284
0.0644006
0.0162405
0.0763891
0.017529
0.0291514
0.0344541
0.0423
0.139226
0.0799094
0.0711695
0.00202483
0.14578
0.133419
0.109086
0.136088
0.00645243
0.0587196
0.139801
0.0072202
0.0333861
0.0337404
0.139538
0.0317726
0.0767986
0.0338368
0.0651116
0.0160906
0.0358625
0.0367171
0.13982
0.140508
0.1363
0.069481
0.0377164
0.0330854
0.161184
0.0594265
0.0334296
0.138751
0.0144647
0.0135305
0.11998
0.132996
0.135395
0.0397769
0.134858
0.0303905
0.0709022
0.0530579
0.0926393
0.137904
0.11974
0.0337182
0.0448305
0.139911
0.07095
0.0824394
0.034721
0.0483194
0.0954781
0.077006
0.0415132
0.0628117
0.139628
0.0775474
0.0273013
0.0776167
0.107963
0.078152
0.0634969
0.106294
0.135943
0.00141353
0.0375618
0.0437863
0.0750219
0.0268759
0.0276878
0.0766452
0.00504818
0.105709
0.0323391
0.123426
0.0284544
0.107177
0.0429308
0.00313866
0.0398275
0.138899
0.0172504
0.00293103
0.0140377
0.0729584
0.125029
0.0306246
0.115037
0.0893872
0.0331733
0.0315855
0.0655047
0.0610091
0.0614301
0.0701882
0.0747911
0.0674036
0.117282
0.0918232
0.0694329
0.134616
0.129001
0.037815
0.0675697
0.0566771
0.111952
0.137915
0.0289755
0.0373576
0.0628817
0.129999
0.118152
0.0398286
0.0250543
0.0300205
0.0600079
0.0994695
0.051906
0.0409186
0.0481887
0.0812485
0.050933
0.136802
0.0380834
0.0598318
0.11576
0.026761
0.0439903
0.0618184
0.0401759
0.0274064
0.136212
0.0515983
0.0246887
0.0306393
0.056466
0.049991
0.0316843
0.0374253
0.0408095
0.0465309
0.0389358
0.0442822
0.0232164
0.0310984
0.0442544
0.0648937
0.114327
0.139117
0.062624
0.113185
0.0367387
0.00619792
0.132545
0.0423501
0.0311549
0.0590217
0.0456676
0.037793
0.0541158
0.140896
0.0331069
0.136651
0.075323
0.135739
0.0270591
0.0401048
0.0313521
0.0424452
0.138527
0.0399707
0.0398236
0.0484216
0.276635
0.0668545
0.0661973
0.139995
0.030374
0.0652251
0.0353561
0.104455
0.0676326
0.0337767
0.0053307
0.0517191
0.0345516
0.0241929
0.0367494
0.0133178
0.0414755
0.0375053
0.138365
0.0344584
0.0248317
0.0387261
0.0349455
0.0102861
0.0727543
0.0400858
0.0697753
0.136394
0.0770116
0.0335903
0.0494242
0.0349239
0.0597456
0.132263
0.0837393
0.131511
0.00629175
0.0323418
0.00553068
0.138974
0.045624
0.0535633
0.0378509
0.101722
0.0312939
0.131548
0.023151
0.0350105
0.0478487
0.0689126
0.126123
0.0318124
0.134638
0.0810498
0.0442237
0.118349
0.0013155
0.00154331
0.120456
0.110885
0.0445688
0.0771591
0.0366941
0.0724125
0.0373534
0.0298436
0.0157574
0.0895003
0.0377421
0.0165999
0.0374674
0.0203951
0.0385139
0.0433679
0.0944927
0.0325016
0.0241413
0.0601761
0.0242669
0.0658577
0.0774304
0.126479
0.110942
0.0328503
0.11277
0.0135617
0.0742237
0.0214659
0.0228354
0.133917
0.0036802
0.00397465
0.00962337
0.106175
0.110303
0.05277
0.0391219
0.097205
0.0599999
0.138328
0.0495791
0.034811
0.0886693
0.0403238
0.0496059
0.0531819
0.0066906
0.0660004
0.0339713
0.0707474
0.077671
0.0948482
0.136665
0.149308
0.0501204
0.0314248
0.0714696
0.0316308
0.0779058
0.0140393
0.0386783
0.0751227
0.0440068
0.0331133
0.022449
0.0599635
0.058479
0.0332663
0.0345428
0.091986
0.0705123
0.0400576
0.0310887
0.123231
0.0494202
0.0828657
0.0590469
0.032067
0.0596431
0.0992131
0.0874678
0.0347215
0.0891473
0.00899163
0.139609
0.0316545
0.0754767
0.0616197
0.0281553
0.102657
0.0383107
0.0168761
0.0490263
0.0162962
0.0409092
0.0544635
0.0320119
0.107935
0.125091
0.0495405
0.021562
0.0312316
0.139473
0.0389195
0.0473228
0.0761265
0.0328466
0.0141222
0.0357887
0.0134573
0.013391
0.0714981
0.0542536
0.0811588
0.132634
0.0643406
0.137235
0.0785939
0.0714317
0.121658
0.0852675
0.057859
0.238472
0.033006
0.138351
0.12637
0.0628743
0.0423159
0.0446489
0.0418018
0.0384816
0.070868
0.0786368
0.0436083
0.0819163
0.0715145
0.0648623
0.033877
0.0500567
0.108278
0.0590097
0.0359529
0.0278881
0.059942
0.022022
0.0644617
0.0417186
0.138196
0.0894078
0.0312234
0.118108
0.13641
0.0370224
0.0874355
0.0740875
0.112037
0.037552
0.070916
0.0370061
0.052005
0.0647271
0.0410257
0.0226039
0.0858897
0.136134
0.0354201
0.0790753
0.00389007
0.0317714
0.0527591
0.0753602
0.033359
0.0523166
0.0158327
0.0370347
0.102405
0.0525101
0.101592
0.042334
0.13367
0.0454739
0.00829347
0.0376169
0.0570126
0.0373914
0.0682363
0.0557358
0.0562147
0.0343309
0.0673615
0.0389977
0.0196084
0.0185313
0.128675
0.0313076
0.0466657
0.0396742
0.0383776
0.0465559
0.0752896
0.0518587
0.0536836
0.0419764
0.216965
0.0385241
0.0541583
0.0528507
0.00168115
0.0138885
0.0541079
0.0325551
0.0606933
0.00903243
0.106211
0.131828
0.122314
0.0521177
0.0548904
0.0974468
0.0845465
0.00882048
0.0529313
0.0363835
0.0547332
0.00584998
0.0766423
0.0751752
0.0345805
0.0357978
0.112334
0.13867
0.0926178
0.0244072
0.00736367
0.136841
0.0333262
0.0874512
0.038363
0.0348478
0.0778886
0.0299828
0.059441
0.0728987
0.135873
0.105307
0.0601873
0.0534063
0.114401
0.0521423
0.0519927
0.075728
0.139692
0.0433191
0.0336727
0.127234
0.051473
0.138943
0.0486512
0.0306654
0.0204725
0.055011
0.0393365
0.0607158
0.0565117
0.087834
0.0336673
0.0308628
0.0528537
0.0988172
0.103229
0.0677439
0.037646
0.0476083
0.0523347
0.0357024
0.0526787
0.0529674
0.138186
0.0435688
0.0980964
0.136783
0.0264667
0.10281
0.0322659
0.0684231
0.0448891
0.0359173
0.0669507
0.0381039
0.057118
0.0295396
0.0738969
0.136987
0.0768652
0.0318908
0.0436499
0.0562314
0.0865293
0.128632
0.0950594
0.0471134
0.0766771
0.0464501
0.0271055
0.0311619
0.0798498
0.0344233
0.0330465
0.052793
0.163117
0.13912
0.0857704
0.139938
0.0836898
0.135783
0.00512193
0.135926
0.138234
0.137766
0.0676813
0.0380991
0.0299967
0.0578127
0.0388066
0.131892
0.0303393
0.00682576
0.0368968
0.0463157
0.0248099
0.0933002
0.139532
0.0874531
0.0326383
0.132091
0.0974329
0.0317989
0.00191651
0.139993
0.0358221
0.13437
0.131938
0.0258818
0.0304505
0.0471128
0.0366442
0.13838
0.0237419
0.0439842
0.124298
0.00524475
0.0880044
0.0795666
0.0335087
0.0863336
0.132912
0.0556907
0.0291077
0.133036
0.0902329
0.079039
0.0231532
0.0424197
0.108339
0.0774919
0.0768789
0.0562823
0.138588
0.13726
0.0541668
0.0342576
0.0350462
0.0313168
0.0820358
0.067036
0.108931
0.0288853
0.0660178
0.0382173
0.0348139
0.0413222
0.031433
0.0570671
0.0712389
0.118218
0.0967159
0.030326
0.0337008
0.135682
0.0960208
0.152351
0.0511039
0.138546
0.138641
0.0689502
0.139606
0.0760395
0.0575933
0.0436997
0.0431414
0.0391835
0.00331736
0.0603364
0.0927488
0.0348032
0.0339723
0.0696949
0.139118
0.138574
0.0242363
0.069749
0.0265343
0.0483428
0.0631619
0.0821808
0.00508014
0.0881091
0.0310404
0.0428258
0.0297331
0.0335434
0.0269624
0.041242
0.0409392
0.0401508
0.0679061
0.0903503
0.138579
0.0295461
0.050169
0.139225
0.117475
0.139442
0.138256
0.120349
0.135014
0.00966837
0.102396
0.138997
0.0280947
0.136572
0.124422
0.0367654
0.0475217
0.015972
0.336593
0.126266
0.0736614
0.0389874
0.0391841
0.1204
0.0456775
0.127017
0.0601992
0.0640415
0.0861813
0.0662334
0.103705
0.0492864
0.0550131
0.0788508
0.0221933
0.0353889
0.105844
0.0695935
0.0424094
0.0136646
0.172202
0.0310328
0.0456413
0.0956821
0.0804209
0.0204287
0.0352697
0.0323132
0.136168
0.0244285
0.139936
0.0438367
0.00125981
0.138021
0.0360752
0.0793033
0.107187
0.0562937
0.106394
0.0358949
0.117304
0.0337157
0.030551
0.0635986
0.0727605
0.135732
0.0326771
0.137677
0.0808191
0.0557021
0.385276
0.0494982
0.0303498
0.0676785
0.0452618
0.140109
0.0849866
0.0630952
0.042684
0.146969
0.137812
0.0950581
0.133923
0.0936437
0.143992
0.00965172
0.0413575
0.0265093
0.0297836
0.0517851
0.0123574
0.0407987
0.0386517
0.139827
0.0360244
0.026182
0.108205
0.0309132
0.0453564
0.121078
0.0554202
0.100539
0.0350439
0.0264335
0.128339
0.104098
0.0398608
0.0679153
0.0988758
0.0373161
0.00891704
0.0381155
0.0466286
0.0869369
0.0826612
0.0364047
0.0798107
0.0335176
0.133
0.106353
0.117596
0.049925
0.137124
0.0354753
0.0486484
0.0650839
0.0714413
0.0287366
0.039385
0.0575706
0.0506453
0.105822
0.0293991
0.0431758
0.0471436
0.0625856
0.0753497
0.0714253
0.0360912
0.0454132
0.0412207
0.0750062
0.0383138
0.0325539
0.0482045
0.0842242
0.0676225
0.0983798
0.0717763
0.0273924
0.0328852
0.0415831
0.0355334
0.120742
0.136096
0.0295491
0.130932
0.00305011
0.0480141
0.129781
0.0579334
0.075504
0.00634141
0.0337697
0.0646281
0.0295748
0.0663735
0.0898133
0.119705
0.0409178
0.0706724
0.0293844
0.0568264
0.139642
0.0386147
0.127292
0.033597
0.0114167
0.0472775
0.0798432
0.0387102
0.0392363
0.0724432
0.0652842
0.0818948
0.128931
0.0462301
0.0392452
0.00501257
0.0326069
0.121691
0.0318851
0.041977
0.0408466
0.0490528
0.0350455
0.0203204
0.0933565
0.00863784
0.0279621
0.0417543
0.0517402
0.137445
0.0854208
0.136652
0.0227716
0.0474971
0.0282059
0.0793063
0.0554311
0.140004
0.0793746
0.0440323
0.00277971
0.0329016
0.0320477
0.0303691
0.00373171
0.0742469
0.139984
0.0299612
0.139978
0.0833514
0.041192
0.0326755
0.148511
0.0319915
0.13951
0.0574767
0.137944
0.131623
0.0547065
0.0760549
0.0442497
0.0658738
0.0876449
0.0332323
0.0340205
0.0368603
0.0794622
0.140004
0.134159
0.130515
0.0302393
0.134049
0.123326
0.0417327
0.359323
0.0268639
0.136593
0.131959
0.00254206
0.0270008
0.0572441
0.120042
0.080281
0.0888292
0.0680774
0.122297
0.138555
0.139932
0.0506535
0.0728772
0.0532592
0.136867
0.137117
0.0771222
0.113832
0.130609
0.0694001
0.136868
0.0535676
0.0814409
0.0522138
0.0352039
0.0454925
0.0854545
0.0747785
0.0313733
0.0625683
0.0430801
0.0357383
0.120259
0.0421286
0.0371466
0.0998642
0.0163919
0.082034
0.135965
0.114756
0.0883668
0.0430598
0.120097
0.139026
0.094307
0.07145
0.0480579
0.082512
0.0364798
0.132827
0.0368547
0.0120822
0.0893944
0.028181
0.0474874
0.0775056
0.110923
0.0868178
0.0510904
0.0903311
0.0312033
0.078774
0.102578
0.0715091
0.0562858
0.0967985
0.0329079
0.0119426
0.122892
0.130954
0.103138
0.129824
0.0910184
0.0673653
0.0604255
0.079855
0.0280631
0.0467815
0.0571528
0.0339399
0.0381741
0.0365476
0.0540594
0.0351597
0.0351813
0.0456733
0.0682985
0.0746307
0.0598242
0.0735772
0.0859464
0.0297603
0.051108
0.0533631
0.0395351
0.122878
0.0690451
0.108959
0.0392088
0.036204
0.0219411
0.046036
0.0379093
0.0799729
0.10007
0.0934225
0.0409471
0.0516888
0.117103
0.0769948
0.139698
0.0710408
0.0753706
0.0566598
0.138724
0.0611126
0.137929
0.139173
0.0530849
0.376453
0.206236
0.00582501
0.055209
0.0497355
0.0346668
0.0310321
0.0365348
0.0319277
0.0777883
0.0282562
0.0545453
0.0656636
0.029382
0.0334229
0.0452984
0.129872
0.100125
0.0519219
0.0849412
0.135136
0.104888
0.142343
0.0371437
0.0301704
0.0740625
0.114937
0.0653235
0.075643
0.0271902
0.0513642
0.0475737
0.137939
0.0598619
0.0548799
0.050897
0.0509079
0.0195309
0.149791
0.121826
0.135904
0.0601281
0.00901655
0.0750804
0.0812532
0.0481935
0.0474135
0.126404
0.348437
0.13621
0.0754944
0.13805
0.0816335
0.0262728
0.138526
0.00177076
0.045119
0.0272722
0.100882
0.037913
0.0249003
0.0252318
0.0482427
0.0398508
0.0470803
0.0469309
0.029951
0.066777
0.128936
0.0351475
0.042936
0.0489138
0.0425138
0.0215491
0.122678
0.021904
0.122768
0.0400886
0.0299649
0.0413734
0.0873573
0.126917
0.0222667
0.0411992
0.108018
0.0316493
0.128588
0.03525
0.0268179
0.033058
0.0445586
0.00660267
0.0393443
0.0771253
0.220275
0.0484966
0.111274
0.0202657
0.133796
0.0320943
0.118486
0.377853
0.0295975
0.0825424
0.0312237
0.138897
0.0404155
0.0310203
0.139053
0.083534
0.0312281
0.0333123
0.0856674
0.133569
0.127422
0.034329
0.0550552
0.137201
0.0679616
0.0466377
0.0444446
0.11026
0.0807963
0.0240298
0.084687
0.0445389
0.134178
0.0393447
0.0603923
0.0339097
0.036745
0.138672
0.136454
0.13906
0.103326
0.138293
0.0490599
0.0806485
0.136511
0.0621502
0.136895
0.0789034
0.048966
0.138449
0.137683
0.103016
0.0660734
0.139987
0.0431173
0.110342
0.0390575
0.0760704
0.105667
0.043817
0.064218
0.0980684
0.0368613
0.0594342
0.138187
0.03433
0.0463928
0.0907629
0.0769513
0.0558982
0.137565
0.0299224
0.0732439
0.0559736
0.0762015
0.0618852
0.0108871
0.0397929
0.0838155
0.0304866
0.102757
0.0621709
0.0982457
0.127397
0.0221914
0.0552838
0.108688
0.138156
0.137272
0.0424935
0.108313
0.139009
0.047942
0.0196534
0.0308639
0.0329499
0.0227252
0.0792687
0.0383146
0.100811
0.036697
0.0324686
0.107558
0.0622272
0.0268617
0.132277
0.13048
0.0681547
0.0367904
0.148802
0.021962
0.0313203
0.0411243
0.130521
0.0894684
0.141424
0.122589
0.0571815
0.0312673
0.0792804
0.00297367
0.0330895
0.0443855
0.0535322
0.0586999
0.0684405
0.136885
0.0950379
0.0332816
0.0636275
0.0375551
0.0655343
0.0228501
0.134024
0.032272
0.123638
0.137392
0.123846
0.065781
0.0562704
0.133458
0.0726646
0.116457
0.0641533
0.0182163
0.0681432
0.119118
0.139734
0.0971435
0.147158
0.0880317
0.13825
0.0801072
0.0300868
0.0750845
0.0664748
0.137561
0.0365483
0.0530814
0.0105954
0.0762996
0.0322652
0.0359076
0.0813884
0.041522
0.040857
0.0551406
0.0354312
0.12519
0.0374237
0.060234
0.0694095
0.0389103
0.11966
0.0559523
0.137544
0.042948
0.125699
0.0678496
0.0298725
0.0469929
0.0397966
0.0640257
0.0618394
0.0884519
0.127828
0.0256769
0.134047
0.138316
0.0835779
0.0382718
0.044695
0.0176162
0.096797
0.053575
0.0548226
0.0964382
0.122057
0.0741702
0.138349
0.0463213
0.129715
0.123208
0.0649885
0.124959
0.0371451
0.0568354
0.124851
0.0461462
0.0704131
0.0912329
0.12861
0.170546
0.0899453
0.0870645
0.13384
0.0871856
0.0473831
0.0575742
0.12598
0.0313115
0.0632916
0.0346325
0.0339978
0.0794623
0.0771906
0.135671
0.0677282
0.089539
0.0644019
0.136769
0.0717206
0.122085
0.124668
0.131019
0.0815861
0.0567346
0.0893387
0.0331793
0.127988
0.0283425
0.0563809
0.0757489
0.136197
0.142354
0.137455
0.135463
0.0708048
0.0490033
0.107517
0.056301
0.0791775
0.084043
0.0403887
0.0483815
0.0215126
0.03259
0.0782622
0.137365
0.128666
0.130453
0.0852937
0.0318145
0.0306431
0.139095
0.250246
0.137713
0.0239549
0.0845611
0.027836
0.0085828
0.0350576
0.0575526
0.13005
0.117473
0.0676059
0.137683
0.0392855
0.0486948
0.0652092
0.044502
0.0463877
0.0353312
0.0287594
0.127422
0.0975052
0.126487
0.0405588
0.0407232
0.00829145
0.0353207
0.121456
0.0342375
0.0371558
0.00601805
0.126119
0.0898432
0.0282837
0.0280268
0.139102
0.1367
0.0747718
0.12932
0.134774
0.0769185
0.0550151
0.139981
0.0558543
0.0248612
0.137294
0.0560397
0.138392
0.034591
0.0742002
0.137729
0.13717
0.0639903
0.0852614
0.136256
0.13996
0.0288659
0.0336655
0.0655918
0.139999
0.0416644
0.0459464
0.0802733
0.0367108
0.120485
0.0286621
0.0391451
0.0341469
0.0778242
0.0287933
0.135939
0.0303145
0.0282547
0.0502366
0.13063
0.0304875
0.0252327
0.0690173
0.140006
0.0438903
0.0288006
0.0639526
0.034724
0.0595084
0.00643505
0.037584
0.0919874
0.0818767
0.136905
0.0693961
0.0995607
0.0460582
0.140744
0.0703886
0.0157191
0.062246
0.0325731
0.0786961
0.0415416
0.032242
0.0543283
0.0269677
0.105915
0.0366817
0.138266
0.0321188
0.0594951
0.022043
0.0299335
0.106154
0.0324496
0.136264
0.0329264
0.132434
0.133202
0.0440322
0.129286
0.072192
0.097587
0.0398669
0.058861
0.0510543
0.0438131
0.0703667
0.0399177
0.0163087
0.0447827
0.0587426
0.0592943
0.055853
0.0973947
0.092329
0.0124364
0.0433554
0.131778
0.0832523
0.0281347
0.110818
0.0389845
0.038884
0.0321213
0.0718982
0.131615
0.0814398
0.130356
0.0350084
0.133771
0.0497718
0.13432
0.0173294
0.0747686
0.118774
0.0338184
0.0599562
0.0360331
0.032363
0.0446866
0.035828
0.0867507
0.0968439
0.138177
0.122352
0.1153
0.0361436
0.123927
0.030432
0.134932
0.0221895
0.138843
0.0292606
0.0718779
0.0308723
0.0291195
0.0784943
0.0546829
0.0937968
0.0293238
0.0279656
0.0438207
0.0349314
0.0394175
0.0380603
0.128513
0.135852
0.070255
0.011527
0.0416099
0.0877686
0.13993
0.0465333
0.00467245
0.0294718
0.0382295
0.0491026
0.0972803
0.12879
0.0473092
0.0430384
0.0636295
0.0346209
0.0524957
0.031781
0.139263
0.0542047
0.068534
0.133897
0.0418616
0.0672712
0.0821413
0.137477
0.0339992
0.0417381
0.0269018
0.117888
0.0370907
0.0738909
0.0230786
0.135298
0.138682
0.0354633
0.0595769
0.13385
0.0416638
0.136556
0.0683127
0.033964
0.0318803
0.126254
0.115434
0.0767688
0.0329528
0.132528
0.0587999
0.132075
0.0805023
0.0618802
0.00803948
0.0505621
0.0886015
0.143183
0.120878
0.0797115
0.0104081
0.0689447
0.0268527
0.138115
0.0945797
0.138393
0.0298525
0.0128122
0.0469025
0.0258444
0.138277
0.126231
0.0782641
0.0676403
0.0572402
0.0304295
0.0666923
0.031673
0.0983138
0.0385337
0.130164
0.129525
0.040272
0.05697
0.13347
0.0570307
0.0966344
0.109331
0.0869965
0.0575507
0.0351552
0.136573
0.137408
0.116305
0.104606
0.0342892
0.0351124
0.111357
0.0934169
0.0830001
0.0566302
0.0688217
0.134735
0.136585
0.0386095
0.0342974
0.0505271
0.138471
0.0900653
0.0455451
0.0769366
0.0381178
0.0230553
0.125848
0.0725719
0.0415008
0.0578293
0.138927
0.0702426
0.0481862
0.0391872
0.0947935
0.0460813
0.058298
0.0446867
0.076412
0.0877221
0.0747714
0.0719959
0.0542158
0.0375315
0.0346407
0.0249963
0.0410651
0.0298779
0.0855773
0.123935
0.059831
0.0318784
0.127949
0.0467946
0.139724
0.0311868
0.121239
0.0821915
0.132231
0.135316
0.137286
0.138913
0.0403002
0.0677702
0.0356447
0.136695
0.0330477
0.0714631
0.0362887
0.0878394
0.0165192
0.028755
0.0838084
0.028117
0.0406351
0.154021
0.0377984
0.102309
0.0211322
0.124924
0.0288202
0.0597441
0.0164262
0.0719722
0.0562069
0.0309376
0.117566
0.0824654
0.102548
0.129363
0.102098
0.0915505
0.123591
0.0563708
0.070196
0.029325
0.137282
0.0465718
0.133653
0.0353349
0.117043
0.0691217
0.028343
0.00452383
0.150975
0.132371
0.138125
0.0652242
0.138258
0.0409655
0.0356399
0.108676
0.0310714
0.041453
0.130531
0.0673662
0.0633176
0.138226
0.132826
0.136185
0.0451219
0.0808157
0.0819492
0.0428194
0.00945116
0.0790854
0.0467891
0.0872531
0.0327225
0.133495
0.0299555
0.0915074
0.0325695
0.127584
0.135602
0.0272208
0.0213211
0.0782499
0.0336656
0.0366392
0.0617172
0.0300617
0.03436
0.0948999
0.0863492
0.130047
0.132538
0.032081
0.0478955
0.0476725
0.0774414
0.126269
0.047669
0.0877915
0.0953458
0.0681312
0.136993
0.0258274
0.0398289
0.101953
0.0643349
0.0161263
0.0380832
0.121398
0.0417312
0.0441454
0.130586
0.0925946
0.00158517
0.0336676
0.0347788
0.0704878
0.0537349
0.136884
0.135771
0.0589646
0.0379737
0.0730729
0.122562
0.0331768
0.0815349
0.136229
0.138001
0.133225
0.0935398
0.134096
0.0834638
0.0994279
0.0460403
0.0113346
0.0652395
0.119891
0.0668666
0.0274113
0.137987
0.0276726
0.0583532
0.108182
0.137609
0.136394
0.139088
0.0373139
0.023199
0.0933082
0.0871015
0.0175304
0.0468193
0.0171747
0.139022
0.13298
0.128598
0.0577913
0.0425358
0.0268365
0.0262566
0.0683668
0.130528
0.0612823
0.130834
0.0607775
0.0876738
0.0411976
0.0796042
0.0470423
0.128573
0.0339279
0.0423014
0.04329
0.0407444
0.0860454
0.067583
0.0285581
0.127481
0.0676311
0.137752
0.0422169
0.0861586
0.0724662
0.0448324
0.0355399
0.111312
0.096891
0.0286734
)
;
boundaryField
{
wings
{
type nutUSpaldingWallFunction;
Cmu 0.09;
kappa 0.41;
E 9.8;
value nonuniform List<scalar>
600
(
1.24672e-06
6.55201e-06
1.06279e-05
1.15807e-05
1.26316e-05
1.34462e-05
1.38821e-05
1.41493e-05
1.43462e-05
1.44787e-05
1.4558e-05
1.46055e-05
1.46259e-05
1.46241e-05
1.45989e-05
1.45645e-05
1.45238e-05
1.44809e-05
1.4436e-05
1.43941e-05
1.43549e-05
1.43124e-05
1.42706e-05
1.42261e-05
1.41809e-05
1.41373e-05
1.40908e-05
1.40464e-05
1.40013e-05
1.39622e-05
1.39253e-05
1.38896e-05
1.38512e-05
1.38121e-05
1.37761e-05
1.37404e-05
1.37063e-05
1.36692e-05
1.36308e-05
1.35956e-05
1.35616e-05
1.35305e-05
1.34976e-05
1.3464e-05
1.34334e-05
1.34044e-05
1.33749e-05
1.33456e-05
1.33168e-05
1.32886e-05
1.32602e-05
1.3232e-05
1.32048e-05
1.31778e-05
1.31519e-05
1.31264e-05
1.31012e-05
1.30767e-05
1.30526e-05
1.30289e-05
1.30055e-05
1.29824e-05
1.29597e-05
1.29371e-05
1.29147e-05
1.28928e-05
1.28714e-05
1.285e-05
1.28293e-05
1.2809e-05
1.27891e-05
1.27694e-05
1.27499e-05
1.27307e-05
1.27118e-05
1.2693e-05
1.26746e-05
1.26563e-05
1.26384e-05
1.26206e-05
1.2603e-05
1.25858e-05
1.25689e-05
1.25522e-05
1.25358e-05
1.25195e-05
1.25035e-05
1.24876e-05
1.24718e-05
1.24563e-05
1.24414e-05
1.24265e-05
1.24114e-05
1.23966e-05
1.2382e-05
1.23675e-05
1.23536e-05
1.23398e-05
1.23261e-05
1.23123e-05
1.22988e-05
1.22855e-05
1.22721e-05
1.22595e-05
1.22468e-05
1.22341e-05
1.22228e-05
1.22097e-05
1.21953e-05
1.21835e-05
1.21721e-05
1.21616e-05
1.21478e-05
1.21365e-05
1.21256e-05
1.2116e-05
1.21032e-05
1.20911e-05
1.20818e-05
1.20703e-05
1.20602e-05
1.20506e-05
1.20393e-05
1.20277e-05
1.20164e-05
1.20076e-05
1.19971e-05
1.19888e-05
1.19781e-05
1.19689e-05
1.19602e-05
1.19498e-05
1.19392e-05
1.19289e-05
1.19216e-05
1.19136e-05
1.19038e-05
1.18937e-05
1.18838e-05
1.18764e-05
1.18673e-05
1.18604e-05
1.1851e-05
1.18432e-05
1.18359e-05
1.18268e-05
1.18175e-05
1.18085e-05
1.18025e-05
1.17957e-05
1.17871e-05
1.17783e-05
1.17696e-05
1.17634e-05
1.17556e-05
1.17498e-05
1.17416e-05
1.17349e-05
1.17288e-05
1.17208e-05
1.17127e-05
1.17048e-05
1.16999e-05
1.16942e-05
1.16867e-05
1.1679e-05
1.16714e-05
1.16679e-05
1.16608e-05
1.16534e-05
1.16461e-05
1.16418e-05
1.16367e-05
1.16299e-05
1.16228e-05
1.16159e-05
1.1612e-05
1.16073e-05
1.16008e-05
1.1594e-05
1.15874e-05
1.1585e-05
1.15788e-05
1.15723e-05
1.1566e-05
1.15627e-05
1.15586e-05
1.15527e-05
1.15466e-05
1.15406e-05
1.15376e-05
1.15337e-05
1.15271e-05
1.15212e-05
1.15169e-05
1.15154e-05
1.15102e-05
1.15046e-05
1.14993e-05
1.14968e-05
1.14936e-05
1.14887e-05
1.14835e-05
1.14785e-05
1.14781e-05
1.14749e-05
1.14677e-05
1.14627e-05
1.14594e-05
1.14588e-05
1.14546e-05
1.14501e-05
1.14456e-05
1.14442e-05
1.1442e-05
1.14381e-05
1.14338e-05
1.14297e-05
1.14304e-05
1.14282e-05
1.14219e-05
1.1418e-05
1.14157e-05
1.14161e-05
1.1413e-05
1.14095e-05
1.14061e-05
1.14072e-05
1.14057e-05
1.14003e-05
1.13971e-05
1.13956e-05
1.13971e-05
1.13961e-05
1.13912e-05
1.13885e-05
1.13873e-05
1.13891e-05
1.13873e-05
1.13853e-05
1.13848e-05
1.1385e-05
1.13848e-05
1.13808e-05
1.13791e-05
1.13786e-05
1.13811e-05
1.13804e-05
1.13793e-05
1.13781e-05
1.13809e-05
1.13821e-05
1.13795e-05
1.1379e-05
1.13795e-05
1.1383e-05
1.13852e-05
1.13836e-05
1.13838e-05
1.1385e-05
1.13892e-05
1.13924e-05
1.13919e-05
1.13927e-05
1.13976e-05
1.14017e-05
1.14025e-05
1.1405e-05
1.1407e-05
1.14131e-05
1.14184e-05
1.142e-05
1.14234e-05
1.1428e-05
1.14358e-05
1.14429e-05
1.14465e-05
1.14519e-05
1.14596e-05
1.14702e-05
1.14779e-05
1.14837e-05
1.14928e-05
1.15057e-05
1.15183e-05
1.15279e-05
1.15399e-05
1.1554e-05
1.15724e-05
1.15912e-05
1.16079e-05
1.16283e-05
1.16531e-05
1.16834e-05
1.17154e-05
1.17472e-05
1.17982e-05
1.18398e-05
1.19587e-05
1.1955e-05
7.21904e-06
1.37942e-05
6.24792e-06
7.16501e-06
5.73269e-06
5.13194e-06
4.29696e-06
3.61596e-06
2.96381e-06
2.39053e-06
1.88211e-06
1.44311e-06
1.06971e-06
7.59858e-07
5.09551e-07
3.14443e-07
1.69123e-07
6.91327e-08
1.21466e-08
1.21461e-08
6.05136e-08
1.3231e-07
2.20572e-07
3.20719e-07
4.29877e-07
5.44993e-07
6.64085e-07
7.85707e-07
9.08046e-07
1.0306e-06
1.15192e-06
1.27205e-06
1.39016e-06
1.5061e-06
1.61906e-06
1.72921e-06
1.83694e-06
1.94177e-06
2.04447e-06
2.14405e-06
2.24051e-06
2.33497e-06
2.42692e-06
2.51717e-06
2.60435e-06
2.68959e-06
2.77273e-06
2.85377e-06
2.93273e-06
3.00985e-06
3.08493e-06
3.15816e-06
3.2295e-06
3.29897e-06
3.36665e-06
3.43273e-06
3.49706e-06
3.55976e-06
3.62082e-06
3.68045e-06
3.7385e-06
3.79514e-06
3.85034e-06
3.90407e-06
3.95648e-06
4.00771e-06
4.05753e-06
4.10614e-06
4.15364e-06
4.19996e-06
4.24506e-06
4.28912e-06
4.33212e-06
4.37409e-06
4.41508e-06
4.45508e-06
4.49415e-06
4.53228e-06
4.56956e-06
4.60588e-06
4.64151e-06
4.67618e-06
4.71021e-06
4.74337e-06
4.77583e-06
4.80762e-06
4.83873e-06
4.86903e-06
4.89863e-06
4.92768e-06
4.9561e-06
4.98391e-06
5.0111e-06
5.03772e-06
5.0638e-06
5.08935e-06
5.11437e-06
5.13886e-06
5.16287e-06
5.18638e-06
5.20931e-06
5.23186e-06
5.25388e-06
5.27564e-06
5.29688e-06
5.31742e-06
5.33774e-06
5.35763e-06
5.37805e-06
5.39732e-06
5.41548e-06
5.43402e-06
5.45197e-06
5.47052e-06
5.4873e-06
5.50448e-06
5.52122e-06
5.53848e-06
5.55449e-06
5.56958e-06
5.58594e-06
5.60093e-06
5.61605e-06
5.63122e-06
5.64571e-06
5.65952e-06
5.67255e-06
5.68711e-06
5.7003e-06
5.71433e-06
5.72677e-06
5.73961e-06
5.75257e-06
5.76489e-06
5.77655e-06
5.78748e-06
5.80004e-06
5.81193e-06
5.82319e-06
5.83384e-06
5.84373e-06
5.85525e-06
5.86544e-06
5.87655e-06
5.8861e-06
5.8961e-06
5.90628e-06
5.91587e-06
5.92485e-06
5.93313e-06
5.94311e-06
5.95247e-06
5.96123e-06
5.96942e-06
5.97689e-06
5.98605e-06
5.99391e-06
6.00212e-06
6.00903e-06
6.01772e-06
6.02578e-06
6.03324e-06
6.04012e-06
6.04632e-06
6.05428e-06
6.06163e-06
6.06842e-06
6.07467e-06
6.08032e-06
6.08793e-06
6.09428e-06
6.10003e-06
6.10511e-06
6.11199e-06
6.11828e-06
6.12401e-06
6.12923e-06
6.13374e-06
6.14007e-06
6.14581e-06
6.15102e-06
6.15569e-06
6.15978e-06
6.16587e-06
6.17071e-06
6.17498e-06
6.17857e-06
6.184e-06
6.18885e-06
6.19317e-06
6.19697e-06
6.20019e-06
6.20548e-06
6.21022e-06
6.2128e-06
6.21572e-06
6.21935e-06
6.22416e-06
6.22772e-06
6.23071e-06
6.23304e-06
6.23721e-06
6.24082e-06
6.24392e-06
6.2465e-06
6.24851e-06
6.2526e-06
6.25615e-06
6.25755e-06
6.25928e-06
6.26272e-06
6.26556e-06
6.26791e-06
6.26977e-06
6.27095e-06
6.274e-06
6.2765e-06
6.27848e-06
6.27995e-06
6.28086e-06
6.28386e-06
6.28634e-06
6.28647e-06
6.28714e-06
6.28954e-06
6.29134e-06
6.29266e-06
6.29334e-06
6.29358e-06
6.29591e-06
6.29778e-06
6.29703e-06
6.29707e-06
6.29789e-06
6.29993e-06
6.30147e-06
6.30028e-06
6.29994e-06
6.30133e-06
6.30147e-06
6.30166e-06
6.30094e-06
6.30119e-06
6.30264e-06
6.30357e-06
6.30151e-06
6.30044e-06
6.30031e-06
6.30141e-06
6.30097e-06
6.29955e-06
6.2981e-06
6.299e-06
6.29925e-06
6.29645e-06
6.29471e-06
6.29387e-06
6.2945e-06
6.2943e-06
6.29109e-06
6.28889e-06
6.28765e-06
6.28797e-06
6.28639e-06
6.28381e-06
6.28111e-06
6.27943e-06
6.27958e-06
6.27644e-06
6.27353e-06
6.27154e-06
6.27136e-06
6.26995e-06
6.26551e-06
6.26213e-06
6.25972e-06
6.25919e-06
6.25741e-06
6.2526e-06
6.24892e-06
6.24809e-06
6.24606e-06
6.24099e-06
6.23712e-06
6.23417e-06
6.23323e-06
6.23114e-06
6.22613e-06
6.22237e-06
6.21981e-06
6.21944e-06
6.21826e-06
6.21492e-06
6.21298e-06
6.21496e-06
6.21521e-06
6.22876e-06
6.20748e-06
6.33249e-06
5.97778e-06
)
;
}
outlet
{
type freestream;
freestreamValue uniform 0.14;
value nonuniform List<scalar>
20
(
0.246292
0.133497
0.423036
0.35449
0.121191
0.183557
0.398126
0.134259
0.136693
0.155954
0.135972
0.136154
0.0988533
0.136639
0.135638
0.132374
0.121763
0.138917
0.0920596
0.312308
)
;
}
tunnel
{
type nutUSpaldingWallFunction;
Cmu 0.09;
kappa 0.41;
E 9.8;
value nonuniform List<scalar>
40
(
0.00935304
0.00793456
0.0076888
0.00783843
0.0109367
0.0087777
0.00864509
0.00665811
0.00927889
0.0108391
0.0103729
0.00746271
0.0100521
0.0100049
0.00784726
0.0073448
0.00947415
0.0083085
0.00997483
0.00812123
0.0060398
0.00731349
0.0106791
0.00991472
0.00680318
0.00757962
0.00908766
0.00768115
0.00743822
0.00871614
0.00611758
0.0115975
0.00974315
0.0077269
0.00957058
0.00965779
0.00532722
0.00937875
0.00796279
0.00714147
)
;
}
inlet
{
type freestream;
freestreamValue uniform 0.14;
value uniform 0.14;
}
defaultFaces
{
type empty;
}
}
// ************************************************************************* //
| [
"[email protected]"
] | ||
1159c684e654e201f34f0fc83e7047263240f84b | de7e771699065ec21a340ada1060a3cf0bec3091 | /core/src/java/org/apache/lucene/analysis/tokenattributes/TermFrequencyAttributeImpl.cpp | cadaf084564d53b7be3302c4dfe7b9e660323ed0 | [] | no_license | sraihan73/Lucene- | 0d7290bacba05c33b8d5762e0a2a30c1ec8cf110 | 1fe2b48428dcbd1feb3e10202ec991a5ca0d54f3 | refs/heads/master | 2020-03-31T07:23:46.505891 | 2018-12-08T14:57:54 | 2018-12-08T14:57:54 | 152,020,180 | 7 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 1,777 | cpp | using namespace std;
#include "TermFrequencyAttributeImpl.h"
#include "../../util/AttributeReflector.h"
namespace org::apache::lucene::analysis::tokenattributes
{
using AttributeImpl = org::apache::lucene::util::AttributeImpl;
using AttributeReflector = org::apache::lucene::util::AttributeReflector;
TermFrequencyAttributeImpl::TermFrequencyAttributeImpl() {}
void TermFrequencyAttributeImpl::setTermFrequency(int termFrequency)
{
if (termFrequency < 1) {
throw invalid_argument(L"Term frequency must be 1 or greater; got " +
to_wstring(termFrequency));
}
this->termFrequency = termFrequency;
}
int TermFrequencyAttributeImpl::getTermFrequency() { return termFrequency; }
void TermFrequencyAttributeImpl::clear() { this->termFrequency = 1; }
void TermFrequencyAttributeImpl::end() { this->termFrequency = 1; }
bool TermFrequencyAttributeImpl::equals(any other)
{
if (other == shared_from_this()) {
return true;
}
if (std::dynamic_pointer_cast<TermFrequencyAttributeImpl>(other) != nullptr) {
shared_ptr<TermFrequencyAttributeImpl> _other =
any_cast<std::shared_ptr<TermFrequencyAttributeImpl>>(other);
return termFrequency == _other->termFrequency;
}
return false;
}
int TermFrequencyAttributeImpl::hashCode()
{
return Integer::hashCode(termFrequency);
}
void TermFrequencyAttributeImpl::copyTo(shared_ptr<AttributeImpl> target)
{
shared_ptr<TermFrequencyAttribute> t =
std::static_pointer_cast<TermFrequencyAttribute>(target);
t->setTermFrequency(termFrequency);
}
void TermFrequencyAttributeImpl::reflectWith(AttributeReflector reflector)
{
reflector(TermFrequencyAttribute::typeid, L"termFrequency", termFrequency);
}
} // namespace org::apache::lucene::analysis::tokenattributes | [
"[email protected]"
] | |
a31ce121137097d515165f2a3d0fce56b8536c77 | 00fe410ea9e57dfd09c5406d76ad0c700de936b3 | /AnalyzerExamples/USBAnalyzer/USBTypes.cpp | e71a46fa953cb416960fb6acab7564f0e95bcdf8 | [] | no_license | mitnad/RFFEAnalyzer | 56f0436b9e67b53cfea38fa25c434631955b8e90 | a05a4905a7cb2a06d4339b020afbc48b64a0a43c | refs/heads/master | 2021-05-29T11:08:24.505774 | 2015-07-31T20:40:57 | 2015-07-31T20:40:57 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 12,809 | cpp | #include <AnalyzerChannelData.h>
#include <AnalyzerHelpers.h>
#include <algorithm>
#include "USBAnalyzer.h"
#include "USBAnalyzerResults.h"
#include "USBTypes.h"
std::string GetPIDName(USB_PID pid)
{
switch (pid)
{
case PID_IN: return "IN";
case PID_OUT: return "OUT";
case PID_SOF: return "SOF";
case PID_SETUP: return "SETUP";
case PID_DATA0: return "DATA0";
case PID_DATA1: return "DATA1";
case PID_ACK: return "ACK";
case PID_NAK: return "NAK";
case PID_STALL: return "STALL";
case PID_PRE: return "PRE";
}
return "<invalid>";
}
void USBPacket::Clear()
{
data.clear();
bit_begin_samples.clear();
sample_begin = sample_end = 0;
PID = 0;
CRC = 0;
}
bool USBPacket::IsPIDValid() const
{
return PID == PID_IN
|| PID == PID_OUT
|| PID == PID_SOF
|| PID == PID_SETUP
|| PID == PID_DATA0
|| PID == PID_DATA1
|| PID == PID_ACK
|| PID == PID_NAK
|| PID == PID_STALL
|| PID == PID_PRE;
}
U8 USBPacket::CalcCRC5(U16 data)
{
U8 crc_register = 0x1f;
U8 polynom = 0x14; // 0b10100
U8 data_bit, crc_bit;
U16 shift_register;
// only the lower 11 bits of the 16 bit number
for (shift_register = 1; shift_register <= 0x400; shift_register <<= 1)
{
data_bit = (data & shift_register) ? 1 : 0;
crc_bit = crc_register & 1;
crc_register >>= 1;
if (data_bit ^ crc_bit)
crc_register ^= polynom;
}
return (~crc_register) & 0x1f;
}
U16 USBPacket::CalcCRC16() const
{
size_t counter;
U16 crc_register = 0xffff;
U16 polynom = 0xA001;
U8 shift_register, data_bit, crc_bit;
for (counter = 2; counter < data.size() - 2; counter++)
{
for (shift_register = 0x01; shift_register > 0x00; shift_register <<= 1)
{
data_bit = (data[counter] & shift_register) ? 1 : 0;
crc_bit = crc_register & 1;
crc_register >>= 1;
if (data_bit ^ crc_bit)
crc_register ^= polynom;
}
}
return ~crc_register;
}
U64 USBPacket::AddFrames(USBAnalyzerResults* pResults)
{
// make the analyzer frames for this packet
Frame f;
// SYNC
f.mStartingSampleInclusive = bit_begin_samples.front();
f.mEndingSampleInclusive = *(bit_begin_samples.begin() + 8);
f.mType = FT_SYNC;
f.mData1 = f.mData2 = 0;
f.mFlags = 0;
pResults->AddFrame(f);
// PID
f.mStartingSampleInclusive = *(bit_begin_samples.begin() + 8);
f.mEndingSampleInclusive = *(bit_begin_samples.begin() + 16);
f.mType = FT_PID;
f.mData1 = PID;
f.mData2 = 0;
f.mFlags = 0;
pResults->AddFrame(f);
// do the payload & CRC frames
if (IsTokenPacket() || IsSOFPacket())
{
// address/endpoint or frame number
f.mStartingSampleInclusive = *(bit_begin_samples.begin() + 16);
f.mEndingSampleInclusive = *(bit_begin_samples.begin() + 27);
// is this a SOF packet?
if (PID == PID_SOF)
{
f.mType = FT_FrameNum;
f.mData1 = GetFrameNum();
f.mData2 = 0;
} else {
f.mType = FT_AddrEndp;
f.mData1 = GetAddress();
f.mData2 = GetEndpoint();
}
pResults->AddFrame(f);
// CRC5
f.mStartingSampleInclusive = *(bit_begin_samples.begin() + 27);
f.mEndingSampleInclusive = bit_begin_samples.back();
f.mType = FT_CRC5;
f.mData1 = CRC;
f.mData2 = CalcCRC5(GetLastWord() & 0x7ff);
pResults->AddFrame(f);
} else if (IsDataPacket()) {
//debug("DATA: " + int2str(bit_begin_samples.back()));
// raw data
size_t bc;
f.mType = FT_Byte;
for (bc = 2; bc < data.size() - 2; ++bc)
{
f.mStartingSampleInclusive = *(bit_begin_samples.begin() + bc * 8);
f.mEndingSampleInclusive = *(bit_begin_samples.begin() + (bc + 1) * 8);
f.mData1 = data[bc];
pResults->AddFrame(f);
}
// CRC16
f.mStartingSampleInclusive = *(bit_begin_samples.end() - 17);
f.mEndingSampleInclusive = bit_begin_samples.back();
f.mType = FT_CRC16;
f.mData1 = CRC;
f.mData2 = CalcCRC16();
pResults->AddFrame(f);
}
// debug invalid CRCs
//if (data.size() > 2 && f.mData1 != f.mData2)
// debug("bad CRC " + GetPIDName((USB_PID) PID) + " " + int2str(bit_begin_samples.back()) + " rcvd: " + int2str(f.mData1) + " calc: " + int2str(f.mData2));
// add the EOP frame
f.mStartingSampleInclusive = bit_begin_samples.back();
// EOP is 2 bits SE0 and one bit J, so add another bit
f.mEndingSampleInclusive = sample_end;
f.mData1 = f.mData2 = 0;
f.mFlags = 0;
f.mType = FT_EOP;
pResults->AddFrame(f);
pResults->CommitResults();
return f.mEndingSampleInclusive;
}
U64 USBPacket::AddRawByteFrames(USBAnalyzerResults* pResults)
{
// raw data
size_t bc;
Frame f;
f.mType = FT_Byte;
f.mData2 = 0;
f.mFlags = 0;
std::string bytes_row;
for (bc = 0; bc < data.size(); ++bc)
{
bytes_row += int2str_sal(data[bc], Hexadecimal, 8) + ", ";
f.mStartingSampleInclusive = *(bit_begin_samples.begin() + bc * 8);
f.mEndingSampleInclusive = *(bit_begin_samples.begin() + (bc + 1) * 8);
f.mData1 = data[bc];
pResults->AddFrame(f);
}
// add the EOP frame
f.mStartingSampleInclusive = bit_begin_samples.back();
// EOP is 2 bits SE0 and one bit J, so add another bit
f.mEndingSampleInclusive = sample_end;
f.mData1 = f.mData2 = 0;
f.mFlags = 0;
f.mType = FT_EOP;
pResults->AddFrame(f);
pResults->CommitResults();
return f.mEndingSampleInclusive;
}
U64 USBPacket::AddErrorFrame(USBAnalyzerResults* pResults)
{
// add the Error frame -- parser can't decode the packet
Frame f;
f.mStartingSampleInclusive = sample_begin;
f.mEndingSampleInclusive = sample_end;
f.mData1 = f.mData2 = 0;
f.mFlags = 0;
f.mType = FT_Error;
pResults->AddFrame(f);
pResults->CommitResults();
return f.mEndingSampleInclusive;
}
void USBSignalState::AddFrame(USBAnalyzerResults* res)
{
Frame f;
f.mStartingSampleInclusive = sample_begin;
f.mEndingSampleInclusive = sample_end;
f.mType = FT_Signal;
f.mData1 = state;
f.mData2 = 0;
res->AddFrame(f);
res->CommitResults();
}
USBSignalFilter::USBSignalFilter(USBAnalyzer* pAnalyzer, USBAnalyzerResults* pResults, USBAnalyzerSettings* pSettings,
AnalyzerChannelData* pDP, AnalyzerChannelData* pDM, USBSpeed speed)
: mAnalyzer(pAnalyzer), mResults(pResults), mSettings(pSettings), mDP(pDP), mDM(pDM), mSpeed(speed),
mSampleDur(1e9 / mAnalyzer->GetSampleRate())
{
mStateStartSample = mDP->GetSampleNumber();
}
bool USBSignalFilter::SkipGlitch(AnalyzerChannelData* pChannel)
{
if (mSampleDur > 20 // sample rate < 50Mhz?
|| mSpeed == FULL_SPEED)
return false;
// up to 20ns
const int IGNORE_PULSE_SAMPLES = mSampleDur == 10 ? 2 : 1;
// skip the glitch
if (pChannel->WouldAdvancingCauseTransition(IGNORE_PULSE_SAMPLES))
{
//debug("start: " + int2str(pChannel->GetSampleNumber()));
pChannel->AdvanceToNextEdge();
//debug("end: " + int2str(pChannel->GetSampleNumber()));
return true;
}
return false;
}
U64 USBSignalFilter::DoFilter(AnalyzerChannelData* mDP, AnalyzerChannelData* mDM)
{
AnalyzerChannelData* pFurther;
AnalyzerChannelData* pNearer;
U64 next_edge_further;
U64 next_edge_nearer;
// this loop consumes all short (1 sample) pulses caused by noise
do {
if (mDP->GetSampleOfNextEdge() > mDM->GetSampleOfNextEdge())
pFurther = mDP, pNearer = mDM;
else
pFurther = mDM, pNearer = mDP;
next_edge_further = pFurther->GetSampleOfNextEdge();
next_edge_nearer = pNearer->GetSampleOfNextEdge();
pNearer->AdvanceToNextEdge();
pFurther->AdvanceToAbsPosition(next_edge_nearer);
} while (SkipGlitch(pNearer));
const int FILTER_THLD = mSettings->mSpeed == LOW_SPEED ? 200 : 50; // filtering threshold in ns
U64 diff_samples = next_edge_further - next_edge_nearer;
// if there's a pulse on pNearer and no transition on pFurther
if (!pNearer->WouldAdvancingToAbsPositionCauseTransition(next_edge_further)
// if the transitions happened withing FILTER_THLD time of eachother
&& diff_samples * mSampleDur <= FILTER_THLD)
{
for (;;)
{
pNearer->AdvanceToAbsPosition(next_edge_further);
pFurther->AdvanceToAbsPosition(next_edge_further);
if (!SkipGlitch(pFurther))
break;
//debug("time: " + mAnalyzer->GetTimeStr(pFurther->GetSampleNumber()) + " sample: " + int2str(pFurther->GetSampleNumber()));
pFurther->AdvanceToNextEdge();
next_edge_further = pFurther->GetSampleNumber();
}
// return the filtered position of the transition
return (next_edge_nearer + next_edge_further) / 2;
}
// return state up until the nearer transition
return next_edge_nearer;
}
USBSignalState USBSignalFilter::GetState()
{
USBSignalState ret_val;
ret_val.sample_begin = mStateStartSample;
// determine the USB signal state
BitState dp_state = mDP->GetBitState();
BitState dm_state = mDM->GetBitState();
if (dp_state == dm_state)
ret_val.state = dp_state == BIT_LOW ? S_SE0 : S_SE1;
else
ret_val.state = (mSpeed == LOW_SPEED ?
(dp_state == BIT_LOW ? S_J : S_K)
: (dp_state == BIT_LOW ? S_K : S_J));
// do the filtering and remember the sample begin for the next iteration
mStateStartSample = DoFilter(mDP, mDM);
ret_val.dur = (mStateStartSample - ret_val.sample_begin) * mSampleDur;
ret_val.sample_end = mStateStartSample;
return ret_val;
}
bool USBSignalFilter::HasMoreData()
{
return mDP->DoMoreTransitionsExistInCurrentData() || mDM->DoMoreTransitionsExistInCurrentData();
}
bool USBSignalFilter::GetPacket(USBPacket& pckt, USBSignalState& sgnl)
{
pckt.Clear();
const U8 bits2add[] = {0, 1, 1, 1, 1, 1, 1};
const double BIT_DUR = (mSpeed == FULL_SPEED ? FS_BIT_DUR : LS_BIT_DUR);
const double SAMPLE_DUR = 1e9 / mAnalyzer->GetSampleRate(); // 1 sample duration in ns
const double BIT_SAMPLES = BIT_DUR / SAMPLE_DUR;
std::vector<U8> bits;
pckt.sample_begin = sgnl.sample_begin; // default for bad packets
bool is_stuff_bit = false;
while (sgnl.IsData(mSpeed))
{
// get the number of bits in this signal
int num_bits = sgnl.GetNumBits(mSpeed);
const U8* add_begin = bits2add;
const U8* add_end = bits2add + num_bits;
// mind the stuffing bit
if (is_stuff_bit)
++add_begin;
// now add the data bits
bits.insert(bits.end(), add_begin, add_end);
// do the bit markers and remember the samples at which a bit begins
int bc;
for (bc = 0; bc < num_bits; ++bc)
{
if (!is_stuff_bit || bc > 0)
pckt.bit_begin_samples.push_back(sgnl.sample_begin + U64(BIT_SAMPLES * bc + .5));
mResults->AddMarker(sgnl.sample_begin + U64(BIT_SAMPLES * (bc + .5) + .5),
bc == 0 ? (is_stuff_bit ? AnalyzerResults::ErrorX : AnalyzerResults::Zero)
: AnalyzerResults::One,
mSettings->mDPChannel);
}
// set the stuff bit flag for the next state
is_stuff_bit = (num_bits == 7);
// get the next signal state
sgnl = GetState();
}
pckt.sample_end = sgnl.sample_end; // default for bad packets
// add another element to bit_begin_samples to mark the end of the last bit
pckt.bit_begin_samples.push_back(sgnl.sample_begin);
// check the number of bits
if (bits.empty()
|| (bits.size() % 8) != 0
|| (pckt.bit_begin_samples.size() % 8) != 1)
{
//debug("incorrect number of bits " + int2str(bits.size()));
return false;
}
// remember the begin & end samples for the entire packet
pckt.sample_begin = pckt.bit_begin_samples.front();
pckt.sample_end = sgnl.sample_end + S64(BIT_DUR / SAMPLE_DUR + 0.5);
// make bytes out of these bits
U8 val = 0;
std::vector<U8>::iterator i(bits.begin());
while (i != bits.end())
{
// least significant bit first
val >>= 1;
if (*i)
val |= 0x80;
++i;
// do we have a full byte?
if (((i - bits.begin()) % 8) == 0)
pckt.data.push_back(val);
}
// extract the PID
if (pckt.data.size() > 1)
pckt.PID = pckt.data[1];
// extract the CRC fields
if (pckt.data.size() >= 4)
{
U16 last_word = (pckt.data.back() << 8) | *(pckt.data.end() - 2);
if (pckt.data.size() == 4)
pckt.CRC = last_word >> 11;
else
pckt.CRC = last_word;
}
//debug("bit_begin_samples.size()=" + int2str(pckt.bit_begin_samples.size()));
//debug("data.size()=" + int2str(pckt.data.size()));
return (pckt.IsTokenPacket() && pckt.data.size() == 4)
|| (pckt.IsDataPacket() && pckt.data.size() >= 4)
|| (pckt.IsHandshakePacket() && pckt.data.size() == 2)
|| (pckt.IsSOFPacket() && pckt.data.size() == 4);
}
std::string int2str_sal(const U64 i, DisplayBase base, const int max_bits)
{
char number_str[256];
AnalyzerHelpers::GetNumberString(i, base, max_bits, number_str, sizeof(number_str));
return number_str;
} | [
"[email protected]"
] | |
d605268e4be432ce8730d4cc4ca1f08192489775 | db8eb39619ee8c4e45a21b9e538b27fabcf41561 | /Engine/Colors.h | c5d5b869d20b66650fcc523e4f523e194982b43f | [] | no_license | EnDronist/BreakOut-Engine | 7596eb292d18cb784ee3257ab6d63214ec7c1036 | 3e9b75a3b6ab4fe5c0fbba4f67f2b6e8ed4e694b | refs/heads/master | 2021-08-01T07:17:49.359665 | 2021-07-30T04:56:29 | 2021-07-30T04:56:29 | 199,389,111 | 1 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 3,816 | h | /******************************************************************************************
* Chili DirectX Framework Version 16.07.20 *
* Colors.h *
* Copyright 2016 PlanetChili <http://www.planetchili.net> *
* *
* This file is part of The Chili DirectX Framework. *
* *
* The Chili DirectX Framework 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 3 of the License, or *
* (at your option) any later version. *
* *
* The Chili DirectX Framework 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 The Chili DirectX Framework. If not, see <http://www.gnu.org/licenses/>. *
******************************************************************************************/
#pragma once
#include <string>
class Color {
public:
unsigned int dword;
public:
constexpr Color(): dword() {}
constexpr Color(const Color& col):
dword(col.dword) {
}
constexpr Color(unsigned int dw):
dword(dw) {
}
constexpr Color(unsigned char x, unsigned char r, unsigned char g, unsigned char b):
dword((x << 24u) | (r << 16u) | (g << 8u) | b) {
}
constexpr Color(unsigned char r, unsigned char g, unsigned char b):
dword((r << 16u) | (g << 8u) | b) {
}
constexpr Color(Color col, unsigned char x):
Color((x << 24u) | col.dword) {
}
Color& operator =(Color color) {
dword = color.dword;
return *this;
}
bool operator==(const Color& rhs) const {
return dword == rhs.dword;
}
bool operator!=(const Color& rhs) const {
return !(*this == rhs);
}
constexpr unsigned char GetX() const {
return dword >> 24u;
}
constexpr unsigned char GetA() const {
return GetX();
}
constexpr unsigned char GetR() const {
return (dword >> 16u) & 0xFFu;
}
constexpr unsigned char GetG() const {
return (dword >> 8u) & 0xFFu;
}
constexpr unsigned char GetB() const {
return dword & 0xFFu;
}
void SetX(unsigned char x) {
dword = (dword & 0xFFFFFFu) | (x << 24u);
}
void SetA(unsigned char a) {
SetX(a);
}
void SetR(unsigned char r) {
dword = (dword & 0xFF00FFFFu) | (r << 16u);
}
void SetG(unsigned char g) {
dword = (dword & 0xFFFF00FFu) | (g << 8u);
}
void SetB(unsigned char b) {
dword = (dword & 0xFFFFFF00u) | b;
}
void ToString(std::string &object_text) {
// unsigned int dword
object_text += std::to_string(dword); object_text += " ";
}
void FromString(std::string &object_text) {
// unsigned int dword
this->dword = (unsigned int)atoi(object_text.substr(size_t(0), object_text.find(' ')).c_str());
object_text.erase(0, object_text.find(' ') + 1);
}
};
namespace Colors {
static constexpr Color MakeRGB(unsigned char r, unsigned char g, unsigned char b) {
return (r << 16) | (g << 8) | b;
}
static constexpr Color White = MakeRGB(255u, 255u, 255u);
static constexpr Color Black = MakeRGB(0u, 0u, 0u);
static constexpr Color Gray = MakeRGB(0x80u, 0x80u, 0x80u);
static constexpr Color LightGray = MakeRGB(0xD3u, 0xD3u, 0xD3u);
static constexpr Color Red = MakeRGB(255u, 0u, 0u);
static constexpr Color Green = MakeRGB(0u, 255u, 0u);
static constexpr Color Blue = MakeRGB(0u, 0u, 255u);
static constexpr Color Yellow = MakeRGB(255u, 255u, 0u);
static constexpr Color Cyan = MakeRGB(0u, 255u, 255u);
static constexpr Color Magenta = MakeRGB(255u, 0u, 255u);
} | [
"[email protected]"
] | |
60cd36fc44f8cea6cb6c0d23c73a269896eb44b6 | d93fe00111f8072d803f7d13a576ce77267b9fd0 | /src/zmq/zmqpublishnotifier.cpp | 4aa9f1b9074b7a4a8d605d326debb9133e793fef | [
"MIT"
] | permissive | yiya-core/yiya-core | 279dcb00f6eb94bdd7eadee4e197565a9f5ecf5f | 54bdc5c72f6d760cb3ec840f202c289bccd03ccd | refs/heads/master | 2020-08-07T15:06:30.855194 | 2019-10-14T20:25:18 | 2019-10-14T20:25:18 | 213,237,061 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 5,737 | cpp | // Copyright (c) 2015-2016 The Bitcoin Core developers
// Copyright (c) 2019 The Yiya Core developers
// Distributed under the MIT software license, see the accompanying
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
#include "chain.h"
#include "chainparams.h"
#include "streams.h"
#include "zmqpublishnotifier.h"
#include "validation.h"
#include "util.h"
#include "rpc/server.h"
static std::multimap<std::string, CZMQAbstractPublishNotifier*> mapPublishNotifiers;
static const char *MSG_HASHBLOCK = "hashblock";
static const char *MSG_HASHTX = "hashtx";
static const char *MSG_RAWBLOCK = "rawblock";
static const char *MSG_RAWTX = "rawtx";
// Internal function to send multipart message
static int zmq_send_multipart(void *sock, const void* data, size_t size, ...)
{
va_list args;
va_start(args, size);
while (1)
{
zmq_msg_t msg;
int rc = zmq_msg_init_size(&msg, size);
if (rc != 0)
{
zmqError("Unable to initialize ZMQ msg");
va_end(args);
return -1;
}
void *buf = zmq_msg_data(&msg);
memcpy(buf, data, size);
data = va_arg(args, const void*);
rc = zmq_msg_send(&msg, sock, data ? ZMQ_SNDMORE : 0);
if (rc == -1)
{
zmqError("Unable to send ZMQ msg");
zmq_msg_close(&msg);
va_end(args);
return -1;
}
zmq_msg_close(&msg);
if (!data)
break;
size = va_arg(args, size_t);
}
va_end(args);
return 0;
}
bool CZMQAbstractPublishNotifier::Initialize(void *pcontext)
{
assert(!psocket);
// check if address is being used by other publish notifier
std::multimap<std::string, CZMQAbstractPublishNotifier*>::iterator i = mapPublishNotifiers.find(address);
if (i==mapPublishNotifiers.end())
{
psocket = zmq_socket(pcontext, ZMQ_PUB);
if (!psocket)
{
zmqError("Failed to create socket");
return false;
}
int rc = zmq_bind(psocket, address.c_str());
if (rc!=0)
{
zmqError("Failed to bind address");
zmq_close(psocket);
return false;
}
// register this notifier for the address, so it can be reused for other publish notifier
mapPublishNotifiers.insert(std::make_pair(address, this));
return true;
}
else
{
LogPrint(BCLog::ZMQ, "zmq: Reusing socket for address %s\n", address);
psocket = i->second->psocket;
mapPublishNotifiers.insert(std::make_pair(address, this));
return true;
}
}
void CZMQAbstractPublishNotifier::Shutdown()
{
assert(psocket);
int count = mapPublishNotifiers.count(address);
// remove this notifier from the list of publishers using this address
typedef std::multimap<std::string, CZMQAbstractPublishNotifier*>::iterator iterator;
std::pair<iterator, iterator> iterpair = mapPublishNotifiers.equal_range(address);
for (iterator it = iterpair.first; it != iterpair.second; ++it)
{
if (it->second==this)
{
mapPublishNotifiers.erase(it);
break;
}
}
if (count == 1)
{
LogPrint(BCLog::ZMQ, "Close socket at address %s\n", address);
int linger = 0;
zmq_setsockopt(psocket, ZMQ_LINGER, &linger, sizeof(linger));
zmq_close(psocket);
}
psocket = nullptr;
}
bool CZMQAbstractPublishNotifier::SendMessage(const char *command, const void* data, size_t size)
{
assert(psocket);
/* send three parts, command & data & a LE 4byte sequence number */
unsigned char msgseq[sizeof(uint32_t)];
WriteLE32(&msgseq[0], nSequence);
int rc = zmq_send_multipart(psocket, command, strlen(command), data, size, msgseq, (size_t)sizeof(uint32_t), nullptr);
if (rc == -1)
return false;
/* increment memory only sequence number after sending */
nSequence++;
return true;
}
bool CZMQPublishHashBlockNotifier::NotifyBlock(const CBlockIndex *pindex)
{
uint256 hash = pindex->GetBlockHash();
LogPrint(BCLog::ZMQ, "zmq: Publish hashblock %s\n", hash.GetHex());
char data[32];
for (unsigned int i = 0; i < 32; i++)
data[31 - i] = hash.begin()[i];
return SendMessage(MSG_HASHBLOCK, data, 32);
}
bool CZMQPublishHashTransactionNotifier::NotifyTransaction(const CTransaction &transaction)
{
uint256 hash = transaction.GetHash();
LogPrint(BCLog::ZMQ, "zmq: Publish hashtx %s\n", hash.GetHex());
char data[32];
for (unsigned int i = 0; i < 32; i++)
data[31 - i] = hash.begin()[i];
return SendMessage(MSG_HASHTX, data, 32);
}
bool CZMQPublishRawBlockNotifier::NotifyBlock(const CBlockIndex *pindex)
{
LogPrint(BCLog::ZMQ, "zmq: Publish rawblock %s\n", pindex->GetBlockHash().GetHex());
const Consensus::ConsensusParams& consensusParams = Params().GetConsensus();
CDataStream ss(SER_NETWORK, PROTOCOL_VERSION | RPCSerializationFlags());
{
LOCK(cs_main);
CBlock block;
if(!ReadBlockFromDisk(block, pindex, consensusParams))
{
zmqError("Can't read block from disk");
return false;
}
ss << block;
}
return SendMessage(MSG_RAWBLOCK, &(*ss.begin()), ss.size());
}
bool CZMQPublishRawTransactionNotifier::NotifyTransaction(const CTransaction &transaction)
{
uint256 hash = transaction.GetHash();
LogPrint(BCLog::ZMQ, "zmq: Publish rawtx %s\n", hash.GetHex());
CDataStream ss(SER_NETWORK, PROTOCOL_VERSION | RPCSerializationFlags());
ss << transaction;
return SendMessage(MSG_RAWTX, &(*ss.begin()), ss.size());
}
| [
"[email protected]"
] | |
07cb46addb3cbd02f2e54b7c5c510d147f9d48d7 | 1a981ff15c2ceabbb6d6bb0caeacb0e6df3afff9 | /src/Shared/Level/Dungeon.cpp | 030fad0c336b7839ffba65ec69a1822021faa7eb | [
"MIT"
] | permissive | alexismartin/NecroEdit | 186ca6e3ea21556ba579e9bffad3a105972a3742 | 1684847c7d4423eba2a28c789cd1a282a2236b91 | refs/heads/master | 2021-01-22T02:57:41.648431 | 2016-05-06T23:14:10 | 2016-05-06T23:14:10 | 56,936,528 | 0 | 0 | null | 2016-04-23T19:15:38 | 2016-04-23T19:15:38 | null | UTF-8 | C++ | false | false | 8,524 | cpp | #include <boost/filesystem/path.hpp>
#include <SFML/System/Vector2.hpp>
#include <Shared/External/PugiXML/pugixml.hpp>
#include <Shared/Level/Dungeon.hpp>
#include <Shared/Level/Level.hpp>
#include <Shared/Level/Tile.hpp>
#include <Shared/Utils/MakeUnique.hpp>
#include <Shared/Utils/Utilities.hpp>
#include <algorithm>
#include <cstring>
#include <iostream>
#include <iterator>
#include <map>
#include <stdexcept>
Dungeon::Dungeon() :
playerCharacter(0),
startItemsEnabled(true)
{
}
Dungeon::~Dungeon()
{
}
void Dungeon::insertLevel(std::size_t index)
{
if (index > levels.size())
{
return;
}
levels.insert(levels.begin() + index, makeUnique<Level>());
}
void Dungeon::removeLevel(std::size_t index)
{
if (index >= levels.size())
{
return;
}
levels.erase(levels.begin() + index);
}
void Dungeon::swapLevels(std::size_t indexA, std::size_t indexB)
{
if (indexA == indexB || indexA >= levels.size() || indexB >= levels.size())
{
return;
}
std::swap(levels[indexA], levels[indexB]);
}
std::size_t Dungeon::getLevelCount() const
{
return levels.size();
}
Level& Dungeon::getLevel(std::size_t index) const
{
if (index >= levels.size())
{
throw(std::out_of_range("Level " + std::to_string(index) + " does not exist."));
}
return *levels[index];
}
void Dungeon::setPlayerCharacter(int character)
{
playerCharacter = character;
}
int Dungeon::getPlayerCharacter() const
{
return playerCharacter;
}
void Dungeon::setStartItemsEnabled(bool enabled)
{
startItemsEnabled = enabled;
}
bool Dungeon::isStartItemsEnabled() const
{
return startItemsEnabled;
}
static const std::vector<Object::Type> OBJECT_TYPE_ORDER = { Object::Type::Trap, Object::Type::Enemy,
Object::Type::Item, Object::Type::Chest, Object::Type::Crate, Object::Type::Shrine };
bool Dungeon::loadFromXML(const std::string& filename)
{
// Create string to read dungeon file from.
std::string xmlData = readFile(filename);
// Create document to read the dungeon's data into.
pugi::xml_document doc;
// Parse dungeon XML from file contents.
pugi::xml_parse_result result = doc.load_buffer(xmlData.data(), xmlData.size());
// Check if parsing was successful.
if (!result)
{
return false;
}
pugi::xml_node dungeonNode = doc.root().child("dungeon");
if (dungeonNode.empty())
{
return false;
}
levels.clear();
int characterID = dungeonNode.attribute("character").as_int(-1);
if (characterID >= 999)
{
characterID -= 1000;
startItemsEnabled = false;
}
else
{
startItemsEnabled = true;
}
playerCharacter = characterID;
name = dungeonNode.attribute("name").as_string(boost::filesystem::path(filename).stem().string().c_str());
std::size_t levelCount = dungeonNode.attribute("numLevels").as_uint(0);
for (std::size_t i = 0; i < levelCount; ++i)
{
insertLevel(i);
}
// Loop over all levels in the XML.
for (const auto & levelNode : dungeonNode)
{
int levelID = levelNode.attribute("num").as_int(0) - 1;
if (levelID == -1 || levelID >= int(levels.size()))
{
continue;
}
Level & level = getLevel(levelID);
level.setBoss(levelNode.attribute("boss").as_int(-1));
level.setMusic(levelNode.attribute("music").as_int(0));
// Load tiles.
loadTiles(levelNode, levelID);
// Load objects.
for (Object::Type type : OBJECT_TYPE_ORDER)
{
loadObjects(levelNode, levelID, type);
}
}
return true;
}
void Dungeon::loadTiles(const pugi::xml_node& levelNode, std::size_t levelNumber)
{
Level & level = getLevel(levelNumber);
for (const auto & tileNode : levelNode.child("tiles"))
{
sf::Vector2i position(tileNode.attribute("x").as_int(0), tileNode.attribute("y").as_int(0));
Tile tile;
tile.id = tileNode.attribute("type").as_int(Tile::Invalid);
tile.hasTorch = tileNode.attribute("torch").as_bool(false);
tile.variant = Tile::Variant(tileNode.attribute("zone").as_int(0));
if (tileNode.attribute("cracked").as_bool(false))
{
tile.setCracked(true);
}
level.setTileAt(position, tile);
}
}
void Dungeon::loadObjects(const pugi::xml_node& levelNode, std::size_t levelNumber, Object::Type objectType)
{
Level & level = getLevel(levelNumber);
for (const auto & objectNode : levelNode.child(Object::getTypeNamePlural(objectType)))
{
sf::Vector2i position(objectNode.attribute("x").as_int(0), objectNode.attribute("y").as_int(0));
Object & object = level.getObject(level.addObject(objectType));
object.setPosition(position);
for (auto attrib = objectNode.attributes_begin(); attrib != objectNode.attributes_end(); ++attrib)
{
// Get name and (string) value of current property.
Object::Property propertyKey = Object::getPropertyByName(attrib->name());
// Ignore unknown attributes (including position).
if (propertyKey == Object::Property::Invalid)
{
continue;
}
const char * propertyValue = attrib->value();
// Assign property as string. Conversion into number is done later if necessary.
object.setPropertyString(propertyKey, propertyValue);
}
}
}
bool Dungeon::saveToXML(const std::string& filename) const
{
// Create document to generate the dungeon's data in.
pugi::xml_document doc;
// Create dungeon node.
pugi::xml_node dungeonNode = doc.root().append_child("dungeon");
// Add dungeon attributes.
dungeonNode.append_attribute("character").set_value(playerCharacter + (isStartItemsEnabled() ? 0 : 1000));
dungeonNode.append_attribute("name").set_value(name.c_str());
dungeonNode.append_attribute("numLevels").set_value((int) levels.size());
// Add levels.
for (std::size_t levelID = 0; levelID < levels.size(); ++levelID)
{
// Select current level.
Level & level = getLevel(levelID);
// Create level node.
pugi::xml_node levelNode = dungeonNode.append_child("level");
// Add level attributes.
levelNode.append_attribute("bossNum").set_value(level.getBoss());
levelNode.append_attribute("music").set_value(level.getMusic());
levelNode.append_attribute("num").set_value((int) levelID + 1);
// Save various components (tiles and objects) of the level.
saveTiles(levelNode, levelID);
saveObjects(levelNode, levelID);
}
// Save document to file.
return doc.save_file(filename.c_str());
}
void Dungeon::saveTiles(pugi::xml_node& levelNode, std::size_t levelNumber) const
{
// Create tiles node.
pugi::xml_node tilesNode = levelNode.append_child("tiles");
Level & level = getLevel(levelNumber);
sf::Vector2i playerSpawn = level.getPlayerSpawnPoint();
// Loop over all tiles in the level.
for (auto it = level.tilesBegin(); it != level.tilesEnd(); ++it)
{
// Create tile node.
pugi::xml_node tileNode = tilesNode.append_child("tile");
// Get tile at current iterator position.
const Tile & tile = level.getTileAt(*it);
// Assign attributes.
tileNode.append_attribute("x").set_value(it->x - playerSpawn.x);
tileNode.append_attribute("y").set_value(it->y - playerSpawn.y);
tileNode.append_attribute("type").set_value(tile.id);
tileNode.append_attribute("zone").set_value(tile.getZone());
tileNode.append_attribute("torch").set_value(tile.hasTorch ? 1 : 0);
tileNode.append_attribute("cracked").set_value(tile.isCracked() ? 1 : 0);
}
}
void Dungeon::saveObjects(pugi::xml_node& levelNode, std::size_t levelNumber) const
{
std::vector<pugi::xml_node> objectNodes;
for (Object::Type type : OBJECT_TYPE_ORDER)
{
if ((int) type < 0)
{
continue;
}
objectNodes.resize(std::max<std::size_t>(objectNodes.size(), (std::size_t) type + 1));
objectNodes[(std::size_t) type] = levelNode.append_child(Object::getTypeNamePlural(type));
}
Level & level = getLevel(levelNumber);
sf::Vector2i playerSpawn = level.getPlayerSpawnPoint();
// Loop over all objects in the level.
for (auto it = level.objectsBegin(); it != level.objectsEnd(); ++it)
{
if ((int) it->getType() >= (int) objectNodes.size() || (int) it->getType() < 0)
{
continue;
}
// Create object node.
pugi::xml_node objectNode = objectNodes[(std::size_t) it->getType()].append_child(
Object::getTypeName(it->getType()));
// Assign common attributes.
objectNode.append_attribute("x").set_value(it->getPosition().x - playerSpawn.x);
objectNode.append_attribute("y").set_value(it->getPosition().y - playerSpawn.y);
// Assign properties.
for (auto itProp = it->getAllProperties().begin(); itProp != it->getAllProperties().end(); ++itProp)
{
const char * propertyName = Object::getPropertyName(itProp->first);
objectNode.append_attribute(propertyName).set_value(itProp->second.c_str());
}
}
}
| [
"[email protected]"
] | |
a631c4151970d940a242f37e903edf0f3f304303 | 0d07ac8085bcb005d243fc315170727620ea4297 | /src/qt/receivecoinsdialog.cpp | 50e686121ec9a21c90f78fd4461897c16b9f15c7 | [
"MIT"
] | permissive | dsdsenen/Dividend | cde017d2e34d5e63db1fbe670884146f287df058 | d6f32603a78df27e7b32da7f9a22fa932beea75a | refs/heads/master | 2020-03-25T01:25:27.374964 | 2018-08-02T14:46:50 | 2018-08-02T14:46:50 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 9,354 | cpp | // Copyright (c) 2011-2014 The Bitcoin developers
// Copyright (c) 2017 The PIVX developers
// Copyright (c) 2017 The Dividend developers
// Distributed under the MIT/X11 software license, see the accompanying
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
#include "receivecoinsdialog.h"
#include "ui_receivecoinsdialog.h"
#include "addressbookpage.h"
#include "addresstablemodel.h"
#include "bitcoinunits.h"
#include "guiutil.h"
#include "optionsmodel.h"
#include "receiverequestdialog.h"
#include "recentrequeststablemodel.h"
#include "walletmodel.h"
#include <QAction>
#include <QCursor>
#include <QItemSelection>
#include <QMessageBox>
#include <QScrollBar>
#include <QTextDocument>
ReceiveCoinsDialog::ReceiveCoinsDialog(QWidget* parent) : QDialog(parent, Qt::WindowSystemMenuHint | Qt::WindowTitleHint | Qt::WindowCloseButtonHint),
ui(new Ui::ReceiveCoinsDialog),
model(0)
{
ui->setupUi(this);
#ifdef Q_OS_MAC // Icons on push buttons are very uncommon on Mac
ui->clearButton->setIcon(QIcon());
ui->receiveButton->setIcon(QIcon());
ui->showRequestButton->setIcon(QIcon());
ui->removeRequestButton->setIcon(QIcon());
#endif
// context menu actions
QAction* copyLabelAction = new QAction(tr("Copy label"), this);
QAction* copyMessageAction = new QAction(tr("Copy message"), this);
QAction* copyAmountAction = new QAction(tr("Copy amount"), this);
// context menu
contextMenu = new QMenu();
contextMenu->addAction(copyLabelAction);
contextMenu->addAction(copyMessageAction);
contextMenu->addAction(copyAmountAction);
// context menu signals
connect(ui->recentRequestsView, SIGNAL(customContextMenuRequested(QPoint)), this, SLOT(showMenu(QPoint)));
connect(copyLabelAction, SIGNAL(triggered()), this, SLOT(copyLabel()));
connect(copyMessageAction, SIGNAL(triggered()), this, SLOT(copyMessage()));
connect(copyAmountAction, SIGNAL(triggered()), this, SLOT(copyAmount()));
connect(ui->clearButton, SIGNAL(clicked()), this, SLOT(clear()));
}
void ReceiveCoinsDialog::setModel(WalletModel* model)
{
this->model = model;
if (model && model->getOptionsModel()) {
model->getRecentRequestsTableModel()->sort(RecentRequestsTableModel::Date, Qt::DescendingOrder);
connect(model->getOptionsModel(), SIGNAL(displayUnitChanged(int)), this, SLOT(updateDisplayUnit()));
updateDisplayUnit();
QTableView* tableView = ui->recentRequestsView;
tableView->verticalHeader()->hide();
tableView->setHorizontalScrollBarPolicy(Qt::ScrollBarAlwaysOff);
tableView->setModel(model->getRecentRequestsTableModel());
tableView->setAlternatingRowColors(true);
tableView->setSelectionBehavior(QAbstractItemView::SelectRows);
tableView->setSelectionMode(QAbstractItemView::ContiguousSelection);
tableView->setColumnWidth(RecentRequestsTableModel::Date, DATE_COLUMN_WIDTH);
tableView->setColumnWidth(RecentRequestsTableModel::Label, LABEL_COLUMN_WIDTH);
connect(tableView->selectionModel(),
SIGNAL(selectionChanged(QItemSelection, QItemSelection)), this,
SLOT(recentRequestsView_selectionChanged(QItemSelection, QItemSelection)));
// Last 2 columns are set by the columnResizingFixer, when the table geometry is ready.
columnResizingFixer = new GUIUtil::TableViewLastColumnResizingFixer(tableView, AMOUNT_MINIMUM_COLUMN_WIDTH, DATE_COLUMN_WIDTH);
}
}
ReceiveCoinsDialog::~ReceiveCoinsDialog()
{
delete ui;
}
void ReceiveCoinsDialog::clear()
{
ui->reqAmount->clear();
ui->reqLabel->setText("");
ui->reqMessage->setText("");
ui->reuseAddress->setChecked(false);
updateDisplayUnit();
}
void ReceiveCoinsDialog::reject()
{
clear();
}
void ReceiveCoinsDialog::accept()
{
clear();
}
void ReceiveCoinsDialog::updateDisplayUnit()
{
if (model && model->getOptionsModel()) {
ui->reqAmount->setDisplayUnit(model->getOptionsModel()->getDisplayUnit());
}
}
void ReceiveCoinsDialog::on_receiveButton_clicked()
{
if (!model || !model->getOptionsModel() || !model->getAddressTableModel() || !model->getRecentRequestsTableModel())
return;
QString address;
QString label = ui->reqLabel->text();
if (ui->reuseAddress->isChecked()) {
/* Choose existing receiving address */
AddressBookPage dlg(AddressBookPage::ForSelection, AddressBookPage::ReceivingTab, this);
dlg.setModel(model->getAddressTableModel());
if (dlg.exec()) {
address = dlg.getReturnValue();
if (label.isEmpty()) /* If no label provided, use the previously used label */
{
label = model->getAddressTableModel()->labelForAddress(address);
}
} else {
return;
}
} else {
/* Generate new receiving address */
address = model->getAddressTableModel()->addRow(AddressTableModel::Receive, label, "");
}
SendCoinsRecipient info(address, label,
ui->reqAmount->value(), ui->reqMessage->text());
ReceiveRequestDialog* dialog = new ReceiveRequestDialog(this);
dialog->setAttribute(Qt::WA_DeleteOnClose);
dialog->setModel(model->getOptionsModel());
dialog->setInfo(info);
dialog->show();
clear();
/* Store request for later reference */
model->getRecentRequestsTableModel()->addNewRequest(info);
}
void ReceiveCoinsDialog::on_recentRequestsView_doubleClicked(const QModelIndex& index)
{
const RecentRequestsTableModel* submodel = model->getRecentRequestsTableModel();
ReceiveRequestDialog* dialog = new ReceiveRequestDialog(this);
dialog->setModel(model->getOptionsModel());
dialog->setInfo(submodel->entry(index.row()).recipient);
dialog->setAttribute(Qt::WA_DeleteOnClose);
dialog->show();
}
void ReceiveCoinsDialog::recentRequestsView_selectionChanged(const QItemSelection& selected, const QItemSelection& deselected)
{
// Enable Show/Remove buttons only if anything is selected.
bool enable = !ui->recentRequestsView->selectionModel()->selectedRows().isEmpty();
ui->showRequestButton->setEnabled(enable);
ui->removeRequestButton->setEnabled(enable);
}
void ReceiveCoinsDialog::on_showRequestButton_clicked()
{
if (!model || !model->getRecentRequestsTableModel() || !ui->recentRequestsView->selectionModel())
return;
QModelIndexList selection = ui->recentRequestsView->selectionModel()->selectedRows();
foreach (QModelIndex index, selection) {
on_recentRequestsView_doubleClicked(index);
}
}
void ReceiveCoinsDialog::on_removeRequestButton_clicked()
{
if (!model || !model->getRecentRequestsTableModel() || !ui->recentRequestsView->selectionModel())
return;
QModelIndexList selection = ui->recentRequestsView->selectionModel()->selectedRows();
if (selection.empty())
return;
// correct for selection mode ContiguousSelection
QModelIndex firstIndex = selection.at(0);
model->getRecentRequestsTableModel()->removeRows(firstIndex.row(), selection.length(), firstIndex.parent());
}
// We override the virtual resizeEvent of the QWidget to adjust tables column
// sizes as the tables width is proportional to the dialogs width.
void ReceiveCoinsDialog::resizeEvent(QResizeEvent* event)
{
QWidget::resizeEvent(event);
columnResizingFixer->stretchColumnWidth(RecentRequestsTableModel::Message);
}
void ReceiveCoinsDialog::keyPressEvent(QKeyEvent* event)
{
if (event->key() == Qt::Key_Return) {
// press return -> submit form
if (ui->reqLabel->hasFocus() || ui->reqAmount->hasFocus() || ui->reqMessage->hasFocus()) {
event->ignore();
on_receiveButton_clicked();
return;
}
}
this->QDialog::keyPressEvent(event);
}
// copy column of selected row to clipboard
void ReceiveCoinsDialog::copyColumnToClipboard(int column)
{
if (!model || !model->getRecentRequestsTableModel() || !ui->recentRequestsView->selectionModel())
return;
QModelIndexList selection = ui->recentRequestsView->selectionModel()->selectedRows();
if (selection.empty())
return;
// correct for selection mode ContiguousSelection
QModelIndex firstIndex = selection.at(0);
GUIUtil::setClipboard(model->getRecentRequestsTableModel()->data(firstIndex.child(firstIndex.row(), column), Qt::EditRole).toString());
}
// context menu
void ReceiveCoinsDialog::showMenu(const QPoint& point)
{
if (!model || !model->getRecentRequestsTableModel() || !ui->recentRequestsView->selectionModel())
return;
QModelIndexList selection = ui->recentRequestsView->selectionModel()->selectedRows();
if (selection.empty())
return;
contextMenu->exec(QCursor::pos());
}
// context menu action: copy label
void ReceiveCoinsDialog::copyLabel()
{
copyColumnToClipboard(RecentRequestsTableModel::Label);
}
// context menu action: copy message
void ReceiveCoinsDialog::copyMessage()
{
copyColumnToClipboard(RecentRequestsTableModel::Message);
}
// context menu action: copy amount
void ReceiveCoinsDialog::copyAmount()
{
copyColumnToClipboard(RecentRequestsTableModel::Amount);
}
| [
"[email protected]"
] | |
5372d7627087ac6e4e198bea89a5227ff3bf24b9 | 198f7ade46226ef0eac2f7beb39716ed2d0ba07b | /6.code/storyBlocks_v2/src/UI.h | 9631610f8c3ad572a795d6433b090f43b046913a | [] | no_license | EveraertJan/NarrativeCoding | 942487e9a18d88707e4f399fc941ebdda46b5999 | 95608e13f9c50fa88b42e86bcf87ed2ed578f211 | refs/heads/master | 2021-01-19T06:06:04.048607 | 2015-06-25T13:56:27 | 2015-06-25T13:56:27 | 32,923,018 | 1 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 337 | h | //
// UI.h
// storyBlocks_v2
//
// Created by jan everaert on 24/05/15.
//
//
#pragma once
class UI{
public:
ci::Area showBookScan();
ci::Area showGreenCard();
ci::Area TagScan();
void tutorial();
void showTagConnections(std::vector<ci::Vec2i> tags);
int cx;
int cy;
int tagSize = 100/2;
}; | [
"[email protected]"
] | |
7afffd6e8fe3f2215aea46b4fcb073b720d305cc | 7d210e6214835fbc3b29702896db2c3fcd01e6bc | /compute-only-sample/costestmc/costestmc.cpp | 590849e563a09709936579b8cc8cb47f8dec2b15 | [
"MIT"
] | permissive | TheMindVirus/roscos | 0c159be9c0199a5b716668806066d825f1a104c6 | f902135d31986d0c9c4d3eda736390052d6330e3 | refs/heads/main | 2023-07-19T11:19:50.782156 | 2021-09-01T00:34:01 | 2021-09-01T00:34:01 | 401,210,985 | 1 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 18,659 | cpp | // costestmc.cpp : Defines the entry point for the console application.
//
#include <windows.h>
#include <d3d11_1.h>
#include <dxgi1_3.h>
#include <d3dcompiler.h>
#include <directxmath.h>
#include <directxcolors.h>
#include <d3d12.h>
#include <stdio.h>
#include <exception>
#include <memory>
#include <list>
#include "CosMetaCommand.h"
template<class T> class D3DPointer
{
public:
D3DPointer() : m_p(NULL) {}
~D3DPointer() { if (m_p) m_p->Release(); }
T * operator->() { return m_p; }
operator bool() { return m_p != NULL; }
operator T *() { return m_p; }
D3DPointer<T> & operator=(T * p) { if (m_p) m_p->Release(); m_p = p; return *this; }
private:
T * m_p;
};
class D3DDevice
{
public:
D3DDevice(std::wstring & driverString)
{
if (!FindAdapter(driverString)) throw std::exception("Failed to find adapter");
if (!CreateDevice()) throw std::exception("Failed to create device");
}
~D3DDevice()
{
// do nothing
}
ID3D12Device5 * GetDevice() { return m_pDevice; }
ID3D12CommandAllocator * GetCommandAllocator() { return m_pCommandAllocator; }
ID3D12CommandQueue * GetCommandQueue() { return m_pCommandQueue; }
ID3D12GraphicsCommandList4 * GetCommandList() { return m_pCommandList; }
private:
D3DPointer<IDXGIAdapter2> m_pAdapter;
D3DPointer<ID3D12Device5> m_pDevice;
D3DPointer<ID3D12CommandAllocator> m_pCommandAllocator;
D3DPointer<ID3D12CommandQueue> m_pCommandQueue;
D3DPointer<ID3D12GraphicsCommandList4> m_pCommandList;
bool CreateDevice()
{
D3D12EnableExperimentalFeatures(1, &D3D12ComputeOnlyDevices, NULL, 0);
ID3D12Device5 * pDevice;
HRESULT hr = D3D12CreateDevice(m_pAdapter, D3D_FEATURE_LEVEL_1_0_CORE, IID_PPV_ARGS(&pDevice));
bool success = (hr == S_OK);
if (success)
m_pDevice = pDevice;
if (success) {
ID3D12CommandQueue * pCommandQueue;
D3D12_COMMAND_QUEUE_DESC commandQueueDesc;
commandQueueDesc.Flags = D3D12_COMMAND_QUEUE_FLAG_NONE;
commandQueueDesc.Type = D3D12_COMMAND_LIST_TYPE_COMPUTE;
commandQueueDesc.Priority = 0;
commandQueueDesc.NodeMask = 0;
hr = pDevice->CreateCommandQueue(&commandQueueDesc, IID_PPV_ARGS(&pCommandQueue));
success = (hr == S_OK);
if (success)
m_pCommandQueue = pCommandQueue;
}
if (success) {
ID3D12CommandAllocator * pCommandAllocator;
hr = pDevice->CreateCommandAllocator(D3D12_COMMAND_LIST_TYPE_COMPUTE, IID_PPV_ARGS(&pCommandAllocator));
success = (hr == S_OK);
if (success)
m_pCommandAllocator = pCommandAllocator;
}
if (success) {
ID3D12GraphicsCommandList4 * pCommandList;
hr = pDevice->CreateCommandList(0, D3D12_COMMAND_LIST_TYPE_COMPUTE, m_pCommandAllocator, NULL, IID_PPV_ARGS(&pCommandList));
success = (hr == S_OK);
if (success)
m_pCommandList = pCommandList;
}
return success;
}
bool FindAdapter(std::wstring & driverString)
{
bool found = false;
IDXGIFactory2 * factory = NULL;
HRESULT hr = CreateDXGIFactory2(0, __uuidof(IDXGIFactory2), ((void **)&factory));
if (FAILED(hr)) throw std::exception("Unable to create DXGIFactor2");
UINT adapterIndex = 0;
bool done = false;
while (!done && !found) {
IDXGIAdapter1 * adapter = NULL;
hr = factory->EnumAdapters1(adapterIndex, &adapter);
if (hr == S_OK)
{
IDXGIAdapter2 * adapter2 = NULL;
hr = adapter->QueryInterface(__uuidof(IDXGIAdapter2), (void **)&adapter2);
if (hr == S_OK)
{
DXGI_ADAPTER_DESC2 desc;
adapter2->GetDesc2(&desc);
found = (wcscmp(driverString.c_str(), desc.Description) == 0);
if (found)
{
m_pAdapter = adapter2;
}
else
{
adapter2->Release();
}
}
adapter->Release();
adapterIndex++;
}
else
{
done = true;
}
}
factory->Release();
return found;
}
};
class D3DAdapter
{
public:
static void GetAdapterList(std::list<std::wstring> & list)
{
IDXGIFactory2 * factory = NULL;
HRESULT hr = CreateDXGIFactory2(0, __uuidof(IDXGIFactory2), ((void **)&factory));
if (FAILED(hr)) throw std::exception("Unable to create DXGIFactor2");
UINT adapterIndex = 0;
bool done = false;
list.clear();
while (!done) {
IDXGIAdapter1 * adapter = NULL;
hr = factory->EnumAdapters1(adapterIndex, &adapter);
if (hr == S_OK)
{
IDXGIAdapter2 * adapter2 = NULL;
hr = adapter->QueryInterface(__uuidof(IDXGIAdapter2), (void **)&adapter2);
if (hr == S_OK)
{
DXGI_ADAPTER_DESC2 desc;
adapter2->GetDesc2(&desc);
list.push_back(desc.Description);
adapter2->Release();
}
adapter->Release();
adapterIndex++;
}
else
{
done = true;
}
}
factory->Release();
}
};
class D3DInputBuffer;
class D3DOutputBuffer;
class D3DBuffer {
public:
D3DBuffer(D3DDevice & inDevice, UINT uSize, D3D12_HEAP_TYPE inHeapType = D3D12_HEAP_TYPE_DEFAULT,
D3D12_RESOURCE_STATES inInitialState = D3D12_RESOURCE_STATE_UNORDERED_ACCESS,
D3D12_RESOURCE_FLAGS inResourceFlags = D3D12_RESOURCE_FLAG_ALLOW_UNORDERED_ACCESS)
{
D3D12_HEAP_PROPERTIES heapProperties;
heapProperties.Type = inHeapType;
heapProperties.CPUPageProperty = D3D12_CPU_PAGE_PROPERTY_UNKNOWN;
heapProperties.MemoryPoolPreference = D3D12_MEMORY_POOL_UNKNOWN;
heapProperties.CreationNodeMask = 0;
heapProperties.VisibleNodeMask = 0;
D3D12_RESOURCE_DESC resourceDesc;
resourceDesc.Dimension = D3D12_RESOURCE_DIMENSION_BUFFER;
resourceDesc.Alignment = 0;
resourceDesc.Width = uSize;
resourceDesc.Height = 1;
resourceDesc.DepthOrArraySize = 1;
resourceDesc.MipLevels = 1;
resourceDesc.Format = DXGI_FORMAT_UNKNOWN;
resourceDesc.SampleDesc.Count = 1;
resourceDesc.SampleDesc.Quality = 0;
resourceDesc.Layout = D3D12_TEXTURE_LAYOUT_ROW_MAJOR;
resourceDesc.Flags = inResourceFlags;
ID3D12Resource * pBuffer;
OutputDebugStringA("creating structured buffer\n");
HRESULT hr = inDevice.GetDevice()->CreateCommittedResource(&heapProperties, D3D12_HEAP_FLAG_NONE, &resourceDesc,
inInitialState, NULL, IID_PPV_ARGS(&pBuffer));
if (FAILED(hr)) throw std::exception("Unable to create structed buffer");
m_pBuffer = pBuffer;
m_initialState = inInitialState;
m_currentState = inInitialState;
}
void CopyFrom(ID3D12GraphicsCommandList * inCommandList, D3DInputBuffer & inBuffer);
void CopyTo(ID3D12GraphicsCommandList * inCommandList, D3DOutputBuffer & outBuffer);
void StartStateTracking()
{
m_currentState = m_initialState;
}
void SetState(ID3D12GraphicsCommandList * pCommandList, D3D12_RESOURCE_STATES inNewState)
{
if (inNewState != m_currentState)
{
D3D12_RESOURCE_BARRIER barrier;
barrier.Type = D3D12_RESOURCE_BARRIER_TYPE_TRANSITION;
barrier.Flags = D3D12_RESOURCE_BARRIER_FLAG_NONE;
barrier.Transition.Subresource = D3D12_RESOURCE_BARRIER_ALL_SUBRESOURCES;
barrier.Transition.pResource = m_pBuffer;
barrier.Transition.StateBefore = m_currentState;
barrier.Transition.StateAfter = inNewState;
pCommandList->ResourceBarrier(1, &barrier);
m_currentState = inNewState;
}
}
ID3D12Resource * Get() { return m_pBuffer; }
protected:
D3DPointer<ID3D12Resource> m_pBuffer;
D3D12_RESOURCE_STATES m_initialState;
D3D12_RESOURCE_STATES m_currentState;
};
class D3DInputBuffer : public D3DBuffer
{
public:
D3DInputBuffer(D3DDevice & inDevice, UINT inSize, void * inData) :
D3DBuffer(inDevice, inSize, D3D12_HEAP_TYPE_UPLOAD, D3D12_RESOURCE_STATE_GENERIC_READ, D3D12_RESOURCE_FLAG_NONE)
{
void * pDst;
D3D12_RANGE range = { 0, 0 };
m_pBuffer->Map(0, &range, &pDst);
memcpy(pDst, inData, inSize);
m_pBuffer->Unmap(0, NULL);
}
};
class D3DOutputBuffer : public D3DBuffer
{
public:
D3DOutputBuffer(D3DDevice & inDevice, UINT inSize, void * inData = NULL) :
D3DBuffer(inDevice, inSize, D3D12_HEAP_TYPE_READBACK, D3D12_RESOURCE_STATE_COPY_DEST, D3D12_RESOURCE_FLAG_NONE)
{
// do nothing
}
void Read( UINT inSize, void * pDst)
{
D3D12_RANGE range = { 0, inSize };
void * pSrc;
m_pBuffer->Map(0, &range, &pSrc);
memcpy(pDst, pSrc, inSize);
range.End = 0;
m_pBuffer->Unmap(0, &range);
}
};
void D3DBuffer::CopyFrom(ID3D12GraphicsCommandList * inCommandList, D3DInputBuffer & inBuffer)
{
SetState(inCommandList, D3D12_RESOURCE_STATE_COPY_DEST);
inCommandList->CopyResource(Get(), inBuffer.Get());
SetState(inCommandList, D3D12_RESOURCE_STATE_UNORDERED_ACCESS);
}
void D3DBuffer::CopyTo(ID3D12GraphicsCommandList * inCommandList, D3DOutputBuffer & outBuffer)
{
SetState(inCommandList, D3D12_RESOURCE_STATE_COPY_SOURCE);
inCommandList->CopyResource(outBuffer.Get(), Get());
SetState(inCommandList, D3D12_RESOURCE_STATE_UNORDERED_ACCESS);
}
struct BufType
{
int i;
float f;
};
#define NUM_ELEMENTS 1024
#define THREADS_IN_GROUP 4 // Expressed in the shader
int main()
{
int dbgFlags = _CrtSetDbgFlag(_CRTDBG_REPORT_FLAG);
dbgFlags |= _CRTDBG_CHECK_ALWAYS_DF;
_CrtSetDbgFlag(dbgFlags);
std::wstring cosDriverString = L"Compute Only Sample Driver";
std::wstring brdDriverString = L"Microsoft Basic Render Driver";
std::wstring amdDriverString = L"Radeon (TM) RX 480 Graphics";
std::wstring intelDriverString = L"Intel(R) HD Graphics 620";
std::list<std::wstring> adapterList;
D3DAdapter::GetAdapterList(adapterList);
printf("Found adapters:\n");
for (std::wstring & a : adapterList)
printf(" %S\n", a.c_str());
auto findIter = std::find(adapterList.begin(), adapterList.end(), brdDriverString);
if (findIter == adapterList.end()) {
printf("%S was not found\n", cosDriverString.c_str());
return 0;
}
try {
std::wstring driverString = cosDriverString;
findIter = std::find(adapterList.begin(), adapterList.end(), driverString);
if (findIter == adapterList.end())
driverString = brdDriverString;
printf("Creating device on %S ... ", driverString.c_str());
D3DDevice computeDevice(driverString);
printf("done.\n");
printf("Creating buffers ... ");
BufType initialData[NUM_ELEMENTS];
for (int i = 0; i < NUM_ELEMENTS; i++) {
initialData[i].i = i;
initialData[i].f = (float)i;
}
UINT uSize = sizeof(BufType) * NUM_ELEMENTS;
D3DInputBuffer input(computeDevice, uSize, initialData);
D3DBuffer a(computeDevice, uSize);
D3DBuffer result(computeDevice, uSize);
D3DOutputBuffer output(computeDevice, uSize);
printf("done.\n");
printf("Running shader ... ");
ID3D12Device5 * pDevice = computeDevice.GetDevice();
ID3D12GraphicsCommandList4 * pCommandList = computeDevice.GetCommandList();
ID3D12Fence * pFence;
HRESULT hr = pDevice->CreateFence(0, D3D12_FENCE_FLAG_NONE, IID_PPV_ARGS(&pFence));
if (FAILED(hr)) throw std::exception("Failed to create fence");
UINT metaCommandCount = 0;
D3D12_META_COMMAND_DESC metaCommandDescriptions[16] = { 0 };
metaCommandCount = _countof(metaCommandDescriptions);
//
// For metaCommandCount,
// in : number of elmements in metaCommandDescriptions
// out : number of metaCommandDescriptions filled in by driver
//
hr = pDevice->EnumerateMetaCommands(&metaCommandCount, metaCommandDescriptions);
if (FAILED(hr))
{
throw std::exception("EnumerateMetaCommands failed");
}
//
// Check GUID_IDENTITY meta command is supported by the driver
//
UINT i;
for (i = 0; i < metaCommandCount; i++)
{
if (IsEqualGUID(GUID_IDENTITY, metaCommandDescriptions[i].Id))
{
break;
}
}
if (i == metaCommandCount)
{
throw std::exception("Driver doesn't support meta command copy resource");
}
//
// Enumerate the meta command parameters
//
// Parameters are passed to meta command creation/initialization/execution calls in structures
// totalStructureSizeInBytes is the byte size of meta command parameter structure
//
// This is mostly used to ensure API driver consistency about a meta command
//
UINT totalStructureSizeInBytes, parameterCount;
D3D12_META_COMMAND_PARAMETER_DESC metaCommandParamterDescriptions[2];
totalStructureSizeInBytes = 0;
parameterCount = _countof(metaCommandParamterDescriptions);
hr = pDevice->EnumerateMetaCommandParameters(
GUID_IDENTITY,
D3D12_META_COMMAND_PARAMETER_STAGE_CREATION,
&totalStructureSizeInBytes,
¶meterCount,
metaCommandParamterDescriptions);
if (FAILED(hr))
{
throw std::exception("EnumerateMetaCommandParameters() for creation stage failed");
}
totalStructureSizeInBytes = 0;
parameterCount = _countof(metaCommandParamterDescriptions);
hr = pDevice->EnumerateMetaCommandParameters(
GUID_IDENTITY,
D3D12_META_COMMAND_PARAMETER_STAGE_INITIALIZATION,
&totalStructureSizeInBytes,
¶meterCount,
metaCommandParamterDescriptions);
if (FAILED(hr))
{
throw std::exception("EnumerateMetaCommandParameters() for initialization stage failed");
}
totalStructureSizeInBytes = 0;
parameterCount = _countof(metaCommandParamterDescriptions);
hr = pDevice->EnumerateMetaCommandParameters(
GUID_IDENTITY,
D3D12_META_COMMAND_PARAMETER_STAGE_EXECUTION,
&totalStructureSizeInBytes,
¶meterCount,
metaCommandParamterDescriptions);
if (FAILED(hr))
{
throw std::exception("EnumerateMetaCommandParameters() for execution stage failed");
}
//
// Create Identity meta command
//
IdentityMetaCommandCreationParameters identityMetaCommandCreationParameters = { uSize };
ID3D12MetaCommand * pMetaCommand;
hr = pDevice->CreateMetaCommand(
GUID_IDENTITY,
0,
&identityMetaCommandCreationParameters,
sizeof(identityMetaCommandCreationParameters),
IID_PPV_ARGS(&pMetaCommand));
if (FAILED(hr))
{
throw std::exception("CreateMetaCommand() failed");
}
a.StartStateTracking();
a.CopyFrom(pCommandList, input);
//
// Initialize the meta command
//
pCommandList->InitializeMetaCommand(pMetaCommand, nullptr, 0);
//
// Transit the resource to UVA
//
a.SetState(pCommandList, D3D12_RESOURCE_STATE_UNORDERED_ACCESS);
result.SetState(pCommandList, D3D12_RESOURCE_STATE_UNORDERED_ACCESS);
//
// Execute the meta command
//
IdentityMetaCommandExecutionParameters identityMetaCommandExecutionParameters = { 0 };
identityMetaCommandExecutionParameters.Input = a.Get()->GetGPUVirtualAddress();
identityMetaCommandExecutionParameters.Output = result.Get()->GetGPUVirtualAddress();
pCommandList->ExecuteMetaCommand(
pMetaCommand,
&identityMetaCommandExecutionParameters,
sizeof(identityMetaCommandExecutionParameters));
result.CopyTo(pCommandList, output);
pCommandList->Close();
ID3D12CommandQueue * pCommandQueue = computeDevice.GetCommandQueue();
ID3D12CommandList * ppCommandLists[] = { pCommandList };
pCommandQueue->ExecuteCommandLists(1, ppCommandLists);
hr = pCommandQueue->Signal(pFence, 1);
if (FAILED(hr)) throw std::exception("Failed to signal");
if (pFence->GetCompletedValue() < 1) {
HANDLE hEvent = CreateEvent(NULL, FALSE, FALSE, NULL);
hr = pFence->SetEventOnCompletion(1, hEvent);
if (FAILED(hr)) throw std::exception("Failed to set event on completion");
WaitForSingleObject(hEvent, INFINITE);
}
printf("done\n");
BufType results[NUM_ELEMENTS];
output.Read(uSize, results);
printf("checking results ... ");
for (int i = 0; i < NUM_ELEMENTS; i++) {
if (results[i].i != i) {
printf("Bad integer result %d at index %d\n", results[i].i, i);
break;
}
if (results[i].f != (float) (i)) {
printf("Bad float result %f at index %d\n", results[i].f, i);
break;
}
}
printf("done.\n");
}
catch (std::exception & e)
{
printf("Hit error: %s\n", e.what());
}
printf("Done.\n");
return 0;
}
| [
"[email protected]"
] | |
a26432278fda88d734c3b4b411441bea75dcabd8 | a4a26652f87ea97a4452100dd44a6ca94e7dea1f | /17-Moderate/17-7.cpp | 768d36691c1236a34ef2e29b28593278d902891a | [] | no_license | talentlei/CTCI150 | b8f342a808dd8c998fc2207b188db24b352cd26b | d0eb8947e45ade1058bf5497889d382521795de0 | refs/heads/master | 2021-01-25T12:01:50.563964 | 2015-07-23T12:09:54 | 2015-07-23T12:09:54 | 33,870,438 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 1,136 | cpp |
vector<string> ones = {"one", "two", "three", "four", "five", "six", "seven",
"eight", "nine"};
vector<string> teens = {"eleven", "twelve", "thirteen", "fourteen", "fifteen", "sixteen",
"seventeen", "eighteen", "nineteen"};
vector<string> tens = {"ten", "twenty", "thirty", "forty", "fifty", "sixty", "seventy",
"eighty", "ninty"};
vector<string> bigs = {"", "thousand", "million", "billion"};
string numToString(int num){
if(num==0) return "zero";
else if(num<0) return "nagetive "+numtoString(-1*num);
int count=0;
string str = "";
while(num>0){
if(num%1000>0){ //注意等于1000的情况
str = numToString100(num%1000)+" " + bigs[count] +" "+ str;
}
count++;
num/=1000;
}
}
string numToString100(int num){
string str = "";
if(num>=100){
str = digits[number/100-1]+" Hundred ";
num%=100;
}
if(num>=11&&num<=19){
str= str + teens[num-11]+" ";
}
else if(num==10||num>=20){
str = str + tens[num/10-1] +" ";
num/=10;
}
if(num>=1&&num<=9)
str = str +digits[num-1]+" ";
return str;
}
| [
"[email protected]"
] | |
d18145e988e283b88fe461c152836b2bfe3b0b64 | bb6ebff7a7f6140903d37905c350954ff6599091 | /sync/engine/non_blocking_type_processor_core.cc | a14a8d003a1c41f62c1b438940e8e6f93d3dbc7e | [
"BSD-3-Clause"
] | permissive | PDi-Communication-Systems-Inc/lollipop_external_chromium_org | faa6602bd6bfd9b9b6277ce3cd16df0bd26e7f2f | ccadf4e63dd34be157281f53fe213d09a8c66d2c | refs/heads/master | 2022-12-23T18:07:04.568931 | 2016-04-11T16:03:36 | 2016-04-11T16:03:36 | 53,677,925 | 0 | 1 | BSD-3-Clause | 2022-12-09T23:46:46 | 2016-03-11T15:49:07 | C++ | UTF-8 | C++ | false | false | 10,979 | cc | // Copyright 2014 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#include "sync/engine/non_blocking_type_processor_core.h"
#include "base/bind.h"
#include "base/format_macros.h"
#include "base/logging.h"
#include "base/strings/stringprintf.h"
#include "sync/engine/commit_contribution.h"
#include "sync/engine/non_blocking_type_commit_contribution.h"
#include "sync/engine/non_blocking_type_processor_interface.h"
#include "sync/engine/sync_thread_sync_entity.h"
#include "sync/syncable/syncable_util.h"
#include "sync/util/time.h"
namespace syncer {
NonBlockingTypeProcessorCore::NonBlockingTypeProcessorCore(
ModelType type,
const DataTypeState& initial_state,
scoped_ptr<NonBlockingTypeProcessorInterface> processor_interface)
: type_(type),
data_type_state_(initial_state),
processor_interface_(processor_interface.Pass()),
entities_deleter_(&entities_),
weak_ptr_factory_(this) {
}
NonBlockingTypeProcessorCore::~NonBlockingTypeProcessorCore() {
}
ModelType NonBlockingTypeProcessorCore::GetModelType() const {
DCHECK(CalledOnValidThread());
return type_;
}
// UpdateHandler implementation.
void NonBlockingTypeProcessorCore::GetDownloadProgress(
sync_pb::DataTypeProgressMarker* progress_marker) const {
DCHECK(CalledOnValidThread());
progress_marker->CopyFrom(data_type_state_.progress_marker);
}
void NonBlockingTypeProcessorCore::GetDataTypeContext(
sync_pb::DataTypeContext* context) const {
DCHECK(CalledOnValidThread());
context->CopyFrom(data_type_state_.type_context);
}
SyncerError NonBlockingTypeProcessorCore::ProcessGetUpdatesResponse(
const sync_pb::DataTypeProgressMarker& progress_marker,
const sync_pb::DataTypeContext& mutated_context,
const SyncEntityList& applicable_updates,
sessions::StatusController* status) {
DCHECK(CalledOnValidThread());
// TODO(rlarocque): Handle data type context conflicts.
data_type_state_.type_context = mutated_context;
data_type_state_.progress_marker = progress_marker;
UpdateResponseDataList response_datas;
for (SyncEntityList::const_iterator update_it = applicable_updates.begin();
update_it != applicable_updates.end();
++update_it) {
const sync_pb::SyncEntity* update_entity = *update_it;
if (!update_entity->server_defined_unique_tag().empty()) {
// We can't commit an item unless we know its parent ID. This is where
// we learn that ID and remember it forever.
DCHECK_EQ(ModelTypeToRootTag(type_),
update_entity->server_defined_unique_tag());
if (!data_type_state_.type_root_id.empty()) {
DCHECK_EQ(data_type_state_.type_root_id, update_entity->id_string());
}
data_type_state_.type_root_id = update_entity->id_string();
} else {
// Normal updates are handled here.
const std::string& client_tag_hash =
update_entity->client_defined_unique_tag();
DCHECK(!client_tag_hash.empty());
EntityMap::const_iterator map_it = entities_.find(client_tag_hash);
if (map_it == entities_.end()) {
SyncThreadSyncEntity* entity =
SyncThreadSyncEntity::FromServerUpdate(update_entity->id_string(),
client_tag_hash,
update_entity->version());
entities_.insert(std::make_pair(client_tag_hash, entity));
} else {
SyncThreadSyncEntity* entity = map_it->second;
entity->ReceiveUpdate(update_entity->version());
}
// Prepare the message for the model thread.
UpdateResponseData response_data;
response_data.id = update_entity->id_string();
response_data.client_tag_hash = client_tag_hash;
response_data.response_version = update_entity->version();
response_data.ctime = ProtoTimeToTime(update_entity->ctime());
response_data.mtime = ProtoTimeToTime(update_entity->mtime());
response_data.non_unique_name = update_entity->name();
response_data.deleted = update_entity->deleted();
response_data.specifics = update_entity->specifics();
response_datas.push_back(response_data);
}
}
// Forward these updates to the model thread so it can do the rest.
processor_interface_->ReceiveUpdateResponse(data_type_state_, response_datas);
return SYNCER_OK;
}
void NonBlockingTypeProcessorCore::ApplyUpdates(
sessions::StatusController* status) {
DCHECK(CalledOnValidThread());
// This function is called only when we've finished a download cycle, ie. we
// got a response with changes_remaining == 0. If this is our first download
// cycle, we should update our state so the NonBlockingTypeProcessor knows
// that it's safe to commit items now.
if (!data_type_state_.initial_sync_done) {
data_type_state_.initial_sync_done = true;
UpdateResponseDataList empty_update_list;
processor_interface_->ReceiveUpdateResponse(data_type_state_,
empty_update_list);
}
}
void NonBlockingTypeProcessorCore::PassiveApplyUpdates(
sessions::StatusController* status) {
NOTREACHED()
<< "Non-blocking types should never apply updates on sync thread. "
<< "ModelType is: " << ModelTypeToString(type_);
}
void NonBlockingTypeProcessorCore::EnqueueForCommit(
const CommitRequestDataList& list) {
DCHECK(CalledOnValidThread());
DCHECK(CanCommitItems())
<< "Asked to commit items before type was initialized. "
<< "ModelType is: " << ModelTypeToString(type_);
for (CommitRequestDataList::const_iterator it = list.begin();
it != list.end();
++it) {
StorePendingCommit(*it);
}
}
// CommitContributor implementation.
scoped_ptr<CommitContribution>
NonBlockingTypeProcessorCore::GetContribution(size_t max_entries) {
DCHECK(CalledOnValidThread());
size_t space_remaining = max_entries;
std::vector<int64> sequence_numbers;
google::protobuf::RepeatedPtrField<sync_pb::SyncEntity> commit_entities;
if (!CanCommitItems())
return scoped_ptr<CommitContribution>();
// TODO(rlarocque): Avoid iterating here.
for (EntityMap::const_iterator it = entities_.begin();
it != entities_.end() && space_remaining > 0;
++it) {
SyncThreadSyncEntity* entity = it->second;
if (entity->IsCommitPending()) {
sync_pb::SyncEntity* commit_entity = commit_entities.Add();
int64 sequence_number = -1;
entity->PrepareCommitProto(commit_entity, &sequence_number);
HelpInitializeCommitEntity(commit_entity);
sequence_numbers.push_back(sequence_number);
space_remaining--;
}
}
if (commit_entities.size() == 0)
return scoped_ptr<CommitContribution>();
return scoped_ptr<CommitContribution>(new NonBlockingTypeCommitContribution(
data_type_state_.type_context, commit_entities, sequence_numbers, this));
}
void NonBlockingTypeProcessorCore::StorePendingCommit(
const CommitRequestData& request) {
if (!request.deleted) {
DCHECK_EQ(type_, GetModelTypeFromSpecifics(request.specifics));
}
EntityMap::iterator map_it = entities_.find(request.client_tag_hash);
if (map_it == entities_.end()) {
SyncThreadSyncEntity* entity =
SyncThreadSyncEntity::FromCommitRequest(request.id,
request.client_tag_hash,
request.sequence_number,
request.base_version,
request.ctime,
request.mtime,
request.non_unique_name,
request.deleted,
request.specifics);
entities_.insert(std::make_pair(request.client_tag_hash, entity));
} else {
SyncThreadSyncEntity* entity = map_it->second;
entity->RequestCommit(request.id,
request.client_tag_hash,
request.sequence_number,
request.base_version,
request.ctime,
request.mtime,
request.non_unique_name,
request.deleted,
request.specifics);
}
// TODO: Nudge SyncScheduler.
}
void NonBlockingTypeProcessorCore::OnCommitResponse(
const CommitResponseDataList& response_list) {
for (CommitResponseDataList::const_iterator response_it =
response_list.begin();
response_it != response_list.end();
++response_it) {
const std::string client_tag_hash = response_it->client_tag_hash;
EntityMap::iterator map_it = entities_.find(client_tag_hash);
// There's no way we could have committed an entry we know nothing about.
if (map_it == entities_.end()) {
NOTREACHED() << "Received commit response for item unknown to us."
<< " Model type: " << ModelTypeToString(type_)
<< " ID: " << response_it->id;
continue;
}
SyncThreadSyncEntity* entity = map_it->second;
entity->ReceiveCommitResponse(response_it->id,
response_it->response_version,
response_it->sequence_number);
}
// Send the responses back to the model thread. It needs to know which
// items have been successfully committed so it can save that information in
// permanent storage.
processor_interface_->ReceiveCommitResponse(data_type_state_, response_list);
}
base::WeakPtr<NonBlockingTypeProcessorCore>
NonBlockingTypeProcessorCore::AsWeakPtr() {
return weak_ptr_factory_.GetWeakPtr();
}
bool NonBlockingTypeProcessorCore::CanCommitItems() const {
// We can't commit anything until we know the type's parent node.
// We'll get it in the first update response.
return !data_type_state_.type_root_id.empty() &&
data_type_state_.initial_sync_done;
}
void NonBlockingTypeProcessorCore::HelpInitializeCommitEntity(
sync_pb::SyncEntity* sync_entity) {
// Initial commits need our help to generate a client ID.
if (!sync_entity->has_id_string()) {
DCHECK_EQ(kUncommittedVersion, sync_entity->version());
const int64 id = data_type_state_.next_client_id++;
sync_entity->set_id_string(
base::StringPrintf("%s-%" PRId64, ModelTypeToString(type_), id));
}
// Always include enough specifics to identify the type. Do this even in
// deletion requests, where the specifics are otherwise invalid.
if (!sync_entity->has_specifics()) {
AddDefaultFieldValue(type_, sync_entity->mutable_specifics());
}
// We're always responsible for the parent ID.
sync_entity->set_parent_id_string(data_type_state_.type_root_id);
}
} // namespace syncer
| [
"[email protected]"
] | |
2ff048ef19927c43c6bc59f13b50d6de6a5fde63 | 435512e4c40fca9e9f9293b6e4c0915534db063a | /191_numberOf1Bits/numberOf1Bit.cpp | 40e8106b456e7c53ed23f793824070d2d70ef734 | [] | no_license | gavin-dtl/LeetCode | 4e9f190b5c59bad1b479324d56f4a35e6c814dbf | 1b260af9b6c298c1926a14ef52d8af9476f8064f | refs/heads/master | 2021-01-19T03:22:47.357959 | 2015-04-16T05:55:49 | 2015-04-16T05:55:49 | 33,853,756 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 1,238 | cpp | /* ************************************************************************
* Filename: numberOf1Bit.c
* Description:
* Version: 1.0
* Created: 2015Äê04ÔÂ14ÈÕ 16ʱ22·Ö12Ãë
* Revision: none
* Compiler: gcc
* Author: YOUR NAME (),
* Company:
* ************************************************************************/
/*
Write a function that takes an unsigned integer and returns the number of ’1
' bits it has (also known as the Hamming weight).
For example, the 32-bit integer ’11' has binary representation
00000000000000000000000000001011, so the function should return 3.
Credits:
Special thanks to @ts for adding this problem and creating all test cases.''
*/
#include <iostream>
#include <stdint.h>
#include <stdlib.h>
using namespace std;
class Solution {
public:
int hammingWeight(uint32_t n);
};
int hammingWeight(uint32_t n)
{
int i = 0;
int count = 0;
while(n){
if(n&0x00000001){
count ++;
}
n = n>>1;
}
return count;
}
int main(int argc, char **argv)
{
unsigned int num = 3;
if(argc>1){
num = atoi(argv[1]);
}
cout << "number of 1 bit is " << hammingWeight(num) << endl;
return 0;
}
| [
"[email protected]"
] | |
c7d124beaaa7866c4a7544a483694ceb219e1e1c | 6d00b88d4ea8afe7a169813f79a640f91e87b691 | /GameEngine_101/src/AI/cNPCManager.h | 64993db53b637a485f2b8365108a4a71c59e4183 | [] | no_license | amengol/Fanshawe_Game_Jam | cce3aa48ecf97fef6649ce170bd1f9f6c5510a53 | 9f045ac028646766aaf3609705cbce8ef798f7e9 | refs/heads/master | 2020-03-12T19:00:19.962194 | 2018-08-03T20:02:58 | 2018-08-03T20:02:58 | 130,774,966 | 3 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 1,529 | h | /**
Controls NPCs
@author Jorge Amengol
@version 1.2
@date April 24th, 2018
*/
#pragma once
#include <vector>
#define GLM_ENABLE_EXPERIMENTAL
#include <glm\gtx\quaternion.hpp>
class cCharacterControl;
class cNPCManager
{
public:
cNPCManager();
~cNPCManager();
// Sets the player character
void SetPlayer(cCharacterControl* CH) { mPlayer = CH; }
// Sets the NPCs
void SetNPCs(std::vector<cCharacterControl*> vecCH) { mNPCs = vecCH; }
// Evaluate the scene
void Evaluate(double deltaTime);
// Returns a rotation quaternion between two vectors
glm::quat RotationBetweenVectors(glm::vec3 start, glm::vec3 dest);
private:
float mInterestRadius; // The interest radius
float mStopDistance; // The distance where the player should stop
float mThreshold; // Distance to avoid staggering
float mSysTimeDying; // Control for dying
bool mIsDying; // Control for dying
bool mTurnComplete; // Control turns
cCharacterControl* mPlayer; // The player
std::vector<cCharacterControl*> mNPCs; // The NPCs
// Solve the NPC for Guardian
void SolveForGuardian(cCharacterControl*, double deltaTime);
// Solve the NPC for Angry Pursuit
void SolveForAngryPursuit(cCharacterControl*, double deltaTime);
// Solve the NPC for Dying
void SolveForDying(cCharacterControl*, double deltaTime);
};
| [
"[email protected]"
] | |
4506694faf89d559c538fa990f5be73868814dcf | 87e4278a37b5bd0cd7e315d6ca61a75f6af6e13f | /build-testa-Desktop_Qt_5_14_0_GCC_64bit-Debug/ui_mainwindow.h | dd192fb41a9a4a3d0de0d765be001b8359c006ed | [] | no_license | Toufikos/testa | 2eade00d7b456f409e2d645ddc19c0443ea0e125 | c2358792b79d2cbd8adc61c3b84a7259147cc8e4 | refs/heads/master | 2021-06-09T10:32:09.682456 | 2021-04-15T11:28:43 | 2021-04-15T11:28:43 | 146,779,272 | 0 | 0 | null | 2019-11-07T09:17:06 | 2018-08-30T16:51:21 | HTML | UTF-8 | C++ | false | false | 7,249 | h | /********************************************************************************
** Form generated from reading UI file 'mainwindow.ui'
**
** Created by: Qt User Interface Compiler version 5.14.0
**
** WARNING! All changes made in this file will be lost when recompiling UI file!
********************************************************************************/
#ifndef UI_MAINWINDOW_H
#define UI_MAINWINDOW_H
#include <QtCore/QVariant>
#include <QtWidgets/QApplication>
#include <QtWidgets/QMainWindow>
#include <QtWidgets/QMenuBar>
#include <QtWidgets/QPushButton>
#include <QtWidgets/QStatusBar>
#include <QtWidgets/QWidget>
QT_BEGIN_NAMESPACE
class Ui_MainWindow
{
public:
QWidget *centralwidget;
QPushButton *pushButton;
QPushButton *pushButton_2;
QMenuBar *menubar;
QStatusBar *statusbar;
void setupUi(QMainWindow *MainWindow)
{
if (MainWindow->objectName().isEmpty())
MainWindow->setObjectName(QString::fromUtf8("MainWindow"));
MainWindow->resize(640, 480);
QPalette palette;
QBrush brush(QColor(0, 0, 0, 255));
brush.setStyle(Qt::SolidPattern);
palette.setBrush(QPalette::Active, QPalette::WindowText, brush);
QBrush brush1(QColor(173, 127, 168, 255));
brush1.setStyle(Qt::SolidPattern);
palette.setBrush(QPalette::Active, QPalette::Button, brush1);
QBrush brush2(QColor(255, 192, 249, 255));
brush2.setStyle(Qt::SolidPattern);
palette.setBrush(QPalette::Active, QPalette::Light, brush2);
QBrush brush3(QColor(214, 159, 208, 255));
brush3.setStyle(Qt::SolidPattern);
palette.setBrush(QPalette::Active, QPalette::Midlight, brush3);
QBrush brush4(QColor(86, 63, 84, 255));
brush4.setStyle(Qt::SolidPattern);
palette.setBrush(QPalette::Active, QPalette::Dark, brush4);
QBrush brush5(QColor(115, 84, 112, 255));
brush5.setStyle(Qt::SolidPattern);
palette.setBrush(QPalette::Active, QPalette::Mid, brush5);
palette.setBrush(QPalette::Active, QPalette::Text, brush);
QBrush brush6(QColor(255, 255, 255, 255));
brush6.setStyle(Qt::SolidPattern);
palette.setBrush(QPalette::Active, QPalette::BrightText, brush6);
palette.setBrush(QPalette::Active, QPalette::ButtonText, brush);
palette.setBrush(QPalette::Active, QPalette::Base, brush6);
palette.setBrush(QPalette::Active, QPalette::Window, brush1);
palette.setBrush(QPalette::Active, QPalette::Shadow, brush);
QBrush brush7(QColor(214, 191, 211, 255));
brush7.setStyle(Qt::SolidPattern);
palette.setBrush(QPalette::Active, QPalette::AlternateBase, brush7);
QBrush brush8(QColor(255, 255, 220, 255));
brush8.setStyle(Qt::SolidPattern);
palette.setBrush(QPalette::Active, QPalette::ToolTipBase, brush8);
palette.setBrush(QPalette::Active, QPalette::ToolTipText, brush);
QBrush brush9(QColor(0, 0, 0, 128));
brush9.setStyle(Qt::SolidPattern);
#if QT_VERSION >= QT_VERSION_CHECK(5, 12, 0)
palette.setBrush(QPalette::Active, QPalette::PlaceholderText, brush9);
#endif
palette.setBrush(QPalette::Inactive, QPalette::WindowText, brush);
palette.setBrush(QPalette::Inactive, QPalette::Button, brush1);
palette.setBrush(QPalette::Inactive, QPalette::Light, brush2);
palette.setBrush(QPalette::Inactive, QPalette::Midlight, brush3);
palette.setBrush(QPalette::Inactive, QPalette::Dark, brush4);
palette.setBrush(QPalette::Inactive, QPalette::Mid, brush5);
palette.setBrush(QPalette::Inactive, QPalette::Text, brush);
palette.setBrush(QPalette::Inactive, QPalette::BrightText, brush6);
palette.setBrush(QPalette::Inactive, QPalette::ButtonText, brush);
palette.setBrush(QPalette::Inactive, QPalette::Base, brush6);
palette.setBrush(QPalette::Inactive, QPalette::Window, brush1);
palette.setBrush(QPalette::Inactive, QPalette::Shadow, brush);
palette.setBrush(QPalette::Inactive, QPalette::AlternateBase, brush7);
palette.setBrush(QPalette::Inactive, QPalette::ToolTipBase, brush8);
palette.setBrush(QPalette::Inactive, QPalette::ToolTipText, brush);
#if QT_VERSION >= QT_VERSION_CHECK(5, 12, 0)
palette.setBrush(QPalette::Inactive, QPalette::PlaceholderText, brush9);
#endif
palette.setBrush(QPalette::Disabled, QPalette::WindowText, brush4);
palette.setBrush(QPalette::Disabled, QPalette::Button, brush1);
palette.setBrush(QPalette::Disabled, QPalette::Light, brush2);
palette.setBrush(QPalette::Disabled, QPalette::Midlight, brush3);
palette.setBrush(QPalette::Disabled, QPalette::Dark, brush4);
palette.setBrush(QPalette::Disabled, QPalette::Mid, brush5);
palette.setBrush(QPalette::Disabled, QPalette::Text, brush4);
palette.setBrush(QPalette::Disabled, QPalette::BrightText, brush6);
palette.setBrush(QPalette::Disabled, QPalette::ButtonText, brush4);
palette.setBrush(QPalette::Disabled, QPalette::Base, brush1);
palette.setBrush(QPalette::Disabled, QPalette::Window, brush1);
palette.setBrush(QPalette::Disabled, QPalette::Shadow, brush);
palette.setBrush(QPalette::Disabled, QPalette::AlternateBase, brush1);
palette.setBrush(QPalette::Disabled, QPalette::ToolTipBase, brush8);
palette.setBrush(QPalette::Disabled, QPalette::ToolTipText, brush);
#if QT_VERSION >= QT_VERSION_CHECK(5, 12, 0)
palette.setBrush(QPalette::Disabled, QPalette::PlaceholderText, brush9);
#endif
MainWindow->setPalette(palette);
MainWindow->setStyleSheet(QString::fromUtf8(""));
centralwidget = new QWidget(MainWindow);
centralwidget->setObjectName(QString::fromUtf8("centralwidget"));
pushButton = new QPushButton(centralwidget);
pushButton->setObjectName(QString::fromUtf8("pushButton"));
pushButton->setGeometry(QRect(419, 173, 111, 51));
pushButton_2 = new QPushButton(centralwidget);
pushButton_2->setObjectName(QString::fromUtf8("pushButton_2"));
pushButton_2->setGeometry(QRect(130, 170, 161, 51));
MainWindow->setCentralWidget(centralwidget);
menubar = new QMenuBar(MainWindow);
menubar->setObjectName(QString::fromUtf8("menubar"));
menubar->setGeometry(QRect(0, 0, 640, 21));
MainWindow->setMenuBar(menubar);
statusbar = new QStatusBar(MainWindow);
statusbar->setObjectName(QString::fromUtf8("statusbar"));
MainWindow->setStatusBar(statusbar);
retranslateUi(MainWindow);
QMetaObject::connectSlotsByName(MainWindow);
} // setupUi
void retranslateUi(QMainWindow *MainWindow)
{
MainWindow->setWindowTitle(QCoreApplication::translate("MainWindow", "MainWindow", nullptr));
pushButton->setText(QCoreApplication::translate("MainWindow", "Calendar", nullptr));
pushButton_2->setText(QCoreApplication::translate("MainWindow", "Ajouter un fichier", nullptr));
} // retranslateUi
};
namespace Ui {
class MainWindow: public Ui_MainWindow {};
} // namespace Ui
QT_END_NAMESPACE
#endif // UI_MAINWINDOW_H
| [
"[email protected]"
] | |
2381ce1ba631e6a9134d4cc6230a360c19af908f | 33e2e66cb1d865f138a38d06858b0c93c846a90b | /src/common/const.h | dc1a44f79df8614960e165c789e8d580ddfb3b19 | [
"MIT"
] | permissive | duzhanyuan/raftkvdbdemo | 155c3e4c52f1f45afd09d8389e59643746df34b6 | 65a4215e95b3a41ca83010633d19272dd2ea37fd | refs/heads/master | 2021-05-04T15:06:05.045568 | 2016-12-06T07:48:32 | 2016-12-06T07:48:32 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 678 | h | // Copyright (c) 2017, Kai-Zhang
// Use of this source code is governed by a MIT license that can be
// found in the LICENSE file.
//
// Author: Kai Zhang ([email protected])
#ifndef ORION_COMMON_CONST_H
#define ORION_COMMON_CONST_H
#include <stdint.h>
#include <string>
namespace orion {
namespace status_code {
static const int32_t OK = 0;
static const int32_t DATABASE_ERROR = 1;
static const int32_t NOT_FOUND = 2;
static const int32_t INVALID = 3;
static const int32_t EXISTED = 4;
} // namespace status_code
namespace common {
static const std::string INTERNAL_NS("__internal__");
} // namespace common
} // namespace orion
#endif // ORION_COMMON_CONST_H
| [
"[email protected]"
] | |
94e982f4aa35ec034e3c8f6eb3af86c938514139 | 363176993f80d8acdf6f53ef0eb742a69afb008a | /chrome/browser/web_applications/components/web_app_file_handler_registration.h | 8fc1250b77f68aa5adb05b45bf6a7d10ff73fd59 | [
"BSD-3-Clause"
] | permissive | nico/chromium | 1ab2f891d6f05c8914f2f5a80e08e3564fd43110 | 777ca4b71dcae380958a8255a9f8e35c4623f5dc | refs/heads/master | 2023-03-14T16:29:08.617171 | 2020-03-19T23:11:13 | 2020-03-19T23:11:13 | 248,628,027 | 1 | 0 | BSD-3-Clause | 2020-03-19T23:46:43 | 2020-03-19T23:46:43 | null | UTF-8 | C++ | false | false | 1,789 | h | // Copyright 2019 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#ifndef CHROME_BROWSER_WEB_APPLICATIONS_COMPONENTS_WEB_APP_FILE_HANDLER_REGISTRATION_H_
#define CHROME_BROWSER_WEB_APPLICATIONS_COMPONENTS_WEB_APP_FILE_HANDLER_REGISTRATION_H_
#include <string>
#include "chrome/browser/web_applications/components/web_app_id.h"
#include "components/services/app_service/public/cpp/file_handler.h"
class Profile;
namespace web_app {
// True if file handlers are managed externally by the operating system, and
// Chrome supports file handling on this operating system.
// In practice, this is false on Chrome OS (as Chrome OS uses Chrome's installed
// apps to find file handlers), and on operating systems where Chrome doesn't
// know how to register file handlers.
bool ShouldRegisterFileHandlersWithOs();
// Do OS-specific registration to handle opening files with the specified
// |file_extensions| and |mime_types| with the PWA with the specified |app_id|.
// This may also involve creating a shim app to launch Chrome from.
// Note: Some operating systems (such as Chrome OS) may not need to do any work
// here.
void RegisterFileHandlersWithOs(const AppId& app_id,
const std::string& app_name,
Profile* profile,
const apps::FileHandlers& file_handlers);
// Undo the file extensions registration for the PWA with specified |app_id|.
// If a shim app was required, also removes the shim app.
void UnregisterFileHandlersWithOs(const AppId& app_id, Profile* profile);
} // namespace web_app
#endif // CHROME_BROWSER_WEB_APPLICATIONS_COMPONENTS_WEB_APP_FILE_HANDLER_REGISTRATION_H_
| [
"[email protected]"
] | |
9162de5d25b81db763221dd1b926703ee36a5a00 | fc47888757bc8b8eb18a0f4f13523625bece0b24 | /poj/1/1099.cc | 83ad44135a0c32b30e66c8cd660637e3879d45a9 | [
"MIT"
] | permissive | eagletmt/procon | 14f015d4cdb9eb324dbaf656b916848a1304c9b5 | adbe503eb3c1bbcc1538b2ee8988aa353937e8d4 | refs/heads/master | 2021-01-18T23:38:54.638301 | 2016-09-22T12:35:35 | 2016-09-22T12:35:35 | 18,721,091 | 1 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 2,492 | cc | #include <iostream>
#include <vector>
#include <iterator>
using namespace std;
int main(void)
{
int M;
int c = 1;
while (cin >> M && M != 0) {
vector<vector<int> > matrix(M, vector<int>(M, 0));
for (int i = 0; i < M; i++) {
for (int j = 0; j < M; j++) {
cin >> matrix[i][j];
}
}
int width = -1;
for (int i = 0; i < M; i++) {
if (matrix[0][i] == -1) {
// vertical
width += 1+1;
} else if (matrix[0][i] == 1) {
// horizontal
width += 5+1;
} else {
width += 3+1;
}
}
const int height = 5+4*(M-2);
vector<string> square(height, string(width, ' '));
for (int i = 0; i < M; i++) {
const int col = 4*i;
for (int j = 0, pos = 0; j < M; j++, pos++) {
if (matrix[i][j] == 1) {
// horizontal
square[col][pos++] = 'H';
square[col][pos++] = '-';
square[col][pos++] = 'O';
square[col][pos++] = '-';
square[col][pos++] = 'H';
} else if (matrix[i][j] == -1) {
// vertical
square[col-2][pos] = 'H';
square[col-1][pos] = '|';
square[col][pos] = 'O';
square[col+1][pos] = '|';
square[col+2][pos] = 'H';
pos++;
} else {
if (pos % 4 != 2) {
square[col][pos++] = 'H';
square[col][pos++] = '-';
square[col][pos] = 'O';
if (col >= 2 && square[col-2][pos] == ' ') {
square[col-1][pos] = '|';
square[col-2][pos] = 'H';
} else {
square[col+1][pos] = '|';
square[col+2][pos] = 'H';
}
pos++;
} else {
square[col][pos] = 'O';
if (col >= 2 && square[col-2][pos] == ' ') {
square[col-1][pos] = '|';
square[col-2][pos] = 'H';
} else {
square[col+1][pos] = '|';
square[col+2][pos] = 'H';
}
pos++;
square[col][pos++] = '-';
square[col][pos++] = 'H';
}
}
}
}
cout << "Case " << c++ << ':' << endl;
cout << endl;
for (int i = 0; i < width+2; i++) {
cout << '*';
}
cout << endl;
for (int i = 0; i < height; i++) {
cout << '*' << square[i] << '*' << endl;
}
for (int i = 0; i < width+2; i++) {
cout << '*';
}
cout << endl << endl;
}
return 0;
} | [
"[email protected]"
] | |
30ca46a965303d1c4f64f033b418debf651cebda | dacc64ddc2f9044666d9f84423476fb7745ff477 | /DeamonConnectionLinux.cpp | 0a73961f78a1ceaac610dc12d8fcbeb5b4e41c3a | [] | no_license | sarvex/Aircel | 63061889ba8d6be29c32e3ac7a0fe271c0ab754d | ae3de8e3f3022bf0484ee702dd243ed6756b65bc | refs/heads/main | 2023-07-07T08:04:48.105341 | 2023-06-23T22:20:01 | 2023-06-24T00:37:27 | 32,200,627 | 0 | 0 | null | 2023-09-05T11:20:14 | 2015-03-14T07:24:12 | C++ | UTF-8 | C++ | false | false | 1,506 | cpp | #include "Data.h"
#include "DeamonConnection.h"
#include "DeamonDatabase.h"
#include "DeamonSetting.h"
#include "Define.h"
#include <QDateTime>
#include <QDebug>
DeamonConnection* DeamonConnection::singleton = NULL;
DeamonConnection*
DeamonConnection::getInstance ()
{
if (NULL == singleton)
{
singleton = new DeamonConnection();
}
return(singleton);
}
DeamonConnection::DeamonConnection(
QObject * parent) :
QObject(parent),
bytesTransmitted (0.0),
bytesRecieved (0.0),
transmitOffset (0.0),
recieveOffset (0.0),
duration (0.0),
durationOffset (0.0)
{
this->timer = new QTimer;
QObject::connect (this->timer,
SIGNAL(timeout()),
this,
SLOT(onTimer()));
QObject::connect (this,
SIGNAL(modemConnected (bool)),
this,
SLOT (onModemConnected (bool)));
}
QString
DeamonConnection::getModemName ()
{
return "";
}
bool
DeamonConnection::connectDataCall ()
{
return true;
}
bool
DeamonConnection::disconnectDataCall ()
{
return true;
}
bool
DeamonConnection::createConnectionEntry ()
{
return true;
}
bool
DeamonConnection::removeConnectionEntry ()
{
return true;
}
bool
DeamonConnection::onResetUsage ()
{
return true;
}
bool
DeamonConnection::onTimer ()
{
return true;
}
bool
DeamonConnection::onModemConnected (bool status)
{
return status;
}
| [
"[email protected]"
] | |
72dbc3f4aef25f3b62ca3141c22f27b7272cb918 | ca9abc5c0755ca3e38dcaad8b54296ebb4994684 | /PlaytimeViewer/include/NSUtil.h | f31fccfabbd9961408a8a466f797c4e5f7ba0bf8 | [] | no_license | Sage-of-Mirrors/PlaytimeViewer | 70fa1e9dad36643bebbfc9106752ab0e83a9d6c6 | d12fc85a2ba761d5e36d4829c763863140b1ea12 | refs/heads/master | 2020-11-24T05:44:31.695356 | 2019-12-17T23:03:34 | 2019-12-17T23:03:34 | 227,990,947 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 155 | h | #pragma once
#include <switch.h>
#include <string>
NsApplicationControlData* GetAppControlData(uint64_t app_id);
std::string GetAppName(uint64_t app_id); | [
"[email protected]"
] | |
9892278f3db50d5060d044c92ec1aa301ff8c6b7 | ce8151aa1c513d46f55e7f7c53e5ab2a405202e9 | /소스.cpp | e9b3d9f9ba6dfcf0653c4a90ad8f94ba2d0f30aa | [] | no_license | BbakSsang/Baek | 6a7c00a9700060e314c6fa7a9abcc0c3f9a39da6 | 0a196de305250fcda04666e0a7be0263d74b3d8f | refs/heads/master | 2022-12-14T07:55:44.426420 | 2020-09-17T13:38:56 | 2020-09-17T13:38:56 | 288,448,362 | 0 | 0 | null | null | null | null | UHC | C++ | false | false | 1,480 | cpp | //#include<iostream>
//#include <string>
//using namespace std;
//
//
//int main(void) {
// ios::sync_with_stdio(false);
// cin.tie(NULL);
// int v1, v2;
// string num1, num2, result;
// cin >> num1 >> num2;
// int max = 0, temp = 0, min;
//
// if (num1.length() > num2.length()) {
// max = num1.length();
// min = num2.length();
// for (int i = 0; i < max - min; i++) {
// num2 = "0" + num2;
// }
// }
//
// else {
// max = num2.length();
// min = num1.length();
// for (int i = 0; i < max - min; i++) {
// num1 = "0" + num1;
// }
// }//앞에 0을 추가해주는구나 그만큼 사이즈 값이 같게..
//
// for (int i = max - 1; i >= 0; i--) { //거꾸로 맥스 스트링 사이즈가 끝까지 내린다
//
// v2 = num2[i] - 48; //48=='0'
// v1 = num1[i] - 48; //48=='0'
//
// if (v1 + v2 + temp >= 10) { //로직 같아 10보다 클때 다 더한값이 기초 템프는 0
//
// result.append(to_string(v1 + v2 + temp - 10));//append to_string? ??
// temp = 1; //왜 1이지
// }
// else {
// result.append(to_string(v1 + v2 + temp)); //
//
// temp = 0;
// }
// }
// if (temp == 1) {
// result.append("1");
// }
//
//
// for (int i = result.length() - 1; i >= 0; i--) {
// cout << result[i];
// }
// system("PAUSE");
//
//
// return 0;
//} | [
"[email protected]"
] | |
054dcf1040aaa4566b974dc10fddb50daada4796 | 73690acce99b294415635f1c5fcb17885910b9b8 | /Student.cpp | 8651d745b28f69892d6ea060b0b4e352c99780b6 | [] | no_license | 5aminz/NewProject--car--person--list- | ec29a80f63fba6d6d68c0ebfdc42f124ff04f2b2 | 7dd96a6c7919d5f6e17a1bd832a0cd9f33c5dd9b | refs/heads/master | 2021-01-13T02:08:47.351959 | 2014-09-16T01:29:39 | 2014-09-16T01:29:39 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 315 | cpp | #include "Student.h"
Student::Student (string major, int studentNo, int age, int sin, string firstName, string lastName):Person(age, sin, firstName, lastName){
this->major = major;
this->studentNo = studentNo;
}
const char* Student::Order(){
return (getLastName() + "," + getFirstName()).c_str();
}
| [
"[email protected]"
] | |
a69f6c5f41ab7598d384aeec1aaf9809f44ce1e5 | 947b74dc1a74cd6d05ac07fa08c14ef0085469a5 | /Chapter 1/2.cpp | 2ee3fa787859cc9b611f6e1473d7dfd2aacbcf2f | [] | no_license | arlenebatada/Cpp-solutions-to-Cracking-the-Coding-Interview | 59bedee62325d8dd06cb85f1a231cda7db900434 | 0e4bb3bd7e7a18ca25b24c2c9e483004aa284a6f | refs/heads/master | 2021-01-11T19:53:24.146690 | 2017-02-28T17:23:05 | 2017-02-28T17:23:05 | 79,418,216 | 1 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 545 | cpp | #include<iostream>
using namespace std;
int main()
{
string s1, s2;
getline(cin, s1);
getline(cin, s2);
int s1_length=s1.length();
if (s1_length != s2.length())
{
cout<< "not permutation";
return false;
}
int ascii_array[256];
for(int i=0; i< 256; i++)
{
ascii_array[i]=0;
}
for (int i=0; i < s1_length; i++)
{
ascii_array[(int)s1[i]]++;
}
for (int i=0; i< s1_length; i++)
{
if(--ascii_array[(int)s2[i]] < 0)
{
cout<< "not permutation";
return false;
}
}
cout<< "permutation";
return true;
}
| [
"[email protected]"
] | |
b2b28b7a29994fd8ef7dbd3f4d7840429b1cdfd9 | 093745115834d5469bec31dfb4b94b6903dfd731 | /Sorting and Searching/Sum_of_Two_Values.cpp | be3d190df77c2dfecaefc59b7aba32caf5803ab8 | [] | no_license | ryanlu2240/CSES_Problem_Set | 8e18e91fdd9076531439a5fa72ba59acec416b80 | 3fe554d69a06fc7d15a4bbe862e775734eda14c1 | refs/heads/master | 2023-03-10T21:47:08.964038 | 2021-03-01T11:33:32 | 2021-03-01T11:33:32 | 326,131,236 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 928 | cpp | #include <iostream>
#include <vector>
#include <algorithm>
#include <math.h>
#include <map>
#include <string>
#include <string.h>
#include <unistd.h>
#include <limits.h>
#include <iterator>
#define ll long long
using namespace std;
int main(void){
ios::sync_with_stdio(false);
cin.tie(NULL);
vector<pair<int,int> > input;
int n,x,t;
bool find=false;
cin>>n>>x;
for(int i=1;i<=n;i++){
cin>>t;
input.push_back(make_pair(t,i));
}
sort(input.begin(), input.end());
int l=0,r=input.size()-1;
while(l<r){
if(input[l].first+input[r].first==x){
cout<<min(input[l].second,input[r].second)<<' '<<max(input[l].second,input[r].second)<<endl;
find=true;
break;
}
else if(input[l].first+input[r].first > x) r--;
else if(input[l].first+input[r].first < x) l++;
}
if(!find) cout<<"IMPOSSIBLE"<<endl;
}
| [
"[email protected]"
] | |
addfcd51a2c78ccf62e96841ec2b4e48bccb4227 | 0eff74b05b60098333ad66cf801bdd93becc9ea4 | /second/download/curl/gumtree/curl_repos_function_2064.cpp | 452fe4241a991b78ef5b2a4b35b016e4281c0a61 | [] | no_license | niuxu18/logTracker-old | 97543445ea7e414ed40bdc681239365d33418975 | f2b060f13a0295387fe02187543db124916eb446 | refs/heads/master | 2021-09-13T21:39:37.686481 | 2017-12-11T03:36:34 | 2017-12-11T03:36:34 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 2,300 | cpp | Curl_addrinfo *
Curl_he2ai(const struct hostent *he, int port)
{
Curl_addrinfo *ai;
Curl_addrinfo *prevai = NULL;
Curl_addrinfo *firstai = NULL;
struct sockaddr_in *addr;
#ifdef ENABLE_IPV6
struct sockaddr_in6 *addr6;
#endif
CURLcode result = CURLE_OK;
int i;
char *curr;
if(!he)
/* no input == no output! */
return NULL;
DEBUGASSERT((he->h_name != NULL) && (he->h_addr_list != NULL));
for(i=0; (curr = he->h_addr_list[i]) != NULL; i++) {
size_t ss_size;
#ifdef ENABLE_IPV6
if(he->h_addrtype == AF_INET6)
ss_size = sizeof (struct sockaddr_in6);
else
#endif
ss_size = sizeof (struct sockaddr_in);
if((ai = calloc(1, sizeof(Curl_addrinfo))) == NULL) {
result = CURLE_OUT_OF_MEMORY;
break;
}
if((ai->ai_canonname = strdup(he->h_name)) == NULL) {
result = CURLE_OUT_OF_MEMORY;
free(ai);
break;
}
if((ai->ai_addr = calloc(1, ss_size)) == NULL) {
result = CURLE_OUT_OF_MEMORY;
free(ai->ai_canonname);
free(ai);
break;
}
if(!firstai)
/* store the pointer we want to return from this function */
firstai = ai;
if(prevai)
/* make the previous entry point to this */
prevai->ai_next = ai;
ai->ai_family = he->h_addrtype;
/* we return all names as STREAM, so when using this address for TFTP
the type must be ignored and conn->socktype be used instead! */
ai->ai_socktype = SOCK_STREAM;
ai->ai_addrlen = (curl_socklen_t)ss_size;
/* leave the rest of the struct filled with zero */
switch (ai->ai_family) {
case AF_INET:
addr = (void *)ai->ai_addr; /* storage area for this info */
memcpy(&addr->sin_addr, curr, sizeof(struct in_addr));
addr->sin_family = (unsigned short)(he->h_addrtype);
addr->sin_port = htons((unsigned short)port);
break;
#ifdef ENABLE_IPV6
case AF_INET6:
addr6 = (void *)ai->ai_addr; /* storage area for this info */
memcpy(&addr6->sin6_addr, curr, sizeof(struct in6_addr));
addr6->sin6_family = (unsigned short)(he->h_addrtype);
addr6->sin6_port = htons((unsigned short)port);
break;
#endif
}
prevai = ai;
}
if(result) {
Curl_freeaddrinfo(firstai);
firstai = NULL;
}
return firstai;
} | [
"[email protected]"
] | |
d8d3629675b4138384d51d04aff36cbdf2a83a0a | ed71c7bc5e116282084713b0ec36b1370780f99e | /icu/source/layout/PairPositioningSubtables.cpp | bbd9519f452db6917d5f7d4cd14432e367bbb094 | [
"ICU",
"LicenseRef-scancode-unicode"
] | permissive | alexswider/dropup.brigade | 12e6a12f82a44e568f39b98bb0dbafee78c0c3f7 | 13fa5308c30786b5bba98564a0959b3c05343502 | refs/heads/master | 2021-01-18T22:20:51.901107 | 2016-04-25T18:46:27 | 2016-04-25T18:46:27 | 47,217,645 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 6,327 | cpp | /*
*
* (C) Copyright IBM Corp. 1998-2006 - All Rights Reserved
*
*/
#include "LETypes.h"
#include "LEFontInstance.h"
#include "OpenTypeTables.h"
#include "GlyphPositioningTables.h"
#include "PairPositioningSubtables.h"
#include "ValueRecords.h"
#include "GlyphIterator.h"
#include "OpenTypeUtilities.h"
#include "LESwaps.h"
U_NAMESPACE_BEGIN
le_uint32 PairPositioningSubtable::process(GlyphIterator *glyphIterator, const LEFontInstance *fontInstance) const
{
switch(SWAPW(subtableFormat))
{
case 0:
return 0;
case 1:
{
const PairPositioningFormat1Subtable *subtable = (const PairPositioningFormat1Subtable *) this;
return subtable->process(glyphIterator, fontInstance);
}
case 2:
{
const PairPositioningFormat2Subtable *subtable = (const PairPositioningFormat2Subtable *) this;
return subtable->process(glyphIterator, fontInstance);
}
default:
return 0;
}
}
le_uint32 PairPositioningFormat1Subtable::process(GlyphIterator *glyphIterator, const LEFontInstance *fontInstance) const
{
LEGlyphID firstGlyph = glyphIterator->getCurrGlyphID();
le_int32 coverageIndex = getGlyphCoverage(firstGlyph);
GlyphIterator tempIterator(*glyphIterator);
if (coverageIndex >= 0 && glyphIterator->next()) {
Offset pairSetTableOffset = SWAPW(pairSetTableOffsetArray[coverageIndex]);
PairSetTable *pairSetTable = (PairSetTable *) ((char *) this + pairSetTableOffset);
le_uint16 pairValueCount = SWAPW(pairSetTable->pairValueCount);
le_int16 valueRecord1Size = ValueRecord::getSize(SWAPW(valueFormat1));
le_int16 valueRecord2Size = ValueRecord::getSize(SWAPW(valueFormat2));
le_int16 recordSize = sizeof(PairValueRecord) - sizeof(ValueRecord) + valueRecord1Size + valueRecord2Size;
LEGlyphID secondGlyph = glyphIterator->getCurrGlyphID();
const PairValueRecord *pairValueRecord = NULL;
if (pairValueCount != 0) {
pairValueRecord = findPairValueRecord((TTGlyphID) LE_GET_GLYPH(secondGlyph), pairSetTable->pairValueRecordArray, pairValueCount, recordSize);
}
if (pairValueRecord == NULL) {
return 0;
}
if (valueFormat1 != 0) {
pairValueRecord->valueRecord1.adjustPosition(SWAPW(valueFormat1), (char *) this, tempIterator, fontInstance);
}
if (valueFormat2 != 0) {
const ValueRecord *valueRecord2 = (const ValueRecord *) ((char *) &pairValueRecord->valueRecord1 + valueRecord1Size);
valueRecord2->adjustPosition(SWAPW(valueFormat2), (char *) this, *glyphIterator, fontInstance);
}
// back up glyphIterator so second glyph can be
// first glyph in the next pair
glyphIterator->prev();
return 1;
}
return 0;
}
le_uint32 PairPositioningFormat2Subtable::process(GlyphIterator *glyphIterator, const LEFontInstance *fontInstance) const
{
LEGlyphID firstGlyph = glyphIterator->getCurrGlyphID();
le_int32 coverageIndex = getGlyphCoverage(firstGlyph);
GlyphIterator tempIterator(*glyphIterator);
if (coverageIndex >= 0 && glyphIterator->next()) {
LEGlyphID secondGlyph = glyphIterator->getCurrGlyphID();
const ClassDefinitionTable *classDef1 = (const ClassDefinitionTable *) ((char *) this + SWAPW(classDef1Offset));
const ClassDefinitionTable *classDef2 = (const ClassDefinitionTable *) ((char *) this + SWAPW(classDef2Offset));
le_int32 class1 = classDef1->getGlyphClass(firstGlyph);
le_int32 class2 = classDef2->getGlyphClass(secondGlyph);
le_int16 valueRecord1Size = ValueRecord::getSize(SWAPW(valueFormat1));
le_int16 valueRecord2Size = ValueRecord::getSize(SWAPW(valueFormat2));
le_int16 class2RecordSize = valueRecord1Size + valueRecord2Size;
le_int16 class1RecordSize = class2RecordSize * SWAPW(class2Count);
const Class1Record *class1Record = (const Class1Record *) ((char *) class1RecordArray + (class1RecordSize * class1));
const Class2Record *class2Record = (const Class2Record *) ((char *) class1Record->class2RecordArray + (class2RecordSize * class2));
if (valueFormat1 != 0) {
class2Record->valueRecord1.adjustPosition(SWAPW(valueFormat1), (char *) this, tempIterator, fontInstance);
}
if (valueFormat2 != 0) {
const ValueRecord *valueRecord2 = (const ValueRecord *) ((char *) &class2Record->valueRecord1 + valueRecord1Size);
valueRecord2->adjustPosition(SWAPW(valueFormat2), (const char *) this, *glyphIterator, fontInstance);
}
// back up glyphIterator so second glyph can be
// first glyph in the next pair
glyphIterator->prev();
return 1;
}
return 0;
}
const PairValueRecord *PairPositioningFormat1Subtable::findPairValueRecord(TTGlyphID glyphID, const PairValueRecord *records, le_uint16 recordCount, le_uint16 recordSize) const
{
#if 1
// The OpenType spec. says that the ValueRecord table is
// sorted by secondGlyph. Unfortunately, there are fonts
// around that have an unsorted ValueRecord table.
const PairValueRecord *record = records;
for(le_int32 r = 0; r < recordCount; r += 1) {
if (SWAPW(record->secondGlyph) == glyphID) {
return record;
}
record = (const PairValueRecord *) ((char *) record + recordSize);
}
#else
le_uint8 bit = OpenTypeUtilities::highBit(recordCount);
le_uint16 power = 1 << bit;
le_uint16 extra = (recordCount - power) * recordSize;
le_uint16 probe = power * recordSize;
const PairValueRecord *record = records;
const PairValueRecord *trial = (const PairValueRecord *) ((char *) record + extra);
if (SWAPW(trial->secondGlyph) <= glyphID) {
record = trial;
}
while (probe > recordSize) {
probe >>= 1;
trial = (const PairValueRecord *) ((char *) record + probe);
if (SWAPW(trial->secondGlyph) <= glyphID) {
record = trial;
}
}
if (SWAPW(record->secondGlyph) == glyphID) {
return record;
}
#endif
return NULL;
}
U_NAMESPACE_END
| [
"[email protected]"
] | |
0f16a4a75f579941d353e36c5cb916dba58def25 | 7fb6c68e6bf7cd3224ce02aea55ea5b4cee607a3 | /facecat_cpp/include/chart/ChartTitleBar.h | 690434604f5ef9b6787d579c776d1f4506fa88c6 | [
"BSD-2-Clause"
] | permissive | kknet/facecat | db02b26fd6ca1c472d156cc18e9a5d9c2b77e8ec | bd33eeda1e1b552a2296c833b89254a8e2a9724b | refs/heads/master | 2020-08-03T13:50:27.597696 | 2019-09-28T09:25:21 | 2019-09-28T09:25:21 | null | 0 | 0 | null | null | null | null | GB18030 | C++ | false | false | 6,590 | h | /*捂脸猫FaceCat框架 v1.0
1.创始人-矿洞程序员-上海卷卷猫信息技术有限公司-脉脉KOL-陶德 (微信号:suade1984);
2.联合创始人-上海卷卷猫信息技术有限公司-周淋霞;
3.联合创始人-肖添龙(微信号:xiaotianlong_luu);
4.联合开发者-陈晓阳(微信号:chenxiaoyangzxy),助理-朱炜(微信号:cnnic_zhu)
5.该框架开源协议为BSD,欢迎对我们的创业活动进行各种支持,欢迎更多开发者加入。
包含C/C++,Java,C#,iOS,MacOS,Linux六个版本的图形和通讯服务框架。
*/
#ifndef __CHARTTITLEBAR_H__
#define __CHARTTITLEBAR_H__
#pragma once
#include "..\\..\\stdafx.h"
#include "..\\core\\FCPaint.h"
#include "FCDataTable.h"
#include "Enums.h"
#include "ChartDiv.h"
namespace FaceCat{
class ChartDiv;
/*
* 标题栏
*/
class ChartTitle : public FCProperty{
protected:
/**
* 保留小数的位数
*/
int m_digit;
/**
* 字段名称
*/
int m_fieldName;
/**
* 字段文字
*/
String m_fieldText;
/**
* 标题显示模式
*/
TextMode m_fieldTextMode;
/**
* 标题的分隔符
*/
String m_fieldTextSeparator;
/**
* 文字的颜色
*/
Long m_textColor;
/**
* 是否可见
*/
bool m_visible;
public:
/**
* 创建标题
* @param fieldName 字段名称
* @param fieldText 字段文字
* @param textColor 文字颜色
* @param digit 保留小数位数
* @param visible 是否可见
*/
ChartTitle(int fieldName, const String& fieldText, Long color, int digit, bool visible);
/**
* 获取保留小数的位数
*/
virtual int getDigit();
/**
* 设置保留小数的位数
*/
virtual void setDigit(int digit);
/**
* 获取字段名称
*/
virtual int getFieldName();
/**
* 设置字段名称
*/
virtual void setFieldName(int fieldName);
/**
* 获取字段文字
*/
virtual String getFieldText();
/**
* 设置字段文字
*/
virtual void setFieldText(const String& fieldText);
/**
* 获取标题显示模式
*/
virtual TextMode getFieldTextMode();
/**
* 设置标题显示模式
*/
virtual void setFieldTextMode(TextMode fieldTextMode);
/**
* 获取标题的分隔符
*/
virtual String getFieldTextSeparator();
/**
* 设置标题的分隔符
*/
virtual void setFieldTextSeparator(const String& fieldTextSeparator);
/**
* 获取文字的颜色
*/
virtual Long getTextColor();
/**
* 设置文字的颜色
*/
virtual void setTextColor(Long textColor);
/**
* 获取是否可见
*/
virtual bool isVisible();
/**
* 设置是否可见
*/
virtual void setVisible(bool visible);
public:
/**
* 获取属性值
* @param name 属性名称
* @param value 返回属性值
* @param type 返回属性类型
*/
virtual void getProperty(const String& name, String *value, String *type);
/**
* 获取属性名称列表
*/
virtual ArrayList<String> getPropertyNames();
/**
* 设置属性值
* @param name 属性名称
* @param value 属性值
*/
virtual void setProperty(const String& name, const String& value);
};
/*
* 标题栏
*/
class ChartTitleBar : public FCProperty{
protected:
/**
* 是否允许用户绘图
*/
bool m_allowUserPaint;
/**
* 字体
*/
FCFont *m_font;
/*
* 文字颜色
*/
Long m_textColor;
/**
* 标题高度
*/
int m_height;
/**
* 最大标题行数
*/
int m_maxLine;
/**
* 是否显示标题下面的线
*/
bool m_showUnderLine;
/**
* 层的标题
*/
String m_text;
/**
* 是否显示标题下面的线的颜色
*/
Long m_underLineColor;
/**
* 是否显示标题
*/
bool m_visible;
public:
/**
* 图层标题栏
*/
ChartTitleBar();
/*
* 析构函数
*/
virtual ~ChartTitleBar();
/*
* 所有标题
*/
ArrayList<ChartTitle*> Titles;
/**
* 获取是否允许用户绘图
*/
virtual bool allowUserPaint();
/**
* 设置是否允许用户绘图
*/
virtual void setAllowUserPaint(bool allowUserPaint);
/**
* 获取字体
*/
virtual FCFont* getFont();
/**
* 设置字体
*/
virtual void setFont(FCFont *font);
/**
* 获取标题高度
*/
virtual int getHeight();
/**
* 设置标题高度
*/
virtual void setHeight(int height);
/**
* 获取最大标题行数
*/
virtual int getMaxLine();
/**
* 设置最大标题行数
*/
virtual void setMaxLine(int maxLine);
/**
* 获取是否显示标题下面的线
*/
virtual bool showUnderLine();
/**
* 设置是否显示标题下面的线
*/
virtual void setShowUnderLine(bool showUnderLine);
/**
* 获取层的标题
*/
virtual String getText();
/**
* 设置层的标题
*/
virtual void setText(const String& text);
/**
* 获取标题的文字颜色
*/
virtual Long getTextColor();
/**
* 设置标题的文字颜色
*/
virtual void setTextColor(Long textColor);
/**
* 获取是否显示标题下面的线的颜色
*/
virtual Long getUnderLineColor();
/**
* 设置是否显示标题下面的线的颜色
*/
virtual void setUnderLineColor(Long underLineColor);
/**
* 获取是否显示标题
*/
virtual bool isVisible();
/**
* 设置是否显示标题
*/
virtual void setVisible(bool visible);
public:
/**
* 获取属性值
* @param name 属性名称
* @param value 返回属性值
* @param type 返回属性类型
*/
virtual void getProperty(const String& name, String *value, String *type);
/**
* 获取属性名称列表
*/
virtual ArrayList<String> getPropertyNames();
/**
* 重绘方法
* @param paint 绘图对象
* @param div 图层
* @param rect 区域
*/
virtual void onPaint(FCPaint *paint, ChartDiv *div, const FCRect& rect);
/**
* 设置属性值
* @param name 属性名称
* @param value 属性值
*/
virtual void setProperty(const String& name, const String& value);
};
}
#endif | [
"[email protected]"
] | |
a541f4be70f89976d465e02dea9edf1cbe8d4232 | 01a42b69633daf62a2eb3bb70c5b1b6e2639aa5f | /SCUM_Hiking_Backpack_07_classes.hpp | a27bf19c8996ed8c1613d0046f4b7855de4e2610 | [] | no_license | Kehczar/scum_sdk | 45db80e46dac736cc7370912ed671fa77fcb95cf | 8d1770b44321a9d0b277e4029551f39b11f15111 | refs/heads/master | 2022-07-25T10:06:20.892750 | 2020-05-21T11:45:36 | 2020-05-21T11:45:36 | 265,826,541 | 1 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 816 | hpp | #pragma once
// Scum 3.79.22573 (UE 4.24)
#ifdef _MSC_VER
#pragma pack(push, 0x8)
#endif
namespace Classes
{
//---------------------------------------------------------------------------
//Classes
//---------------------------------------------------------------------------
// BlueprintGeneratedClass Hiking_Backpack_07.Hiking_Backpack_07_C
// 0x0000 (0x0730 - 0x0730)
class AHiking_Backpack_07_C : public AClothesItem
{
public:
static UClass* StaticClass()
{
static auto ptr = UObject::FindClass("BlueprintGeneratedClass Hiking_Backpack_07.Hiking_Backpack_07_C");
return ptr;
}
void UpdateMaterialParamsOnClients();
void SetDirtiness(float* dirtiness);
void OnRep_MaterialParameters();
int GetWarmth();
int GetCapacityY();
int GetCapacityX();
};
}
#ifdef _MSC_VER
#pragma pack(pop)
#endif
| [
"[email protected]"
] | |
8b801b1d1ac97da12c523f2efcf20c4ba00ba609 | 5e4776dc94001ad13be80a677631a9d7fe8d4b2a | /libcomtrade/src/newcomtd.h | 9ce22b9a57a3091ece6779a0e65a3ff85fcadead | [
"MIT"
] | permissive | mtcheou/adsp | 8b7694aae0c7893a4cec05022972a5fbf5c62d60 | d9b7c2460f1b8d6bd8e021eae815d0c0c5b27c23 | refs/heads/master | 2020-05-29T23:35:11.969119 | 2019-11-01T19:28:18 | 2019-11-01T19:28:18 | 26,556,935 | 0 | 0 | null | null | null | null | ISO-8859-1 | C++ | false | false | 1,710 | h | #ifndef NEWCOMTD_H
#define NEWCOMTD_H
/*****************************************************************************
Projeto : SISTEMA INTEGRADO DE APOIO `A ANALISE DE PERTURBACOES - SINAPE
Nome : NEWCOMTD.H
Funcao : Rotinas para conversão entre formato interno (CConfigCOMTRADE)
e o formato COMTRADE (IEEE standard Common Format for Transient
Data Exchange for power systems), IEEE C37.111-1991.
Este tradutor gera COMTRADE em formato binario
C : C++
Autor : MAMR
Data : mar/95
Data : data da primeira modificacao
Modific.: descricao dos itens modificados
...
Data : data da ultima modificacao
Modific.: descricao dos itens modificados
*****************************************************************************/
#include "bincomtd.h"
//#include "newcomtd_99.h"
class CComtrade97: public CBinaryComtrade {
public:
CComtrade97(size_t memoria_disponivel=0, char* arquivo_=NULL)
:CBinaryComtrade( memoria_disponivel, arquivo_) {};
~CComtrade97() {};
// preenche config a partir do arquivo registrado em SetNomeArquivo
int ExtrairConfiguracao(CConfigComtrade* config, char* erro=NULL);
int ExtrairConfiguracao_(CConfigComtrade* config, char* erro=NULL);
// criar arquivo a partir de config no formato do tradutor
int InserirConfiguracao(CConfigComtrade* config, char* erro=NULL);
int InserirConfiguracao_(CConfigComtrade* config, char* erro=NULL);
// New
int LerLinhaCanalAnalogico(CConfigComtrade* config, CCanal *canal, int cont, char* erro=NULL);
int LerLinhaCanalDigital(CConfigComtrade* config, CCanal *canal, int cont, char* erro=NULL);
};
#endif
| [
"[email protected]"
] | |
0f391a987f944072428a766cd4f0ca53d1c1e587 | c4c4d7fa797fc4da4c0557effe20fffb7c3a2fed | /src/in_ncsf/SoundView.h | edc62ffa73b3353c42c985ee2f47a5f5cdb60c8b | [
"BSD-3-Clause"
] | permissive | bauxite69/in_xsf | 61addc63e9a55ceb1eb9729d53e5f719f017c52e | 6d78469746b17bf1a9356c7a26ecd2850ba46eb3 | refs/heads/master | 2023-04-04T22:08:02.382396 | 2021-04-20T01:20:36 | 2021-04-20T01:20:36 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 1,597 | h | /*
* xSF - Sound View Dialog
* By Naram Qashat (CyberBotX) [[email protected]]
*
* Partially based on the vio*sf framework
*
* Based on the Sound View dialog box from DeSmuME
* http://desmume.org/
*/
#pragma once
#ifdef __GNUC__
# pragma GCC diagnostic push
# pragma GCC diagnostic ignored "-Wold-style-cast"
#elif defined(__clang__)
# pragma clang diagnostic push
# pragma clang diagnostic ignored "-Wold-style-cast"
#endif
#include <wx/dialog.h>
#ifdef __GNUC__
# pragma GCC diagnostic pop
#elif defined(__clang__)
# pragma clang diagnostic pop
#endif
#include "SSEQPlayer/consts.h"
class wxCheckBox;
class wxGauge;
class wxIdleEvent;
class wxStaticText;
class wxWindow;
class XSFConfig_NCSF;
class XSFPlayer_NCSF;
struct SoundViewData
{
wxGauge *volumeGauge = nullptr;
wxStaticText *volumeLabel = nullptr;
wxStaticText *repeatModeLabel = nullptr;
wxStaticText *stateLabel = nullptr;
wxStaticText *timerValueLabel = nullptr;
wxCheckBox *muteCheckBox = nullptr;
wxGauge *panGauge = nullptr;
wxStaticText *panLabel = nullptr;
wxStaticText *formatLabel = nullptr;
wxStaticText *loopStartLabel = nullptr;
wxStaticText *soundPosLenLabel = nullptr;
ChannelState lastState = ChannelState::Start;
};
class SoundView : public wxDialog
{
void GaugeSetValueImmediate(wxGauge *gauge, int value);
public:
SoundView(wxWindow *parent, XSFConfig_NCSF *ncsfConfig, XSFPlayer_NCSF *ncsfPlayer);
void OnIdle(wxIdleEvent &evt);
void SyncToConfig();
void Update();
XSFConfig_NCSF *config;
XSFPlayer_NCSF *player;
SoundViewData channelData[16];
bool volumeModeAlternative;
};
| [
"[email protected]"
] |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.