Give some information about your project. What is this project? What technologies does it use? Describe your knowledge and mention what you expect to get from the audience.
Select technologies, which are used in your project (e.g. - C++ / Java)
Select required roles for your project (e.g. - Designer/Programmer)


RayTracer
src
linalg
Classes
Vector3D.h File Reference
#include <iostream>
Include dependency graph for Vector3D.h:
This graph shows which files directly or indirectly include this file:
Go to the source code of this file.
Classes
class
Vector3D
Vector in 3D space with usual arithmetics.
More...
Generated by
1.8.15


Tablet of Vision:
There's a disturbance near the tablet.
Iron may be stronger than the warrior, but that doesn't guarantee the outcome of this battle.
He bears the scars of countless battles, as do I.
Is that the tablet, or is it an illusion? The sound of clashing swords snaps you out of your torpor.
Examine the area.


Django administration
Welcome,
coordt
.
Change password
/
Log out
Home
›
Simpleapp
› Lookup models
Select lookup model to change
Add lookup model
‹ 2011
June 7
Filter
By staff status
All
Yes
No
By superuser status
All
Yes
No
By active
All
Yes
No
Action:
---------
Delete selected lookup models
Go
0 of 5 selected
All 24 selected
Select all 24 lookup models
Clear selection
Lookup model
omega
psi
chi
phi
upsilon
1
2
3
4
5
24 lookup models
Show all


|
NUC472_NUC442_BSP V3.03.004
The Board Support Package for NUC472/NUC442
|
Macros | |
| #define | I2S_ENABLE_TXDMA(i2s) |
| Enable I2S Tx DMA function. I2S requests DMA to transfer data to Tx FIFO. More... | |
| #define | I2S_DISABLE_TXDMA(i2s) |
| Disable I2S Tx DMA function. I2S requests DMA to transfer data to Tx FIFO. More... | |
| #define | I2S_ENABLE_RXDMA(i2s) |
| Enable I2S Rx DMA function. I2S requests DMA to transfer data from Rx FIFO. More... | |
| #define | I2S_DISABLE_RXDMA(i2s) |
| Disable I2S Rx DMA function. I2S requests DMA to transfer data from Rx FIFO. More... | |
| #define | I2S_ENABLE_TX(i2s) |
| Enable I2S Tx function . More... | |
| #define | I2S_DISABLE_TX(i2s) |
| Disable I2S Tx function . More... | |
| #define | I2S_ENABLE_RX(i2s) |
| Enable I2S Rx function . More... | |
| #define | I2S_DISABLE_RX(i2s) |
| Disable I2S Rx function . More... | |
| #define | I2S_ENABLE_TX_MUTE(i2s) |
| Enable Tx Mute function . More... | |
| #define | I2S_DISABLE_TX_MUTE(i2s) |
| Disable Tx Mute function . More... | |
| #define | I2S_CLR_TX_FIFO(i2s) |
| Clear Tx FIFO. Internal pointer is reset to FIFO start point. More... | |
| #define | I2S_CLR_RX_FIFO(i2s) |
| Clear Rx FIFO. Internal pointer is reset to FIFO start point. More... | |
| #define | I2S_WRITE_TX_FIFO(i2s, u32Data) |
| Write data to I2S Tx FIFO. More... | |
| #define | I2S_READ_RX_FIFO(i2s) |
| Read Rx FIFO. More... | |
| #define | I2S_GET_INT_FLAG(i2s, u32Mask) |
| This function gets the interrupt flag according to the mask parameter. More... | |
| #define | I2S_CLR_INT_FLAG(i2s, u32Mask) |
| This function clears the interrupt flag according to the mask parameter. More... | |
| #define | I2S_GET_TX_FIFO_LEVEL(i2s) |
| Get transmit FIFO level. More... | |
| #define | I2S_GET_RX_FIFO_LEVEL(i2s) |
| Get receive FIFO level. More... | |
Functions | |
| static __INLINE void | I2S_ENABLE_TX_ZCD (I2S_T *i2s, uint32_t u32ChMask) |
| Enable zero cross detect function. More... | |
| static __INLINE void | I2S_DISABLE_TX_ZCD (I2S_T *i2s, uint32_t u32ChMask) |
| Disable zero cross detect function. More... | |
| static __INLINE void | I2S_SET_MONO_RX_CHANNEL (I2S_T *i2s, uint32_t u32Ch) |
| This function sets the recording source channel when mono mode is used. More... | |
| uint32_t | I2S_Open (I2S_T *i2s, uint32_t u32MasterSlave, uint32_t u32SampleRate, uint32_t u32WordWidth, uint32_t u32Channels, uint32_t u32DataFormat, uint32_t u32AudioInterface) |
| This function configures some parameters of I2S interface for general purpose use. The sample rate may not be used from the parameter, it depends on system's clock settings, but real sample rate used by system will be returned for reference. More... | |
| void | I2S_Close (I2S_T *i2s) |
| Disable I2S function and I2S clock. More... | |
| void | I2S_EnableInt (I2S_T *i2s, uint32_t u32Mask) |
| This function enables the interrupt according to the mask parameter. More... | |
| void | I2S_DisableInt (I2S_T *i2s, uint32_t u32Mask) |
| This function disables the interrupt according to the mask parameter. More... | |
| uint32_t | I2S_EnableMCLK (I2S_T *i2s, uint32_t u32BusClock) |
| Enable MCLK . More... | |
| void | I2S_DisableMCLK (I2S_T *i2s) |
| Disable MCLK . More... | |
| void | I2S_SetFIFO (I2S_T *i2s, uint32_t u32TxThreshold, uint32_t u32RxThreshold) |
| Configure FIFO threshold setting. More... | |
| static uint32_t | I2S_GetSourceClockFreq (I2S_T *i2s) |
| This function is used to get I2S source clock frequency. More... | |
| #define I2S_CLR_INT_FLAG | ( | i2s, | |
| u32Mask | |||
| ) |
| #define I2S_CLR_RX_FIFO | ( | i2s | ) |
| #define I2S_CLR_TX_FIFO | ( | i2s | ) |
| #define I2S_DISABLE_RX | ( | i2s | ) |
| #define I2S_DISABLE_RXDMA | ( | i2s | ) |
| #define I2S_DISABLE_TX | ( | i2s | ) |
| #define I2S_DISABLE_TX_MUTE | ( | i2s | ) |
| #define I2S_DISABLE_TXDMA | ( | i2s | ) |
| #define I2S_ENABLE_RX | ( | i2s | ) |
| #define I2S_ENABLE_RXDMA | ( | i2s | ) |
| #define I2S_ENABLE_TX | ( | i2s | ) |
| #define I2S_ENABLE_TX_MUTE | ( | i2s | ) |
| #define I2S_ENABLE_TXDMA | ( | i2s | ) |
| #define I2S_GET_INT_FLAG | ( | i2s, | |
| u32Mask | |||
| ) |
| #define I2S_GET_RX_FIFO_LEVEL | ( | i2s | ) |
| #define I2S_GET_TX_FIFO_LEVEL | ( | i2s | ) |
| #define I2S_READ_RX_FIFO | ( | i2s | ) |
| #define I2S_WRITE_TX_FIFO | ( | i2s, | |
| u32Data | |||
| ) |
| void I2S_Close | ( | I2S_T * | i2s | ) |
|
static |
| void I2S_DisableInt | ( | I2S_T * | i2s, |
| uint32_t | u32Mask | ||
| ) |
| void I2S_DisableMCLK | ( | I2S_T * | i2s | ) |
|
static |
| void I2S_EnableInt | ( | I2S_T * | i2s, |
| uint32_t | u32Mask | ||
| ) |
| uint32_t I2S_EnableMCLK | ( | I2S_T * | i2s, |
| uint32_t | u32BusClock | ||
| ) |
|
static |
| uint32_t I2S_Open | ( | I2S_T * | i2s, |
| uint32_t | u32MasterSlave, | ||
| uint32_t | u32SampleRate, | ||
| uint32_t | u32WordWidth, | ||
| uint32_t | u32Channels, | ||
| uint32_t | u32DataFormat, | ||
| uint32_t | u32AudioInterface | ||
| ) |
This function configures some parameters of I2S interface for general purpose use. The sample rate may not be used from the parameter, it depends on system's clock settings, but real sample rate used by system will be returned for reference.
| [in] | i2s | is the base address of I2S module. |
| [in] | u32MasterSlave | I2S operation mode. Valid values are: |
| [in] | u32SampleRate | Sample rate |
| [in] | u32WordWidth | Data length. Valid values are: |
| [in] | u32Channels | Audio format. Valid values are: |
| [in] | u32DataFormat | Data format. Valid values are: |
| [in] | u32AudioInterface | Audio interface. Valid values are: |
Definition at line 99 of file i2s.c.
|
static |
This function sets the recording source channel when mono mode is used.
| [in] | i2s | is the base address of I2S module. |
| [in] | u32Ch | left or right channel. Valid values are: |
| void I2S_SetFIFO | ( | I2S_T * | i2s, |
| uint32_t | u32TxThreshold, | ||
| uint32_t | u32RxThreshold | ||
| ) |
Configure FIFO threshold setting.
| [in] | i2s | The pointer of the specified I2S module. |
| [in] | u32TxThreshold | Decides the TX FIFO threshold. It could be 0 ~ 7. |
| [in] | u32RxThreshold | Decides the RX FIFO threshold. It could be 0 ~ 7. |
Set TX FIFO threshold and RX FIFO threshold configurations.


About Me
Hello! My name is David. I am a student at Code Fellows in Seattle, Washington.  I grew up in a performing arts home in China. Although thousands of miles away, I've always felt a special connection to the city of Seattle. My dad is a voice actor; he did the voice over for Tom Hanks' character in the movie Sleepless in Seattle, that was the first time when the name of this beautiful city made its first apperance in my life. As a young boy in China, I also remember watching NBA legend Ray Allen sinking long arc shots in the green and yellow Supersonics uniform. I just knew I have to be there one day. After moving to America at 12, spenting 4 years in U.S. Navy after high school, 4 years at Michigan State University, here I am!
My Experience
After graduating high school in 2010, I enlisted in the U.S. Navy. I was an avionics technician in an F/A-18E Super Hornet fighter jet squdron, known as the "VFA-151 Vigilantes", in Naval Air Station Lemoore, California. I performed daily inspections, as well as maintaining various avionics equipment aboard the fighter jet. The Navy has brought me to some cool places! Here are some countries that I've been to while being deployed.
My Education
As soon as I received my honorable discharge from the Navy in 2014, I attended Michigan State University in East Lansing, Michigan. I was a student at MSU's Athletic Training Education Program, where I worked with elite Division I athletes. I had the opportunity to be a part of MSU's ice hockey team, gymnastics, swim and dive, as well as men's basketball. I graduated in May of 2018 with a B.S. in Athletic Training.
Fun Facts About Me!
- Skateboarding is my passion. I ride my board everywhere.
- I love Mexican food. There's nothing like grilling some carne asadas over charcoal.
- I am a big fan of hip-hop artist Drake.
- I enjoy getting to know different people and experiencing different cultures.
- I have a soft spot for really sour candies, like Sour Patch Kids.
- Sneakers catch my eye; I think it's cool that people express themselves through clothing, especially footwear. I have 5 pairs of sneakers.
- I've lived in Michigan, Florida, and California before moving to Washington.


Python Environment
Basics
To avoid errors later, it's best to update all the packages in the default environment. Open the Anaconda Prompt application. In the prompt, run the following commands:
conda upgrade conda conda upgrade --all
If you are seeing the following "conda command not found" and are using ZShell, you have to do the following:
export PATH="/Users/username/anaconda/bin:$PATH"
or update above command line to your .zsh_config file.
- Install Package:Once you have Anaconda installed, managing packages is fairly straightforward. To install a package, type
conda install package_name
in your terminal. For example, to install numpy, type
conda install numpy.
You can install multiple packages at the same time. Something like conda install numpy scipy pandas will install all those packages simultaneously. It's also possible to specify which version of a package you want by adding the version number such as
conda install numpy=1.10.
Conda also automatically installs dependencies for you. For example scipy depends on numpy, it uses and requires numpy. If you install just scipy (conda install scipy), Conda will also install numpy if it isn't already installed.
- Remove Package : Most of the commands are pretty intuitive. To uninstall, use
conda remove package_name
To update a package
conda update package_name
- Update Package : If you want to update all packages in an environment, which is often useful, use
conda update --all
- List Package: to list installed packages, it's
conda list
- Search Package Name: If you don't know the exact name of the package you're looking for, you can try searching with
conda search search_term
For example, I know I want to install Beautiful Soup, but I'm not sure of the exact package name. So, I try
conda search beautifulsoup
Environments
Conda can be used to create environments to isolate your projects. To create an environment, use
conda create -n env_name list of packages in your terminal
- Name : Here -n env_name sets the name of your environment (-n for name) and list of packages is the list of packages you want installed in the environment. For example, to create an environment named my_env and install numpy in it, type
conda create -n my_env numpy
- Version: When creating an environment, you can specify which version of Python to install in the environment. This is useful when you're working with code in both Python 2.x and Python 3.x. To create an environment with a specific Python version, do something like
conda create -n py3 python=3 or conda create -n py2 python=2
- Different Python versions : I actually have both of these environments on my personal computer. I use them as general environments not tied to any specific project, but rather for general work with each Python version easily accessible. These commands will install the most recent version of Python 3 and 2, respectively. To install a specific version, use
conda create -n py python=3.3
- Activate Environment : for Python 3.3.
Once you have an environment created, use
source activate my_env
to enter it on OSX/Linux. On Windows, use
activate my_env
When you're in the environment, you'll see the environment name in the terminal prompt. Something like (my_env) ~ $. The environment has only a few packages installed by default, plus the ones you installed when creating it. You can check this out with conda list. Installing packages in the environment is the same as before:
conda install package_name
Only this time, the specific packages you install will only be available when you're in the environment. To leave the environment, type
source deactivate (on OSX/Linux)
On Windows, use
deactivate
Saving and loading environments
- Export the environment : A really useful feature is sharing environments so others can install all the packages used in your code, with the correct versions. You can save the packages to a YAML file with
conda env export > environment.yaml
The first part
conda env export
writes out all the packages in the environment, including the Python version. Above you can see the name of the environment and all the dependencies (along with versions) are listed. The second part of the export command,
> environment.yaml
- Create environment from exported file : writes the exported text to a YAML file
environment.yaml
. This file can now be shared and others will be able to create the same environment you used for the project.
To create an environment from an environment file use
conda env create -f environment.yaml
This will create a new environment with the same name listed in environment.yaml
.
Listing environments
- List the environments : If you forget what your environments are named (happens to me sometimes), use
conda env list
to list out all the environments you've created. You should see a list of environments, there will be an asterisk next to the environment you're currently in. The default environment, the environment used when you aren't in one, is called root
.
Removing environments
If there are environments you don't use anymore,
conda env remove -n env_name
will remove the specified environment (here, named env_name
).
Using environments
One thing that’s helped me tremendously is having separate environments for Python 2 and Python 3. I used
conda create -n py2 python=2
and
conda create -n py3 python=3
to create two separate environments, py2
and py3
. Now I have a general use environment for each Python version. In each of those environments, I've installed most of the standard data science packages (numpy, scipy, pandas, etc.)
I’ve also found it useful to create environments for each project I’m working on. It works great for non-data related projects too like web apps with Flask. For example, I have an environment for my personal blog using Pelican.
Sharing environments
When sharing your code on GitHub, it's good practice to make an environment file and include it in the repository. This will make it easier for people to install all the dependencies for your code. I also usually include a pip requirements.txt
file using pip freeze
(learn more here) for people not using conda.
More to learn
To learn more about conda and how it fits in the Python ecosystem, check out this article by Jake Vanderplas: Conda myths and misconceptions. And here's the conda documentation you can reference later.


class ToolCardEffect
extends java.lang.Object
| Modifier and Type | Field and Description |
|---|---|
private GameController |
gameController |
private java.util.logging.Logger |
log |
| Constructor and Description |
|---|
ToolCardEffect(GameController gameController)
Class constructor that associate the class with the controller
|
| Modifier and Type | Method and Description |
|---|---|
(package private) void |
changeDiceValueEffect(int id,
int indexPool,
int number)
method responsible of the effect of changing the values of a dice depending on the tool card used by the player
|
(package private) void |
corkBackedStraightedgeEffect(int id,
int indexPool,
int indexPattern)
method responsible of the effect of put a dice in the card ignoring the constraint of the other dice
|
(package private) void |
fluxRemoverEffect(int id,
int indexPool,
int value,
Dice dice)
method responsible of the exchange of a dice between the draft pool and the dice bag
|
(package private) void |
glazingHammerEffect(int id)
method responsible of the effect of the shuffling all the dice in the draft pool at the moment of the cal
|
(package private) void |
grozingPliersEffect(int id,
int indexPool,
int increase)
effect implemented by the grozing pliers tool card, set a new value to the dice depending on the choose made by the
player in the match
|
(package private) void |
lathekinEffect(int id,
int indexStart1,
int indexEnd1,
int indexStart2,
int indexEnd2)
method responsible of the effect of a tool card to move two dice from a position to another in the pattern card
|
(package private) void |
lensCutterEffect(int id,
int indexPool,
int indexRound,
int indexPosition)
method responsible of the effect of an exchange of a dice between the dice and the Round Tracker
|
(package private) void |
moveOneDiceEffect(int id,
int indexStart,
int indexEnd,
int number)
method responsible of the effect of some tool cards that move a dice from an index of the pattern box list to
another one
|
(package private) void |
runningPliers(int id,
int indexPool,
int indexPattern)
method responsible of the effect to draft a die immediately after the first turn
|
(package private) void |
tapWheelEffect(int id,
int numberOfDice,
int indexStart1,
int indexEnd1,
int indexStart2,
int indexEnd2)
method responsible of the effect of moving up to two dice,depending on the chose of the player,
in the pattern box list that match the color of a dice in the round tracker
|
private final java.util.logging.Logger log
private GameController gameController
ToolCardEffect(GameController gameController)
gameController
- controller associated with the effectvoid grozingPliersEffect(int id, int indexPool, int increase) throws InvalidMoveException
id
- of tha playerindexPool
- index of the dice in the cardincrease
- increase or decrease decision by the playerInvalidMoveException
- if something goes wrongvoid moveOneDiceEffect(int id, int indexStart, int indexEnd, int number) throws InvalidMoveException
id
- of the playerindexStart
- index where to take the diceindexEnd
- index where to move itnumber
- of the tool card on which the effect is runningInvalidMoveException
- if something goes wrongvoid lathekinEffect(int id, int indexStart1, int indexEnd1, int indexStart2, int indexEnd2) throws InvalidMoveException
id
- of the playerindexStart1
- where to take the first diceindexEnd1
- where to move the first diceindexStart2
- where to take the second diceindexEnd2
- where to move the second diceInvalidMoveException
- if something goes wrongvoid lensCutterEffect(int id, int indexPool, int indexRound, int indexPosition)
id
- of the playerindexPool
- of the dice in draft poolindexRound
- of the current roundindexPosition
- of the dice in the current round listvoid glazingHammerEffect(int id) throws InvalidMoveException
id
- of the playerInvalidMoveException
- if something goes wrongvoid runningPliers(int id, int indexPool, int indexPattern) throws InvalidMoveException
id
- of the playerindexPool
- index of the dice in draft poolindexPattern
- index of pattern box list where to put the diceInvalidMoveException
- if something goes wrongvoid corkBackedStraightedgeEffect(int id, int indexPool, int indexPattern) throws InvalidMoveException
id
- of the playerindexPool
- index of the dice in the draft poolindexPattern
- index of the pattern box list where to put the diceInvalidMoveException
- if something goes wrongvoid changeDiceValueEffect(int id, int indexPool, int number)
id
- of the playerindexPool
- index of the dice in the draft poolnumber
- of the tool choosen by the playervoid fluxRemoverEffect(int id, int indexPool, int value, Dice dice)
id
- of the playerindexPool
- of the dice in the draft poolvalue
- to set to the dicedice
- to insert in the poolvoid tapWheelEffect(int id, int numberOfDice, int indexStart1, int indexEnd1, int indexStart2, int indexEnd2) throws InvalidMoveException
id
- of the playernumberOfDice
- to move upindexStart1
- index of the first dice to moveindexEnd1
- index where to move the first diceindexStart2
- index of the second dice to moveindexEnd2
- index where to move the second diceInvalidMoveException
- if something goes wrong


'nuff said
If you still think "All Lives Matter", there are more than enough resources ( here. here. here.) illustrating why it's incorrect.
What else can we do?


Poems on Various Subjects, Religious and Moral
by Phillis Wheatley
"On the Rev. Mr. George Whitefield. 1770."
Additional Information
- Year Published: 1773
- Language: English
- Country of Origin: United States of America
- Source: Wheatley, P. (1773). Poems on Various Subjects, Religious and Moral.London, England: A. Bell.
-
Readability:
- Flesch–Kincaid Level: 2.5
- Word Count: 407
- Genre: Poetry
- Keywords: 18th century literature, american authors, poetry
- ✎ Cite This
Downloads
HAIL, happy saint, on thine immortal throne,
Possest of glory, life, and bliss unknown;
We hear no more the music of thy tongue,
Thy wonted auditories cease to throng.
Thy sermons in unequall'd accents flow'd,
And ev'ry bosom with devotion glow'd;
Thou didst in strains of eloquence refin'd
Inflame the heart, and captivate the mind.
Unhappy we the setting sun deplore,
So glorious once, but ah! it shines no more.
Behold the prophet in his tow'ring flight!
He leaves the earth for heav'n's unmeasur'd height,
And worlds unknown receive him from our sight.
There Whitefield wings with rapid course his way,
And sails to Zion through vast seas of day.
Thy pray'rs, great saint, and thine incessant cries
Have pierc'd the bosom of thy native skies.
Thou moon hast seen, and all the stars of light,
How he has wrestled with his God by night.
He pray'd that grace in ev'ry heart might dwell,
He long'd to see America excell;
He charg'd its youth that ev'ry grace divine
Should with full lustre in their conduct shine;
That Saviour, which his soul did first receive,
The greatest gift that ev'n a God can give,
He freely offer'd to the num'rous throng,
That on his lips with list'ning pleasure hung.
"Take him, ye wretched, for your only good,
"Take him ye starving sinners, for your food;
"Ye thirsty, come to this life–giving stream,
"Ye preachers, take him for your joyful theme;
"Take him my dear Americans, he said,
"Be your complaints on his kind bosom laid:
"Take him, ye Africans, he longs for you,
"Impartial Saviour is his title due:
"Wash'd in the fountain of redeeming blood,
"You shall be sons, and kings, and priests to God."
Great Countess,* we Americans revere
Thy name, and mingle in thy grief sincere;
New England deeply feels, the Orphans mourn,
Their more than father will no more return.
But, though arrested by the hand of death,
Whitefield no more exerts his lab'ring breath,
Yet let us view him in th' eternal skies,
Let ev'ry heart to this bright vision rise;
While the tomb safe retains its sacred trust,
Till life divine re–animates his dust.
*The Countess of Huntingdon, to whom Mr. Whitefield was Chaplain.


87 children adopted into forever homes in Florida
by Sarah HollenbeckCLEARWATER, Fla. -- Almost 90 children in Pinellas and Hillsborough counties were adopted into forever families Friday. The big adoption events were part of national adoption month.
Foster care agencies hope the adoptions call attention to the need for more foster families, volunteers and people interested in adoption.
At age 68 and 75 years old, Jane and Darrel Eagle never imagined they'd be raising a 2-year-old, yet they were among the families adopting Friday.
“This is a special situation,” Jane Eagle explained. “He has disabilities and we just need each other.”
The Eagle family raised their four biological kids. Then, they became foster parents of 25 years after adopting four children with disabilities. Now, as most of their friends retire, they're welcoming 2-year-old Ryland to the family.
“You think you’re giving, but they give to you. They just make your life so full and so interesting,” Jane said with a smile.
They’ve earned their nickname: The forever parents.
“It’s not starting over, we just have continued parenting for our entire lives!”
Many more children are waiting for their turn to be adopted.
Across Florida, 800 children are still waiting for their forever families. In the United States, 120,000 children are without permanent families.
Adoption agencies are struggling to find them families before the children age out of foster care.
“We need people to come forward and be there for the kids in our child welfare system,” explained Mariela Ollsen, the Circuit Director of the Guadian Ad Litem program.
Ollsen hopes the Eagle family's story proves love doesn't discriminate.


|
Panda3D
|
Public Member Functions | |
| def | __init__ (self, parent=None, **kw) |
| def | addKeyframe (self, fToggleRecord=1) |
| def | addNodePath (self, nodePath) |
| def | addNodePathToDict (self, nodePath, names, menu, dict) |
| def | addWidget (self, widget, category, text) |
| WIDGET UTILITY FUNCTIONS ##. More... | |
| def | appInit (self) |
| USER METHODS ### To be overridden. More... | |
| def | computeCurves (self) |
| def | createAngleDial (self, parent, category, text, balloonHelp, command=None, **kw) |
| def | createButton (self, parent, category, text, balloonHelp, command, side='top', expand=0, fill=X) |
| def | createCheckbutton (self, parent, category, text, balloonHelp, command, initialState, side='top', fill=X, expand=0) |
| def | createColorEntry (self, parent, category, text, balloonHelp, command=None, **kw) |
| def | createComboBox (self, parent, category, text, balloonHelp, items, command, history=0, side=LEFT, expand=0, fill=X) |
| def | createEntryScale (self, parent, category, text, balloonHelp, command=None, min=0.0, max=1.0, resolution=None, side=TOP, fill=X, expand=1, **kw) |
| def | createFloater (self, parent, category, text, balloonHelp, command=None, min=0.0, resolution=None, maxVelocity=10.0, **kw) |
| def | createInterface (self) |
| def | createLabeledEntry (self, parent, category, text, balloonHelp, value='', command=None, relief='sunken', side=LEFT, expand=1, width=12) |
| def | createNewPointSet (self) |
| def | createOptionMenu (self, parent, category, text, balloonHelp, items, command) |
| def | createRadiobutton (self, parent, side, category, text, balloonHelp, variable, value, command=None, fill=X, expand=0) |
| def | createSlider (self, parent, category, text, balloonHelp, command=None, min=0.0, max=1.0, resolution=None, side=TOP, fill=X, expand=1, **kw) |
| def | createVector2Entry (self, parent, category, text, balloonHelp, command=None, **kw) |
| def | createVector3Entry (self, parent, category, text, balloonHelp, command=None, **kw) |
| def | cropCurve (self) |
| def | curveEditTask (self, state) |
| def | desampleCurve (self) |
| def | deselectedNodePathHook (self, nodePath) |
| def | disableKeyframeButton (self) |
| def | easeInOut (self, t) |
| def | enableKeyframeButton (self) |
| def | extractPointSetFromCurveCollection (self) |
| def | extractPointSetFromCurveFitter (self) |
| def | faceForward (self) |
| def | followTerrain (self, height=1.0) |
| def | getChildIds (self, nodePath) |
| def | getPostPoints (self) |
| def | getPrePoints (self, type='Refine') |
| def | getVariable (self, category, text) |
| def | getWidget (self, category, text) |
| def | initTrace (self) |
| def | jumpToEndOfPlayback (self) |
| def | jumpToStartOfPlayback (self) |
| def | loadCurveFromFile (self) |
| def | makeCameraWindow (self) |
| def | makeEven (self) |
| def | manipulateObjectCleanupHook (self, nodePathList=[]) |
| def | manipulateObjectStartHook (self) |
| def | mergePoints (self) |
| def | onDestroy (self, event) |
| def | playbackGoTo (self, time) |
| def | playbackTask (self, state) |
| def | pushRedo (self) |
| def | pushRedoHook (self) |
| def | pushUndo (self, fResetRedo=1) |
| def | pushUndoHook (self) |
| def | recordPoint (self, time) |
| def | recordTask (self, state) |
| def | redoHook (self, nodePathList=[]) |
| def | redoListEmptyHook (self) |
| def | reset (self) |
| def | sampleCurve (self, fCompute=1) |
| def | saveCurveToFile (self) |
| def | selectedNodePathHook (self, nodePath) |
| def | selectNodePathNamed (self, name) |
| def | selectPointSetNamed (self, name) |
| def | setControlStart (self, value) |
| def | setControlStop (self, value) |
| def | setCropFrom (self, value) |
| def | setCropTo (self, value) |
| def | setCvColor (self, color) |
| def | setCvVis (self) |
| def | setDesampleFrequency (self, frequency) |
| def | setExtendMode (self) |
| def | setHullColor (self, color) |
| def | setHullVis (self) |
| def | setKeyframeHook (self, event=None) |
| def | setKnotColor (self, color) |
| def | setKnotVis (self) |
| def | setLoopPlayback (self) |
| def | setMarkerVis (self) |
| def | setNewCurveMode (self) |
| def | setNodePath (self, nodePath) |
| def | setNumSamples (self, numSamples) |
| def | setNumSegs (self, value) |
| def | setNumTicks (self, value) |
| def | setPathColor (self, color) |
| def | setPathDuration (self, event) |
| def | setPathDurationTo (self, newMaxT) |
| def | setPathVis (self) |
| def | setPlaybackNodePath (self, nodePath) |
| def | setPlaybackSF (self, value) |
| def | setPreRecordFunc (self, func) |
| def | setRecordingType (self, type) |
| def | setRecordStart (self, value) |
| def | setRefineMode (self) |
| def | setRefineStop (self, value) |
| def | setSamplingMode (self, mode) |
| def | setSpeedScale (self, value) |
| def | setStartStopHook (self, event=None) |
| def | setTickColor (self, color) |
| def | setTickScale (self, value) |
| def | setTraceVis (self) |
| def | startPlayback (self) |
| def | startStopPlayback (self) |
| def | stopPlayback (self) |
| def | toggleRecord (self) |
| def | toggleRecordVar (self) |
| def | undoHook (self, nodePathList=[]) |
| def | undoListEmptyHook (self) |
| def | updateWidgets (self) |
| Public Member Functions inherited from AppShell | |
| def | addVariable (self, category, text, variable) |
| def | alignbuttons (self) |
| def | balloon (self) |
| def | bind (self, child, balloonHelpMsg, statusHelpMsg=None) |
| def | buttonAdd (self, buttonName, helpMessage=None, statusMessage=None, **kw) |
| def | buttonBox (self) |
| def | createMenuBar (self) |
| def | createWidget (self, parent, category, text, widgetClass, help, command, side, fill, expand, kw) |
| def | interior (self) |
| def | messageBar (self) |
| def | newCreateButton (self, parent, category, text, help='', command=None, side=LEFT, fill=X, expand=0, **kw) |
| def | newCreateCheckbutton (self, parent, category, text, help='', command=None, initialState=0, anchor=W, side=LEFT, fill=X, expand=0, **kw) |
| def | newCreateColorEntry (self, parent, category, text, help='', command=None, side=LEFT, fill=X, expand=0, **kw) |
| def | newCreateComboBox (self, parent, category, text, help='', command=None, items=[], state=DISABLED, history=0, labelpos=W, label_anchor=W, label_width=16, entry_width=16, side=LEFT, fill=X, expand=0, **kw) |
| def | newCreateDial (self, parent, category, text, help='', command=None, side=LEFT, fill=X, expand=0, **kw) |
| def | newCreateEntryScale (self, parent, category, text, help='', command=None, side=LEFT, fill=X, expand=0, **kw) |
| def | newCreateFloater (self, parent, category, text, help='', command=None, side=LEFT, fill=X, expand=0, **kw) |
| def | newCreateLabeledEntry (self, parent, category, text, help='', command=None, value='', width=12, relief=SUNKEN, side=LEFT, fill=X, expand=0) |
| def | newCreateOptionMenu (self, parent, category, text, help='', command=None, items=[], labelpos=W, label_anchor=W, label_width=16, menu_tearoff=1, side=LEFT, fill=X, expand=0, **kw) |
| def | newCreateRadiobutton (self, parent, category, text, variable, value, command=None, help='', anchor=W, side=LEFT, fill=X, expand=0, **kw) |
| def | newCreateSider (self, parent, category, text, help='', command=None, side=LEFT, fill=X, expand=0, **kw) |
| def | newCreateVector2Entry (self, parent, category, text, help='', command=None, side=LEFT, fill=X, expand=0, **kw) |
| def | newCreateVector3Entry (self, parent, category, text, help='', command=None, side=LEFT, fill=X, expand=0, **kw) |
| def | quit (self) |
| def | showAbout (self) |
| def | toggleBalloon (self) |
| def | transformRGB (self, rgb, max=1.0) |
| def | updateProgress (self, newValue=0, newMax=0) |
| Public Member Functions inherited from DirectObject | |
| def | __init__ (self) |
| def | accept (self, event, method, extraArgs=[]) |
| def | acceptOnce (self, event, method, extraArgs=[]) |
| def | addTask (self, *args, **kwargs) |
| def | detectLeaks (self) |
| def | doMethodLater (self, *args, **kwargs) |
| def | getAllAccepting (self) |
| def | ignore (self, event) |
| def | ignoreAll (self) |
| def | isAccepting (self, event) |
| def | isIgnoring (self, event) |
| def | removeAllTasks (self) |
| def | removeTask (self, taskOrName) |
Static Public Attributes | |
| string | appname = 'Mopath Recorder Panel' |
| int | count = 0 |
| int | frameHeight = 550 |
| int | frameWidth = 450 |
| int | usecommandarea = 0 |
| int | usestatusarea = 0 |
| Static Public Attributes inherited from AppShell | |
| string | appname = 'Generic Application Frame' |
| string | appversion = '1.0' |
| string | balloonState = 'none' |
| string | contactemail =<EMAIL_ADDRESS>|
| string | contactname = 'Mark R. Mine' |
| string | contactphone = '(818) 544-2921' |
| tuple | copyright |
| int | frameHeight = 320 |
| int | frameWidth = 450 |
| int | padx = 5 |
| int | pady = 5 |
| int | panelCount = 0 |
| int | usecommandarea = 0 |
| int | usestatusarea = 0 |
| Static Public Attributes inherited from DirectObject | |
| def | accept_once = acceptOnce |
| def | add_task = addTask |
| def | detect_leaks = detectLeaks |
| def | do_method_later = doMethodLater |
| def | get_all_accepting = getAllAccepting |
| def | ignore_all = ignoreAll |
| def | is_accepting = isAccepting |
| def | is_ignoring = isIgnoring |
| def | remove_all_tasks = removeAllTasks |
| def | remove_task = removeTask |
| def __init__ | ( | self, | |
parent = None , |
|||
| ** | kw | ||
| ) |
Reimplemented from AppShell.
| def addKeyframe | ( | self, | |
fToggleRecord = 1 |
|||
| ) |
| def addNodePath | ( | self, | |
| nodePath | |||
| ) |
| def addNodePathToDict | ( | self, | |
| nodePath, | |||
| names, | |||
| menu, | |||
| dict | |||
| ) |
| def addWidget | ( | self, | |
| widget, | |||
| category, | |||
| text | |||
| ) |
WIDGET UTILITY FUNCTIONS ##.
Reimplemented from AppShell.
| def appInit | ( | self | ) |
USER METHODS ### To be overridden.
Reimplemented from AppShell.
| def computeCurves | ( | self | ) |
| def createAngleDial | ( | self, | |
| parent, | |||
| category, | |||
| text, | |||
| balloonHelp, | |||
command = None , |
|||
| ** | kw | ||
| ) |
| def createButton | ( | self, | |
| parent, | |||
| category, | |||
| text, | |||
| balloonHelp, | |||
| command, | |||
side = 'top' , |
|||
expand = 0 , |
|||
fill = X |
|||
| ) |
| def createCheckbutton | ( | self, | |
| parent, | |||
| category, | |||
| text, | |||
| balloonHelp, | |||
| command, | |||
| initialState, | |||
side = 'top' , |
|||
fill = X , |
|||
expand = 0 |
|||
| ) |
| def createColorEntry | ( | self, | |
| parent, | |||
| category, | |||
| text, | |||
| balloonHelp, | |||
command = None , |
|||
| ** | kw | ||
| ) |
| def createComboBox | ( | self, | |
| parent, | |||
| category, | |||
| text, | |||
| balloonHelp, | |||
| items, | |||
| command, | |||
history = 0 , |
|||
side = LEFT , |
|||
expand = 0 , |
|||
fill = X |
|||
| ) |
| def createEntryScale | ( | self, | |
| parent, | |||
| category, | |||
| text, | |||
| balloonHelp, | |||
command = None , |
|||
min = 0.0 , |
|||
max = 1.0 , |
|||
resolution = None , |
|||
side = TOP , |
|||
fill = X , |
|||
expand = 1 , |
|||
| ** | kw | ||
| ) |
| def createFloater | ( | self, | |
| parent, | |||
| category, | |||
| text, | |||
| balloonHelp, | |||
command = None , |
|||
min = 0.0 , |
|||
resolution = None , |
|||
maxVelocity = 10.0 , |
|||
| ** | kw | ||
| ) |
| def createInterface | ( | self | ) |
Reimplemented from AppShell.
| def createLabeledEntry | ( | self, | |
| parent, | |||
| category, | |||
| text, | |||
| balloonHelp, | |||
value = '' , |
|||
command = None , |
|||
relief = 'sunken' , |
|||
side = LEFT , |
|||
expand = 1 , |
|||
width = 12 |
|||
| ) |
| def createNewPointSet | ( | self | ) |
| def createOptionMenu | ( | self, | |
| parent, | |||
| category, | |||
| text, | |||
| balloonHelp, | |||
| items, | |||
| command | |||
| ) |
| def createRadiobutton | ( | self, | |
| parent, | |||
| side, | |||
| category, | |||
| text, | |||
| balloonHelp, | |||
| variable, | |||
| value, | |||
command = None , |
|||
fill = X , |
|||
expand = 0 |
|||
| ) |
| def createSlider | ( | self, | |
| parent, | |||
| category, | |||
| text, | |||
| balloonHelp, | |||
command = None , |
|||
min = 0.0 , |
|||
max = 1.0 , |
|||
resolution = None , |
|||
side = TOP , |
|||
fill = X , |
|||
expand = 1 , |
|||
| ** | kw | ||
| ) |
| def createVector2Entry | ( | self, | |
| parent, | |||
| category, | |||
| text, | |||
| balloonHelp, | |||
command = None , |
|||
| ** | kw | ||
| ) |
| def createVector3Entry | ( | self, | |
| parent, | |||
| category, | |||
| text, | |||
| balloonHelp, | |||
command = None , |
|||
| ** | kw | ||
| ) |
| def cropCurve | ( | self | ) |
| def curveEditTask | ( | self, | |
| state | |||
| ) |
| def desampleCurve | ( | self | ) |
| def deselectedNodePathHook | ( | self, | |
| nodePath | |||
| ) |
Hook called upon deselection of a node path used to select playback marker if subnode selected
| def disableKeyframeButton | ( | self | ) |
| def easeInOut | ( | self, | |
| t | |||
| ) |
| def enableKeyframeButton | ( | self | ) |
| def extractPointSetFromCurveCollection | ( | self | ) |
| def extractPointSetFromCurveFitter | ( | self | ) |
| def faceForward | ( | self | ) |
| def followTerrain | ( | self, | |
height = 1.0 |
|||
| ) |
| def getChildIds | ( | self, | |
| nodePath | |||
| ) |
| def getPostPoints | ( | self | ) |
| def getPrePoints | ( | self, | |
type = 'Refine' |
|||
| ) |
| def getVariable | ( | self, | |
| category, | |||
| text | |||
| ) |
Reimplemented from AppShell.
| def getWidget | ( | self, | |
| category, | |||
| text | |||
| ) |
Reimplemented from AppShell.
| def initTrace | ( | self | ) |
| def jumpToEndOfPlayback | ( | self | ) |
| def jumpToStartOfPlayback | ( | self | ) |
| def loadCurveFromFile | ( | self | ) |
| def makeCameraWindow | ( | self | ) |
| def makeEven | ( | self | ) |
| def manipulateObjectCleanupHook | ( | self, | |
nodePathList = [] |
|||
| ) |
| def manipulateObjectStartHook | ( | self | ) |
| def mergePoints | ( | self | ) |
| def onDestroy | ( | self, | |
| event | |||
| ) |
Reimplemented from AppShell.
| def playbackGoTo | ( | self, | |
| time | |||
| ) |
| def playbackTask | ( | self, | |
| state | |||
| ) |
| def pushRedo | ( | self | ) |
| def pushRedoHook | ( | self | ) |
| def pushUndo | ( | self, | |
fResetRedo = 1 |
|||
| ) |
| def pushUndoHook | ( | self | ) |
| def recordPoint | ( | self, | |
| time | |||
| ) |
| def recordTask | ( | self, | |
| state | |||
| ) |
| def redoHook | ( | self, | |
nodePathList = [] |
|||
| ) |
| def redoListEmptyHook | ( | self | ) |
| def reset | ( | self | ) |
| def sampleCurve | ( | self, | |
fCompute = 1 |
|||
| ) |
| def saveCurveToFile | ( | self | ) |
| def selectedNodePathHook | ( | self, | |
| nodePath | |||
| ) |
Hook called upon selection of a node path used to select playback marker if subnode selected
| def selectNodePathNamed | ( | self, | |
| name | |||
| ) |
| def selectPointSetNamed | ( | self, | |
| name | |||
| ) |
| def setControlStart | ( | self, | |
| value | |||
| ) |
| def setControlStop | ( | self, | |
| value | |||
| ) |
| def setCropFrom | ( | self, | |
| value | |||
| ) |
| def setCropTo | ( | self, | |
| value | |||
| ) |
| def setCvColor | ( | self, | |
| color | |||
| ) |
| def setCvVis | ( | self | ) |
| def setDesampleFrequency | ( | self, | |
| frequency | |||
| ) |
| def setExtendMode | ( | self | ) |
| def setHullColor | ( | self, | |
| color | |||
| ) |
| def setHullVis | ( | self | ) |
| def setKeyframeHook | ( | self, | |
event = None |
|||
| ) |
| def setKnotColor | ( | self, | |
| color | |||
| ) |
| def setKnotVis | ( | self | ) |
| def setLoopPlayback | ( | self | ) |
| def setMarkerVis | ( | self | ) |
| def setNewCurveMode | ( | self | ) |
| def setNodePath | ( | self, | |
| nodePath | |||
| ) |
| def setNumSamples | ( | self, | |
| numSamples | |||
| ) |
| def setNumSegs | ( | self, | |
| value | |||
| ) |
| def setNumTicks | ( | self, | |
| value | |||
| ) |
| def setPathColor | ( | self, | |
| color | |||
| ) |
| def setPathDuration | ( | self, | |
| event | |||
| ) |
| def setPathDurationTo | ( | self, | |
| newMaxT | |||
| ) |
| def setPathVis | ( | self | ) |
| def setPlaybackNodePath | ( | self, | |
| nodePath | |||
| ) |
| def setPlaybackSF | ( | self, | |
| value | |||
| ) |
| def setPreRecordFunc | ( | self, | |
| func | |||
| ) |
| def setRecordingType | ( | self, | |
| type | |||
| ) |
| def setRecordStart | ( | self, | |
| value | |||
| ) |
| def setRefineMode | ( | self | ) |
| def setRefineStop | ( | self, | |
| value | |||
| ) |
| def setSamplingMode | ( | self, | |
| mode | |||
| ) |
| def setSpeedScale | ( | self, | |
| value | |||
| ) |
| def setStartStopHook | ( | self, | |
event = None |
|||
| ) |
| def setTickColor | ( | self, | |
| color | |||
| ) |
| def setTickScale | ( | self, | |
| value | |||
| ) |
| def setTraceVis | ( | self | ) |
| def startPlayback | ( | self | ) |
| def startStopPlayback | ( | self | ) |
| def stopPlayback | ( | self | ) |
| def toggleRecord | ( | self | ) |
| def toggleRecordVar | ( | self | ) |
| def undoHook | ( | self, | |
nodePathList = [] |
|||
| ) |
| def undoListEmptyHook | ( | self | ) |
| def updateWidgets | ( | self | ) |
| actionEvents |
|
static |
| cCam |
| cCamera |
| cCamNode |
| cDr |
| cLayer |
| cLens |
| controlStart |
| controlStop |
|
static |
| cropFrom |
| cropPage |
| cropTo |
| curveCollection |
| curveFitter |
| curveNodePath |
| deltaTime |
| desampleFrequency |
| drawPage |
| extendPage |
| fAdjustingValues |
|
static |
|
static |
| hasPoints |
| iRay |
| iRayCS |
| keyframeHook |
| lastPos |
| layerIndex |
| loopPlayback |
| mainNotebook |
| manipulandumId |
| maxT |
| name |
| nodePath |
| nodePathDict |
| nodePathMenu |
| nodePathMenuBG |
| nodePathMenuEntry |
| nodePathNames |
| nodePathParent |
| numSamples |
| numSegs |
| numTicks |
| nurbsCurveDrawer |
| oldPlaybackNodePath |
| optionsPage |
| playbackMarker |
| playbackMarkerIds |
| playbackNodePath |
| playbackSF |
| playbackTime |
| pointSet |
| pointSetCount |
| pointSetDict |
| pointSetName |
| postPoints |
| prePoints |
| preRecordFunc |
OPTIONS PAGE ##.
| recorderNodePath |
| recordingType |
| recordStart |
| recordStop |
| redoButton |
| refinePage |
| resamplePage |
| samplingMode |
| sf |
RESAMPLE PAGE.
REFINE PAGE ## EXTEND PAGE ## CROP PAGE ## DRAW PAGE ##
| speedEntry |
| speedScale |
| speedVar |
| startStopHook |
| tangentGroup |
| tangentLines |
| tangentMarker |
| tangentMarkerIds |
| tempCS |
| trace |
| undoButton |
|
static |
|
static |
| variableDict |
| widgetDict |


Support enumeration - solutions¶
Define the support of a strategy.
Bookwork: https://vknight.org/gt/chapters/05/#Definition-of-support
Obtain the supports for the following strategy vectors:
- $\sigma = (1, 0, 0, 0)$: $S(\sigma)=\{1\}$
- $\sigma = (.5, 0, .5, 0)$: $S(\sigma)=\{1, 3\}$
- $\sigma = (.25, .25, .25, .25)$: $S(\sigma)=\{1, 2, 3, 4\}$
Define a degenerate game.
Bookwork: https://vknight.org/gt/chapters/05/#Definition-of-nondegenerate-games
Construct a degenerate $3\times 3$ game.
Many possible solutions. Here is one:
$$ A = \begin{pmatrix} 1 & 2 & 3\\ 1 & 3 & 2\\ 0 & 1 & 4 \end{pmatrix} \qquad B = \begin{pmatrix} -1 & -2 & -3\\ -1 & -3 & -2\\ 0 & -1 & -4 \end{pmatrix} $$
Consider $\sigma_c = (1, 0, 0)$, we have $A\sigma_c^T=\begin{pmatrix}1 & 1 & 0\end{pmatrix}$. Thus, there are two best responses to $\sigma_c$ however $|S(\sigma_c)|=2$.
Describe the support enumeration algorithm.
Bookwork: https://vknight.org/gt/chapters/05/#Support-enumeration-algorithm
Use support enumeration to find Nash equilibria for the following games:
$ A = \begin{pmatrix} 3 & 3 & 2 \\ 2 & 1 & 3 \end{pmatrix} \qquad B = \begin{pmatrix} 2 & 1 & 3 \\ 2 & 3 & 2 \end{pmatrix} $
We need to consider three possible supports for the column player: $J\in\{(1, 2), (1, 2), (2, 3)\}$:
$I=(1, 2)$ and $J=(1, 2)$, the indifference condition gives:
$$ 2{\sigma_{r}}_1+2{\sigma_{r}}_2={\sigma_{r}}_1+3{\sigma_{r}}_2 $$
$$ {\sigma_{r}}_1={\sigma_{r}}_2 $$
$$ 3{\sigma_{c}}_1+3{\sigma_{c}}_2=2{\sigma_{c}}_1+{\sigma_{c}}_2 $$
$$ {\sigma_{c}}_1=-2{\sigma_{c}}_2 $$
which would not give a valid probability vector.
$I=(1, 2)$ and $J=(1, 3)$, the indifference condition gives:
$$ 2{\sigma_{r}}_1+2{\sigma_{r}}_2=3{\sigma_{r}}_1+2{\sigma_{r}}_2 $$
$$ -{\sigma_{r}}_1=0 $$
which is not valid for this support. (No need to check the condition on $\sigma_c$).
$I=(1, 2)$ and $J=(2, 3)$, the indifference condition gives:
$$ {\sigma_{r}}_1+3{\sigma_{r}}_2=3{\sigma_{r}}_1+2{\sigma_{r}}_2 $$
$$ {\sigma_{r}}_2=2{\sigma_{r}}_1 $$
$$ 3{\sigma_{c}}_2+2{\sigma_{c}}_3={\sigma_{c}}_2+3{\sigma_{c}}_3 $$
$$ 2{\sigma_{c}}_2={\sigma_{c}}_3 $$
Normalising both these solutions gives:
$$\sigma_r=(1/3, 2/3)\qquad\sigma_c=(0, 1/3, 2/3)$$
We confirm these two vectors are best responses to each other:
$$A\sigma_c^T=\begin{pmatrix}7/3\\7/3\end{pmatrix}$$
thus $\sigma_r$ is a best response to $\sigma_c$.
$$\sigma_rB=\begin{pmatrix}2&7/3&7/3\end{pmatrix}$$
thus $\sigma_c$ is a best response to $\sigma_r$.
Thus the unique Nash equilibrium for this game is:
$$((1/3, 2/3), (0, 1/3, 2/3))$$
$ A = \begin{pmatrix} 3 & -1\\ 2 & 7\end{pmatrix} \qquad B = \begin{pmatrix} -3 & 1\\ 1 & -6\end{pmatrix} $
There is a single pair of supports to investigate here giving the pair of equations:
$$ -3{\sigma_{r}}_1+{\sigma_{r}}_2={\sigma_{r}}_1-6{\sigma_{r}}_2 $$
$$ {\sigma_{r}}_2=4/7{\sigma_{r}}_1 $$
$$ 3{\sigma_{c}}_1-{\sigma_{c}}_2=2{\sigma_{c}}_1+7{\sigma_{c}}_2 $$
$$ {\sigma_{c}}_1=8{\sigma_{c}}_2 $$
Normalising these gives: ${\sigma_{r}}_1(4/7 + 1) = 1\Rightarrow {\sigma_{r}}_1=7/11$ and ${\sigma_{c}}_1(1/8 + 1) = 1\Rightarrow {\sigma_{c}}_1=8/9$. Giving the unique nash equilibrium (there is no need to check the best response, as there are no other strategies outside of these supports):
$$((7/11, 4/11), (8/9, 1/9))$$


| Place | Code | Country | Admin1 | Admin2 | Admin3 |
| 1 | Calgary (City Centre / Calgary Tower) | T2P | Canada | Alberta | Calgary | |
| 51.071/-113.693 |
| 2 | Calgary (Cranston) | T3M | Canada | Alberta | Calgary | |
| 50.88/-113.955 |
| 3 | Calgary Northeast | T3N | Canada | Alberta | Calgary | |
| 51.163/-113.954 |
| 4 | Calgary Northwest | T3R | Canada | Alberta | Calgary | |
| 51.202/-114.245 |
| 5 | Calgary (Rundle / Whitehorn / Monterey Park) | T1Y | Canada | Alberta | Calgary | |
| 51.082/-113.958 |
| 6 | Calgary (Bridgeland / Greenview / Zoo / YYC) | T2E | Canada | Alberta | Calgary | |
| 51.088/-114.021 |
| 7 | Calgary (Highfield / Burns Industrial) | T2H | Canada | Alberta | Calgary | |
| 50.989/-114.052 |
| 8 | Calgary (Thornecliffe / Tuxedo) | T2K | Canada | Alberta | Calgary | |
| 51.111/-114.048 |
| 9 | Calgary (Brentwood / Collingwood / Nose Hill) | T2L | Canada | Alberta | Calgary | |
| 51.105/-114.115 |
| 10 | Calgary (Kensington / Westmont / Parkdale / University) | T2N | Canada | Alberta | Calgary | |
| 51.062/-114.116 |
| 11 | Calgary (Connaught / West Victoria Park) | T2R | Canada | Alberta | Calgary | |
| 51.041/-114.076 |
| 12 | Calgary South (Altadore / Bankview / Richmond) | T2T | Canada | Alberta | Calgary | |
| 51.024/-114.1 |
| 13 | Calgary (Braeside / Woodbine) | T2W | Canada | Alberta | Calgary | |
| 50.951/-114.359 |
| 14 | Calgary (Midnapore / Sundance) | T2X | Canada | Alberta | Calgary | |
| 50.884/-114.033 |
| 15 | Calgary (Millrise / Somerset / Bridlewood / Evergreen) | T2Y | Canada | Alberta | Calgary | |
| 50.909/-114.103 |
| 16 | Calgary (Rosscarrock / Wildwood / Shaganappi / Sunalta) | T3C | Canada | Alberta | Calgary | |
| 51.05/-114.139 |
| 17 | Calgary (Lakeview / Glendale / Killarney / Glamorgan) | T3E | Canada | Alberta | Calgary | |
| 50.99/-114.157 |
| 18 | Calgary (Tuscany / Scenic Acres) | T3L | Canada | Alberta | Calgary | |
| 51.147/-114.313 |
| 19 | Calgary (Symons Valley) | T3P | Canada | Alberta | Calgary | |
| 51.207/-114.135 |
| 20 | Calgary (Mount Pleasant / Capitol Hill / Banff Trail) | T2M | Canada | Alberta | Calgary | |
| 51.133/-113.856 |
| 21 | Calgary (Elbow Park / Britannia / Parkhill / Mission) | T2S | Canada | Alberta | Calgary | |
| 51.023/-114.071 |
| 22 | Calgary (Oak Ridge / Haysboro / Kingsland / Windsor Park) | T2V | Canada | Alberta | Calgary | |
| 50.982/-114.1 |
| 23 | Calgary (Martindale / Taradale / Falconridge / Saddle Ridge) | T3J | Canada | Alberta | Calgary | |
| 51.119/-113.947 |
| 24 | Calgary (Lynnwood Ridge / Ogden / Foothills Industrial / Great Plains) | T2C | Canada | Alberta | Calgary | |
| 50.987/-113.963 |
| 25 | Calgary (Inglewood / Burnsland / Chinatown / East Victoria Park / Saddledome) | T2G | Canada | Alberta | Calgary | |
| 51.027/-114.035 |
| 26 | Calgary (Douglas Glen / McKenzie Lake / Copperfield / East Shepard) | T2Z | Canada | Alberta | Calgary | |
| 50.928/-113.968 |
| 27 | Calgary (Hawkwood / Arbour Lake / Royal Oak / Rocky Ridge) | T3G | Canada | Alberta | Calgary | |
| 51.139/-114.201 |
| 28 | Calgary (Discovery Ridge / Signal Hill / Aspen Woods / Patterson / Cougar Ridge) | T3H | Canada | Alberta | Calgary | |
| 51.042/-114.2 |
| 29 | Calgary (Sandstone / Harvest Hills / Coventry Hills / Panorama Hills / Beddington) | T3K | Canada | Alberta | Calgary | |
| 51.156/-114.057 |
| 30 | Calgary | T3S | Canada | Alberta | Calgary | |
| 50.915/-113.893 |
| 31 | Calgary (Queensland Downs / Lake Bonavista / Willow Park / Acadia) | T2J | Canada | Alberta | Calgary | |
| 50.848/-114.196 |
| 32 | Calgary (Penbrooke Meadows / Marlborough) | T2A | Canada | Alberta | Calgary | |
| 51.049/-113.956 |
| 33 | Calgary (Forest Lawn / Dover / Erin Woods) | T2B | Canada | Alberta | Calgary | |
| 51.021/-113.981 |
| 34 | Calgary (Dalhousie / Edgemont / Hamptons / Hidden Valley) | T3A | Canada | Alberta | Calgary | |
| 51.126/-114.142 |
| 35 | Calgary (Montgomery / Bowness / Silver Springs / Greenwood) | T3B | Canada | Alberta | Calgary | |
| 51.091/-114.207 |


Thank you for filling your tax with the IRS. Follow us on Twitter for the latest updates.
Success!
You will now be redirected to our partner at INTUIT to complete your filling.
Your tax data will now be transmitted to our partner (INTUIT) WITHOUT any encryption to save electricity.


fun getOutputStream(msgCtrl: MsgCtrl? = null): OutputStream
Returns an output stream for this socket.
See Also: srt_sendmsg2
msgCtrl - the MsgCtrl that contains extra parameter
msgCtrl
Return an output stream for writing bytes to this socket.
See Also
getInputStream


Creates nomogram visualizations for penalized Cox regression models, with the support of reproducible survival model building, validation, calibration, and comparison for high-dimensional data.
| Version: | 5.0 |
| Depends: | R (≥ 3.0.2) |
| Imports: | survival, glmnet, penalized, ncvreg (≥ 3.8-0), rms, foreach, survAUC, ggplot2 (≥ 2.2.1), gridExtra |
| Suggests: | knitr, rmarkdown, doParallel, Hmisc, mice |
| Published: | 2018-05-14 |
| Author: | Nan Xiao [aut, cre], Qing-Song Xu [aut], Miao-Zhu Li [aut] |
| Maintainer: | Nan Xiao <me at nanx.me> |
| BugReports: | https://github.com/road2stat/hdnom/issues |
| License: | GPL-3 | file LICENSE |
| URL: | https://nanx.me/hdnom/, https://github.com/road2stat/hdnom, http://hdnom.io |
| NeedsCompilation: | no |
| Citation: | hdnom citation info |
| Materials: | README NEWS |
| In views: | Survival |
| CRAN checks: | hdnom results |
| Reference manual: | hdnom.pdf |
| Vignettes: |
An Introduction to hdnom |
| Package source: | hdnom_5.0.tar.gz |
| Windows binaries: | r-devel: hdnom_5.0.zip, r-release: hdnom_5.0.zip, r-oldrel: hdnom_5.0.zip |
| OS X binaries: | r-release: hdnom_5.0.tgz, r-oldrel: hdnom_5.0.tgz |
| Old sources: | hdnom archive |
Please use the canonical form https://CRAN.R-project.org/package=hdnom to link to this page.


A channel to talk about topics that don't fit into any other channel. You can also share interesting links here.
100 messages
Before 05-Dec-19 12:00 AM
nocturnal12-May-19 08:30 AM
and who is doing the ordering
designer12-May-19 08:31 AM
How did a free individual human create a repressive State?
jl777c12-May-19 08:31 AM
generally speaking, the more people concentrated leads to centralized state
and arbitrary rules deemed necessary to maintain the centralized control
go to places with fewer people
nocturnal12-May-19 08:32 AM
yes i agree, i think the balance between de/centralized is the key
jl777c12-May-19 08:32 AM
less controls (generally speaking)
nocturnal12-May-19 08:32 AM
and which arena have central organisation and which dont is important
for example finance and power should be on the decentralised spectrum. but things like health care and infrastructure creation need co-ordination to be efficient
jl777c12-May-19 08:34 AM
not sure why health care needs to be centralized
roads yes
nocturnal12-May-19 08:34 AM
maybe not health care but you know what i mean
but health care is good have unoform level of care across society
*uniform
and standards
across society
was my thinking
same as education
anyways.. a simple way to stop people physically stealing your crypto I think will be major thing in the future. get working on it haha
laters
designer12-May-19 08:55 AM
human hates complexity. human likes simplicity.
human don't like to think. human like to just follow.
human is selfish and greedy.
nocturnal12-May-19 08:58 AM
this is all true. the opposite is also all true
designer12-May-19 09:15 AM
Since the public is the epitome of irresponsibility, fools who believe in democracy as learned in school should be careful and be careful.
Representative Brad Sherman: “I look for colleagues to join with me in introducing a bill to… uh… outlaw cryptocurrency… uh… uh… owner… uh… purchases by Americans so that we nip this in the bud”
Bitcoin: https://t.co/hGQI8vBita
Retweets
187
Likes
664
klein12-May-19 01:24 PM
its probably the same person or group of people conrolling the three accounts
Is it not possible they bought those pictures somewhere with green screen?
and aded background
lol
Cryptoon12-May-19 01:37 PM
Wasnt that the den novak guy supposedly(edited)
klein12-May-19 01:42 PM
guy must be pretty butt hurt now
All that time and effort spent all lost
Cryptoon12-May-19 01:44 PM
Yawn
Wouldnt be the first one
1
KomodoWorld12-May-19 05:28 PM
the photos have something... they seem crated on a green screen
jl777c12-May-19 05:40 PM
if green screen, only one of them would need to know the purpose
1
KomodoWorld12-May-19 05:41 PM
the give away is that presentations so elaborate like sci-fi don't exist in reality
he/she overdid it
polycryptoblog12-May-19 05:46 PM
@KomodoWorld real presentations are done with a webcam and a brown sheet
In his own interpretation of Elton John’s iconic hit, Iranian filmmaker and refugee Majid Adin reimagines “Rocket Man” to tell a new story of adventure, lone...
2.5 hours left to go and its neck and neck. Please vote for infotech-al for Komodo Notary node operator. VOTING DETAILS: NORTH AMERICA ADDRESS: RJZWxYnAuu6j6qUtqVJfBUPaMy2qyExBds @MrKomodoWorld @KomodoGermany @komodoregames @KomodoPioneers @KMD_Platform_ES @satindergrewal
nocturnal13-May-19 09:57 PM
hey could anyone enlighten me on cold storage? a trezor thingumy, isnt it basically just a very expensive usb stick?(edited)
haha ok ty
jl777c13-May-19 10:02 PM
in addition to usb data storage, it should be able to sign a rawtransaction, so i think it is like a lite client + usb, a very small application specific computer
1
nocturnal13-May-19 10:06 PM
i guess what i mean is is it any better to have a ledger than just to back up all keys etc on a usb stick?
+wallet dats etc
jl777c13-May-19 10:08 PM
if you use windows, then likely anything is better, especially hardware wallet
nocturnal13-May-19 10:09 PM
because its encrypted?
jl777c13-May-19 10:09 PM
because it doesnt run windows inside
likely some variant of unix
1
1
nocturnal13-May-19 10:09 PM
do you think I should move my main wallets to my mac?
lol i love that
like new-school pirate treasure(edited)
2
in 1000 years people will be turning up old bitcoin keys in archeological digs
Provided to YouTube by Believe SAS Money Is the Name of the Game · Buster Benton Blues & Trouble (Blues Reference 1983-1985) Disques Black & Blue Released ...
This is Paddington. He lay down at the park and another pup came over and fell asleep on his tail. Please don’t excite him for he’s trying his best not to wag. Both 14/10


Beast Herder Tunatun:
You've brought the Divine Stone of Wisdom, right?
All right. Now, I'll give you the Stone of Commune.
Actually, I'm hoping to get two stones of sacred wisdom! One from the Varka Silenos and one from the Ketra Orcs... If I had two stones, I could meet with the chiefs of both tribes!
If I could just get them talking, I think we could establish a peace that would let us share our common land to our mutual benefit!
Ah, yes! You wanted the Stone of Commune, right?
"Yes, please."


irclog.gr
Online IRC logs for open source projects
irclog.gr
talking to your friendly server...
(
)
^^^
older
^^^
vvv
older
vvv


The "Printing Area" is the area of the Clothe
where your design can be printed.
It is a fixed area
The "Design Area" Area is the
maximum size of your design.
- It can be scaled, rotated and moved.
- Inside the "Printing Area"


World Diabetes Day: Tips on self-care for diabetics
by Betty AmamukiroriAccording to WHO by 2014, 422 million people were living with diabetes, this is projected to rise to 600 million by 2025.
HEALTH
Diabetes affects both children and adults. Over the years, there has been an increase in the number of people diagnosed with the disease.
The World Health Organisation defines diabetes as a chronic disease that occurs either when the pancreas does not produce enough insulin or when the body cannot effectively use the insulin it produces.
Insulin is a hormone that regulates blood sugar. Hyperglycaemia, or raised blood sugar, is a common effect of uncontrolled diabetes and over time leads to serious damage to many of the body's systems, especially the nerves and blood vessels.
According to WHO by 2014, 422 million people were living with diabetes, this is projected to rise to 600 million by 2025. The global prevalence of diabetes among adults over 18 years of age has risen by 2014 was at 8.5%.
The prevalence is reported to be rising more rapidly in middle- and low-income countries. In 2016, an estimated 1.6 million deaths were directly caused by diabetes.
Dr. William Lumu, the President of Uganda Diabetes Association, says that in Uganda, the prevalence is between 0.4% and 9%.
He said though there are about 400,000 Ugandans living with diabetes, only 100,000 are aware of their status.
The youngest person so far to be diagnosed with diabetes was three months old at the time of diagnosis.
He noted that diabetes is the leading cause of blindness, heart disease, kidney failure, stroke and lower limb amputation in Uganda.
However, he noted that even with these grave conditions, only about 65% of people living with the disease get information on diabetes, only 30% have glucometers for testing blood sugar levels, only 11.5% have had their eyes checked, only 2.2% do feet checks, only 4.8% do dental checks and only 32% have their kidneys checked.
He also noted that with physical activity, a healthy diet, adhering to medication and maintaining a normal body, one can be able to lead a longer healthier life.
How diabetics should care of themselves
Dr.Thereza Piloya-Were, a senior lecturer and paediatric endocrinologist at the department of paediatrics and child health, Makerere University said the first step to managing diabetes is testing for the sugar levels in the body to ensure that the sugar is balanced.
“That (the test) tells you whether to adjust your sugar or not using the tablets or insulin. Unfortunately in our setting, very few people are testing at home because they can’t afford testing kits,” she said.
She revealed that testing at home costs a minimum of sh50, 000 for adults in two months while for children, it’s about sh50, 000 in one month because they test more because of the insulin injections they are subjected to daily.
Treatment
The second care regimen is adhering to treatment. Piloya stated that people on insulin need to take it as regularly as recommended to facilitate digestion.
 So they need the drugs to push the blood into the cells for body function,” she said.
She noted that when the food fails to enter the bloodstream, the blood system gets clogged and a diabetic will find themselves urinating frequently.
Diet
Diet is also very crucial for people with diabetes. The diet should be balanced with lots of vegetables and fruits.
“The only thing we should be avoiding is the portion. Eat a lot of vegetables and fruits. For a person with diabetes, almost half the plate should be vegetables. In a day one should take three to five servings of vegetables and fruits,” she said.
She, however, warned that foods like posho and rice should be taken in moderation because they tend to raise the blood sugar. Salt intake should also be reduced because it is linked to high blood pressure.
Exercise
Exercise, Piloya says is most important for people with type 2 diabetes, also known as diabetes mellitus. She said exercise alone can improve one’s blood sugar.
“When you start exercising the muscles become too sensitive to insulin and once you eat, the food easily gets into the cells. So exercise is so crucial to us in reducing the amount of drugs we need to take,” she said.
Eye check
Diabetes is a leading cause of blindness. Adults with diabetes tend to suffer from retinal changes that affect the small vessels of the retina and can lead to blindness.
The condition known as retinography occurs when blood sugar levels are high for an extended period of time. This damages the capillaries that supply blood to the retina.
To monitor eye health, Piloya said diabetics need to annual check their eyes to make sure that any vision issues are detected early.
Feet care
With increasing years with diabetes, one’s nerves gradually stop working and become insensitive to pain.
Piloya said a diabetic can reach a stage whereby they can knock their feet, or burn themselves but fail to feel the pain. At this stage, the wounds caused by such injuries may fail to heal and instead worsen, leading to limb amputation.
To avoid injury, she said that people with diabetes should not put on open shoes and sandles, and instead opt for closed, well-fitting and soft shoes.
Teeth care
People with diabetes have a lot of sugar in their bloodstream, and because of this, germs tend to come and chew on the sugar especially in areas around the teeth.
Piloya warned that if diabetics do not care for their teeth, they may end up with infects leading to loss of teeth and threatening their lives.
Kidneys
Diabetes hits the kidney like any other organ in the body. Regular checks through urinalysis for traces of proteins in the urine will help in early detection of renal failure.
“Don’t wait for your body to start swelling, test regularly for early intervention,” Piloya warned.
Heart check
The disease tends to have a grave effect on the heart. When the heart is affected, Piloya said one can become impotent. Therefore, one needs to check their heart regularly.
Education
Education, though often ignored, is very important to a diabetic. They need to know how to manage the disease. Since the biggest part of care is self-care.
“Every patient needs an enormous amount of information in regards to diabetes. It’s the cornerstone in management. If we do not give them the right information, however many drugs we give them, however many insulin injections you are giving, you are wasting your time,” said Piloya.
Diabetes can hit every part of the body so self-care is so crucial.
Related story
Diabetes patients warned against abandoning medication


Toggle navigation
Map
{{ username }}
Profile
Members Portal
Report an Issue
Logout
×
Loading...
Nathaniel Rochester Hall
Helen Fish Hall
Bathrooms
Stairs/Elevators
Special Rooms
{% if config['PLUG_SUPPORT'] %}
{% endif %}


107
Let the Redeemed of the LORD Say So
1 Oh give thanks to the LORD, for he is good,
for his steadfast love endures forever!
2 Let the redeemed of the LORD say so,
whom he has redeemed from trouble
3 and gathered in from the lands,
from the east and from the west,
from the north and from the south.
4 Some wandered in desert wastes,
finding no way to a city to dwell in;
5 hungry and thirsty,
their soul fainted within them.
6 Then they cried to the LORD in their trouble,
and he delivered them from their distress.
7 He led them by a straight way
till they reached a city to dwell in.
8 Let them thank the LORD for his steadfast love,
for his wondrous works to the children of men!
9 For he satisfies the longing soul,
and the hungry soul he fills with good things.
10 Some sat in darkness and in the shadow of death,
prisoners in affliction and in irons,
11 for they had rebelled against the words of God,
and spurned the counsel of the Most High.
12 So he bowed their hearts down with hard labor;
they fell down, with none to help.
13 Then they cried to the LORD in their trouble,
and he delivered them from their distress.
14 He brought them out of darkness and the shadow of death,
and burst their bonds apart.
15 Let them thank the LORD for his steadfast love,
for his wondrous works to the children of men!
16 For he shatters the doors of bronze
and cuts in two the bars of iron.
17 Some were fools through their sinful ways,
and because of their iniquities suffered affliction;
18 they loathed any kind of food,
and they drew near to the gates of death.
19 Then they cried to the LORD in their trouble,
and he delivered them from their distress.
20 He sent out his word and healed them,
and delivered them from their destruction.
21 Let them thank the LORD for his steadfast love,
for his wondrous works to the children of men!
22 And let them offer sacrifices of thanksgiving,
and tell of his deeds in songs of joy!
23 Some went down to the sea in ships,
doing business on the great waters;
24 they saw the deeds of the LORD,
his wondrous works in the deep.
25 For he commanded and raised the stormy wind,
which lifted up the waves of the sea.
26 They mounted up to heaven; they went down to the depths;
their courage melted away in their evil plight;
27 they reeled and staggered like drunken men
and were at their wits' end.
28 Then they cried to the LORD in their trouble,
and he delivered them from their distress.
29 He made the storm be still,
and the waves of the sea were hushed.
30 Then they were glad that the waters were quiet,
and he brought them to their desired haven.
31 Let them thank the LORD for his steadfast love,
for his wondrous works to the children of men!
32 Let them extol him in the congregation of the people,
and praise him in the assembly of the elders.
33 He turns rivers into a desert,
springs of water into thirsty ground,
34 a fruitful land into a salty waste,
because of the evil of its inhabitants.
35 He turns a desert into pools of water,
a parched land into springs of water.
36 And there he lets the hungry dwell,
and they establish a city to live in;
37 they sow fields and plant vineyards
and get a fruitful yield.
38 By his blessing they multiply greatly,
and he does not let their livestock diminish.
39 When they are diminished and brought low
through oppression, evil, and sorrow,
40 he pours contempt on princes
and makes them wander in trackless wastes;
41 but he raises up the needy out of affliction
and makes their families like flocks.
42 The upright see it and are glad,
and all wickedness shuts its mouth.
43 Whoever is wise, let him attend to these things;
let them consider the steadfast love of the LORD.


Select Server Repository to Upload Converted Configuration File(s):
This is optional. Note:
1. If your input config is an ASR9K admin config with filename "admin.cfg", two
converted configuration files will be uploaded to the selected repository:
a) "admin.cal" will be the ASR9K-X64 Calvados/admin config.
b) "admin.iox" will be the ASR9K-X64 IOS-XR config.
2. Same goes for an ASR9K IOS-XR config, except that the ".cal" file in this case
should contain no valid configuration and will not be used.
{{ edit_field(config_form.select_server, label_field_width="col-sm-4", field_width="col-sm-5", class="form-control") }}
{% macro extra_field_for_directory() %}
{% endmacro %}
{{ edit_field(config_form.select_server_directory, label_field_width="col-sm-4", field_width="col-sm-5", class="form-control", extra_field=extra_field_for_directory()) }}


System Architect Diagram ".Agency States"
Sorry, this document will only work on browsers capable of displaying frames (e.g. Netscape Navigator and Internet Explorer).


public static interface CompositeMap.MapMutator
| Modifier and Type | Method and Description |
|---|---|
Object |
put(CompositeMap map,
Map[] composited,
Object key,
Object value)
Called when the CompositeMap.put() method is invoked.
|
void |
putAll(CompositeMap map,
Map[] composited,
Map mapToAdd)
Called when the CompositeMap.putAll() method is invoked.
|
void |
resolveCollision(CompositeMap composite,
Map existing,
Map added,
Collection intersect)
Called when adding a new Composited Map results in a
key collision.
|
void resolveCollision(CompositeMap composite, Map existing, Map added, Collection intersect)
composite
- the CompositeMap with the collisionexisting
- the Map already in the composite which contains the
offending keyadded
- the Map being addedintersect
- the intersection of the keysets of the existing and added mapsObject put(CompositeMap map, Map[] composited, Object key, Object value)
map
- the CompositeMap which is being modifiedcomposited
- array of Maps in the CompositeMap being modifiedkey
- key with which the specified value is to be associated.value
- value to be associated with the specified key.UnsupportedOperationException
- if not definedClassCastException
- if the class of the specified key or value
prevents it from being stored in this map.IllegalArgumentException
- if some aspect of this key or value
prevents it from being stored in this map.NullPointerException
- this map does not permit null
keys or values, and the specified key or value is
null.void putAll(CompositeMap map, Map[] composited, Map mapToAdd)
map
- the CompositeMap which is being modifiedcomposited
- array of Maps in the CompositeMap being modifiedmapToAdd
- Mappings to be stored in this CompositeMapUnsupportedOperationException
- if not definedClassCastException
- if the class of the specified key or value
prevents it from being stored in this map.IllegalArgumentException
- if some aspect of this key or value
prevents it from being stored in this map.NullPointerException
- this map does not permit null
keys or values, and the specified key or value is
null.Copyright © 2001–2015 The Apache Software Foundation. All rights reserved.


Add desktops There can be at most 16 desktops Returns true on success, false if number_to_add was zero, or would result in more than 16 desktops. The ::on_layout_change notification will be sent if a changed was made.
TotalSpaces.add_desktops(1)
# File lib/totalspaces.rb, line 441 def add_desktops(number_to_add) TSApi.tsapi_addDesktops(number_to_add) end
Returns the version of the api present in TotalSpaces, a string such as “1.0” You should be using the same dylib version as that returned by the this call
puts "TotalSpaces API version: #{TotalSpaces.api_version}" if TotalSpaces.lib_total_spaces_version != TotalSpaces.api_version puts "Comms error!" exit(1) end
# File lib/totalspaces.rb, line 181 def api_version string_and_free(TSApi.tsapi_apiVersion) end
Cancel the layout change notification
# File lib/totalspaces.rb, line 367 def cancel_on_layout_change $tsapi_on_layout_change_block = nil TSApi.tsapi_unsetLayoutChangedCallback end
Cancel the ::on_space_change notification.
# File lib/totalspaces.rb, line 339 def cancel_on_space_change $tsapi_on_space_change_block = nil TSApi.tsapi_unsetSpaceWillChangeCallback end
Returns the number of the current space. Numbering starts at 1, except if you have the Dashboard enabled as a space, in which case the Dashboard counts as space 0
puts "Current space number: #{TotalSpaces.current_space}"
# File lib/totalspaces.rb, line 198 def current_space TSApi.tsapi_currentSpaceNumber end
Returns true if the dashboard is configured to appear as a space in Mission Control preferences.
puts "Dashboard is a space: #{TotalSpaces.dashboard_is_a_space?}"
# File lib/totalspaces.rb, line 254 def dashboard_is_a_space? TSApi.tsapi_dashboardIsASpace end
Returns the number of columns defined in TotalSpaces
puts "Number of columns: #{TotalSpaces.grid_columns}"
# File lib/totalspaces.rb, line 270 def grid_columns TSApi.tsapi_definedColumns end
Returns the number of rows defined in TotalSpaces
puts "Number of rows: #{TotalSpaces.grid_rows}"
# File lib/totalspaces.rb, line 262 def grid_rows TSApi.tsapi_definedRows end
Returns the version of the dylib, a string such as “1.0” You should be using the same dylib version as that returned by the ::api_version call
puts "libTotalSpaces version: #{TotalSpaces.lib_total_spaces_version}" if TotalSpaces.lib_total_spaces_version != TotalSpaces.api_version puts "Comms error!" exit(1) end
# File lib/totalspaces.rb, line 167 def lib_total_spaces_version string_and_free(TSApi.tsapi_libTotalSpacesVersion) end
Move space to a new position You cannot move a space to position 1, and you cannot move the first space anywhere else - it is fixed. You cannot move full screen apps around with this method, only normal desktops Returns false if the space_number or position_number is not valid.
TotalSpaces.move_space_to_position(4, 2)
# File lib/totalspaces.rb, line 429 def move_space_to_position(space_number, position_number) TSApi.tsapi_moveSpaceToPosition(space_number, position_number) end
Command TotalSpaces to switch to the given space number. Returns false if the space number was invalid. The ::on_space_change notification will be sent.
TotalSpaces.move_to_space(1)
# File lib/totalspaces.rb, line 304 def move_to_space(space_number) TSApi.tsapi_moveToSpace(space_number) end
Move a window to a given space The window_id parameter must be fetched using window_list. Returns false if the space_number or window_id is invalid.
# File lib/totalspaces.rb, line 417 def move_window_to_space(window_id, space_number) TSApi.tsapi_moveWindowToSpace(window_id, space_number) end
Returns the name for a space. The returned string will be empty if the space number is not valid
current_space = TotalSpaces.current_space puts "Current space is called: #{TotalSpaces.name_for_space(current_space)}"
# File lib/totalspaces.rb, line 208 def name_for_space(space_number) name = string_and_free(TSApi.tsapi_spaceNameForSpaceNumber(space_number)) name.force_encoding("UTF-8") end
Returns the number of desktops that are present in the system. This may be a bigger number that the rows x columns in the grid if more desktops have been created in Mission Control.
puts "Number of desktops: #{TotalSpaces.number_of_desktops}"
# File lib/totalspaces.rb, line 246 def number_of_desktops TSApi.tsapi_numberOfDesktops end
Returns the number of fullscreen apps present
puts "Number of fullscreens: #{TotalSpaces.number_of_fullscreens}"
# File lib/totalspaces.rb, line 226 def number_of_fullscreens TSApi.tsapi_numberOfFullScreens end
Returns the number of fullscreen apps tht are defined in the grid - this can be defined in Advanced preferences in TotalSpaces. The return value does not depend on how many fullscreens actually exist in the grid - the value is the definition only, there could be fewer than this actually present.
puts "Number of fullscreens in the grid: #{TotalSpaces.number_of_fullscreens_in_grid}"
# File lib/totalspaces.rb, line 237 def number_of_fullscreens_in_grid TSApi.tsapi_numberOfFullScreensInGrid end
Returns the total number of spaces including fullscreens, dashboard (if it's a space), and spaces that are unused in the grid
puts "Total number of spaces: #{TotalSpaces.number_of_spaces}"
# File lib/totalspaces.rb, line 218 def number_of_spaces TSApi.tsapi_numberOfSpaces end
Register for notifications on layout change. The given block will be called whenever the layout changes - this could be due to making an app fullscreen, changing a space name, or changing the layout of the TotalSpaces grid. There are no arguments passed to the block.
TotalSpaces.on_layout_change {puts "Spaces changed"} sleep
When you get a notification from this method, you should re-fetch any information about the spaces that you may be storing.
There can only be one block registered at any time, the most recently registered one will be called.
# File lib/totalspaces.rb, line 360 def on_layout_change(&block) $tsapi_on_layout_change_block = block # prevent GC TSApi.tsapi_setLayoutChangedCallback(block) end
Register for notifications on space change. The given block will be called whenever you move from one space to another. The arguments are the space number you moved from, and the one you are moving to.
TotalSpaces.on_space_change {|from, to| puts "Moving from space #{from} to space #{to}"} sleep
There can only be one block registered at any time, the most recently registered one will be called. This callback is called just before the space actually changes - ::current_space will still report the from space.
# File lib/totalspaces.rb, line 332 def on_space_change(&block) $tsapi_on_space_change_block = block # prevent GC TSApi.tsapi_setSpaceWillChangeCallback(block) end
Remove desktops The highest numbered desktops are removed. Removing a desktop you are currently on will result in TotalSpaces switching to another dektop. Any windows present on a desktop being removed will be moved to one of the remaining desktops. Returns true on success, false if number_to_remove was zero or would result in less than 1 desktop remaining. The ::on_layout_change notification will be sent if a change was made.
TotalSpaces.remove_desktops(1)
# File lib/totalspaces.rb, line 457 def remove_desktops(number_to_remove) TSApi.tsapi_removeDesktops(number_to_remove) end
Sets the number of columns defined in TotalSpaces.
This does not change the actual number of desktops present, you should call ::add_desktops or ::remove_desktops as appropriate after changing the number of columns.
TotalSpaces.set_grid_columns(3)
# File lib/totalspaces.rb, line 294 def set_grid_columns(columns) TSApi.tsapi_setDefinedColumns(columns) end
Sets the number of rows defined in TotalSpaces.
This does not change the actual number of desktops present, you should call ::add_desktops or ::remove_desktops as appropriate after changing the number of rows.
TotalSpaces.set_grid_rows(3)
# File lib/totalspaces.rb, line 282 def set_grid_rows(rows) TSApi.tsapi_setDefinedRows(rows) end
Set the name for a space. Note that using this command will cause a layout notification to be sent. if the new name was different from that previously set. The maximum length for a name is 255 bytes.
TotalSpaces.set_name_for_space(1, "Home")
# File lib/totalspaces.rb, line 315 def set_name_for_space(space_number, name) TSApi.tsapi_setNameForSpace(space_number, name) end
Returns the version of TotalSpaces running on the system, a string such as “1.1.4”
puts "TotalSpaces version: #{TotalSpaces.total_spaces_version}"
# File lib/totalspaces.rb, line 189 def total_spaces_version string_and_free(TSApi.tsapi_totalSpacesVersion) end
Get a list of all the windows on your mac It returns an array containing a hash for each space. The hash contains the space number (key :space_number) and an array of hashes, one for each window (key :windows). The windows are in front to back order. Each window hash contains a window_id, title, frame, app_name and is_on_all_spaces flag
The below example would move the frontmost window to the next space to the right.
windows = TotalSpaces.window_list if !windows.empty? current_space_windows = windows[TotalSpaces.current_space - 1] front_window = current_space_windows[:windows][0] TotalSpaces.move_window_to_space(front_window[:window_id], TotalSpaces.current_space + 1) end
# File lib/totalspaces.rb, line 387 def window_list result = [] list = TSApi.tsapi_windowList main_array = Spaces.new(list) (0...main_array[:count]).each do |n| result[n] = {} windows_array = Space.new(main_array[:windows_arrays] + n * Space.size) result[n][:space_number] = windows_array[:space_number] result[n][:windows] = [] (0...windows_array[:count]).each do |m| window_hash = result[n][:windows][m] = {} window = Window.new(windows_array[:windows_array] + m * Window.size) window_hash[:window_id] = window[:window_id] window_hash[:title] = window[:title].dup.force_encoding("UTF-8") window_hash[:frame] = window[:frame].dup.force_encoding("UTF-8") window_hash[:is_on_all_spaces] = window[:is_on_all_spaces] window_hash[:app_name] = window[:app_name].dup.force_encoding("UTF-8") end end TSApi.tsapi_freeWindowList(list) result end


Back To Homepage
Chapter 1 - What is Diabetes?
Chapter 2 - Glucose Monitoring
Chapter 3 - Insulin
Chapter 4 - Hypoglycemia or Low
Chapter 5 - Hyperglycemia or High
Chapter 6 - Nutrition
Chapter 7 - Exercise and Diabetes
Chapter 8 - Personal Plan
Chapter 9 - Famous with Diabetes
Menu
Chapter 2
Blood Glucose Monitoring
Why Test your Blood Glucose?
Your browser does not support the video tag.
How do I use a glucose meter?
Your browser does not support the video tag.
Question 1. Which is the correct first step tp test your blood glucose?
A. Put Lancet in device
B. Prick finger
C. Wash and dry hands
D. Collect items
Yay!! You are Correct! :)
Please Try Again :(
Please Select one!

Question 2. How many times should you test your glucose?
A. Twice a day
B. Once a day
C. Three times a day
D. Four times a day
Yay!! You are Correct! :)
Please Try Again :(
Please Select one!

To the Next Chapter
Previous
Next


The best way to learn Corona is by writing sample apps. To do this, you write programs in a language called Lua. If you're new to the language, please read the Introduction to Lua.
In keeping with tradition, you'll write some Lua code that prints "Hello World!" to the Terminal/Output window. Then you'll display that text to the screen, change its color, and create basic tap interactivity to change its color randomly. After that, you'll learn how to implement physics in Corona with just a few lines of code.
In Mac OS X, if you're running the Corona Simulator by itself (without the Terminal open) please close and quit the Simulator for a moment — you need to reload it with the Terminal window "linked" and working in unison. Now, in your Corona SDK folder, instead of opening Corona Simulator
, open Corona Terminal
. The Terminal will load, then it will automatically open the Corona Simulator Welcome Window where you can choose the Simulator option. The Terminal will then display diagnostic output as you run your code.
With both the Corona Simulator and the Corona Terminal (Mac OS X) or Corona Simulator Output (Windows) open, load your chosen text editor. Create a blank file and save it as main.lua
to a project directory named "HelloWorld". In general, each project should be contained within its own directory on your system, and each project's core file must be named main.lua
. You may eventually design complex apps using external modules, but every Lua project must contain a main.lua
file at its core.
Include only the files that your application uses in the project directory. You should not leave old copies of main.lua
or old multimedia assets in the folder. Also, you should only include final production assets in the folder; do not include original native files produced by tools like Photoshop® (.psd) or Illustrator® (.ai).
In the text file, type the following:
print( "Hello World!" )
Save your file, then open the project in the Simulator: File → Open... → ["HelloWorld" directory]
Note that you don't need to select "main.lua"
to open the project; simply click the Open button and Corona will load the project in the Simulator.
Notice that nothing appears in the Simulator window. Don't panic! Look at the Terminal/Output window and you'll see the text Hello World!
displayed there.
In Lua, the humble print
command is used to output messages only to the Terminal, including diagnostic messages about what's happening in your program, warning/error messages, and "debugging" messages. It can be used to quickly test aspects of a program to ensure that it's operating properly.
The print
command accepts only one parameter. If you are new to programming, a parameter is a numerical value, text string, variable, or similar piece of information that is passed to and used by the command or function. In the above example, the parameter passed to the print()
function is simply "Hello World!"
. This parameter is a text string and thus it is enclosed in quotes. As you can see in the Terminal view, the quotes are not displayed in the printed result; they simply indicate that the parameter is a string value (text), not a variable or numerical value.
To display Hello World!
on the Simulator screen, you need to use a different API (Application Programming Interface) included in Corona's display library. A library in Corona is a collection of functions and commands that provide useful, related functionality.
To show Hello World!
in the Simulator, add the following line to your text file:
local myTextObject = display.newText( "Hello World!", 50, 50, "Arial", 60 )
If you're new to scripting or programming, this might look complicated, but in fact it's relatively simple. Let's examine each element in order:
local myTextObject
This is the basic method to declare a variable in Lua. Unlike most other languages, Lua is a dynamically typed language. This means that you don't need to explicitly define the variable as a number, string, etc. Variables can, and sometimes will, change types as you work with them. As you study further, you'll realize that this is a very convenient feature of Lua.
In this case, local
defines the scope of the variable in Lua's memory system. Scoping is a very important aspect of Lua which you can read about here.
myTextObject
is the variable name and can be whatever you wish. However, variable names must be unique (not previously declared elsewhere in your code) and non-reserved — you cannot name your variables the same as a command/API reserved by Lua or Corona.
display.newText( ... )
As mentioned above, Corona includes many libraries, including the display library which contains APIs related to displaying and managing screen content like text, vector objects, images, and animated sprites.
To access an item from a library, use this notation consistently:
[library].[API]
This tells Corona that you wish to "access" the chosen library then "use" the chosen API. You must always specify the library first, then a dot (period), then the API. This is known as a property relationship.
display.newText( ... ) --CORRECT!
newText( ... ) --INCORRECT
The newText
API is self-explanatory: display a new text object to the screen! It requires five core parameters as explained below. Note that parameters are always separated by commas — do not separate them solely with spaces!
display.newText( string, left, top, font, size )
string
— the value to display as textleft
— the left (horizontal) position of the text on the screentop
— the top (vertical) position of the text on the screenfont
— the desired font facesize
— the size of the font on the screenNow that you understand each parameter, inspect the newText
command in your code. You are telling Corona to display the string "Hello World!" to the screen. The text will begin at 50 pixels from the left side of the screen. The text top position will be 50 pixels from the top of the screen. The text will be shown in the common "Arial" font face. Finally, the text will be shown at a size of 60.
Let's check the result of your new code using the Simulator! Simply "relaunch" the Simulator using ⌘-R (Command-R) and you will see your text displayed on the screen in the upper-left corner.
Now let's discuss how to modify the color of your text. Notice that the newText
API does not include parameters to set the color directly. To accomplish this, you will need to use another command:
[object]:setTextColor( R, G, B ).
If you use this command directly after you display the text — on the next line — it effectively occurs at the same time in your app and the new color will be reflected immediately.
Let's try the command in your app. Add this code to your text document on the line directly following the newText
command:
myTextObject:setTextColor( 255, 0, 0 )
Notice that you begin with myTextObject
, the same variable name that you assigned above. Directly following that, you put a colon, and following that you write the command.
In addition to the dot notation explained above, let's examine the colon notation.
[object]:[command]
This notation is called an object method. Typically this method modifies the variable/object before the colon. In this tutorial, setTextColor( 255, 0, 0 )
, following the colon, tells Corona that you want to change the color of myTextObject
, specified before the colon.
As you can see, this API requires 3 core parameters: R (red), G (green), and B (blue). Each parameter is a color "channel" and the value must be a number between 0 and 255. The higher the value, the more of that color will be "mixed" into the final result. If you set all three values to 255, the result will be solid white; if you set all three values to 0, the result will be solid black. In the above line of code, only the red value is mixed into the result. Relaunch the Simulator with ⌘-R (Command-R) and notice that the text color has changed to pure, bright red.
As you develop your application, you'll find yourself following this procedure often: you'll load your app in the Simulator, make some edits to main.lua
file in the text editor, switch back to the Simulator, and "relaunch" your app to see the results. This saves you the time and trouble of quitting and restarting the simulator.
You can experiment with different colors yourself, or refer to a chart such as the one found on this page. On this chart, you will see the RGB values under the column "Decimal code". Although this chart contains a wide array of colors, you are not limited to them — you can adjust the three values as necessary to achieve the exact color you desire.
It's often useful to set a default text color for all of the text in your app. Fortunately, you can achieve this with just one line of code.
At the very top of your text document, insert a new line and add this code:
display.setDefault( “textColor”, 150, 150, 150 )
Now, all of the text in your app will be displayed in a medium grey, and you won't need to spend time setting the color of every new text object. Of course, you can still override this default text color on a particular text element by using the explicit setTextColor()
method described above.
Let's add some basic interactivity that will change the color of the text randomly. Add the following lines to the end of your project:
function screenTap()
local r = math.random( 0, 255 )
local g = math.random( 0, 255 )
local b = math.random( 0, 255 )
myTextObject:setTextColor( r, g, b )
end
This code creates a new function, a core element of programming. A function is a block of code — a routine or set of commands — that is "called" (to be executed) by another command or process.
This specific function is named screenTap, the name you'll use to reference it. Since this is a custom function you've written, you can name it whatever seems logical; note that many programmers adhere to a short descriptive "sentence" with the first word lowercase and successive words capitalized for legibility.
Inside the function, you write four lines. The first three lines create variables for the red, green, and blue values that you'll use to set the text color. These three values are randomly determined by the math.random()
command, part of Corona's math library. In this example, you tell Corona to choose a random number between 0 and 255, the allowed range for any of the color channel values.
The fourth line simply uses those random values to set the text color, using the same method you practiced with already.
Next, you need to add a Corona event listener to create interactivity. Add this line to your project on the line after the function's end
line:
display.currentStage:addEventListener( "tap", screenTap )
Event listeners can take various forms which you'll learn as you progress further. This one adds a "tap" listener to the screen "stage". For more information on the stage, please read the guide on Display Groups and Coordinates.
Note that the object method is used to create an event listener. The object is the Corona stage, accessed by the command display.currentStage
. The method is the addition of an event listener with two parameters:
"tap"
— this tells Corona that you wish to "listen" for a quick screen tap, meaning a quick touch and release on a specific point.screenTap
— this is the reference to the function you just wrote; it will be executed when the tap occurs.That's it! Relaunch the Simulator and now "tap" (click) on the screen. The text should change to a random color on each click. This is an extremely basic example of what you can do using a tap listener, but it exhibits how easy it is to add basic interactivity to a Corona object.
In line with Corona's rapid prototyping, you can implement physics with just a few lines of code. Corona includes the widely-used Box2D physics engine which features multiple body types, collision detection, joints, raycasting, and more. If you want to follow along with this project in the Simulator, the source code and assets can be found in your local application directory here:
CoronaSDK → SampleCode → Physics → HelloPhysics
When using physics, the first thing you must do is require()
the physics library. Don't worry about what this does internally — just realize that it opens up access to the physics APIs and functions. In addition, you must start the physics engine; this should be done before calling any other physics functions.
local physics = require( "physics" )
physics.start()
Next, you should add some visual content to the screen. A good starting point is a sky background and a grassy piece of ground. More details about images are described in the Display Objects guide, but at this time, observe the simple use of display.newImage()
:
local sky = display.newImage( "bkg_clouds.png" )
sky.x = 160; sky.y = 195
local ground = display.newImage( "ground.png" )
ground.x = 160; ground.y = 445
This basic code displays two images on the screen: "bkg_clouds.png"
for the sky background and "ground.png"
for the ground image. After the images are placed, the position(s) are adjusted to specific x/y coordinates on the screen: 160,195 for the sky and 160,445 for the grass. Reload the project in the Simulator and you'll see the sky and ground displayed on the screen.
Now the fun part: creating a physics body. When you make a standard display object into a physics body, it immediately becomes a functioning element of the physics engine and it will adhere to basic Box2D physics behavior.
physics.addBody( ground, "static", { friction=0.5, bounce=0.3 } )
This line is simple. The first parameter, ground
, is the name of the display object you want convert to a physics body. The second parameter, "static"
, tells Corona that this object is a solid, non-moving object that will be effectively locked in place and immune to physical forces like gravity. As you might guess, this is a perfect body type for the solid ground. The third parameter is a Lua table/array {}
that contains various settings and properties for the physics body. In this case, the friction is set to 50% and the bounce to 30%.
If you reload this in the Simulator, it won't look any different because, by default, objects that are physical bodies do not "appear" any different than normal objects. Don't concern yourself with this now — just be aware that the ground is now a physical body that will interact with other physical bodies in the scene.
To see this in action, add an additional object now:
local crate = display.newImage( "crate.png" )
crate.x = 180; crate.y = -50; crate.rotation = 5
This adds a wooden crate to the scene, far above the ground and off the screen. At this point, it will just float in space because it's not yet a physical body. To change this, convert it to a physical body in the same fashion as the ground:
physics.addBody( crate, { density=3.0, friction=0.5, bounce=0.3 } )
Notice that in this case, the second parameter which defines the body type — "static"
in the case of the ground object — has been omitted. This makes the crate into a dynamic physics object, the default body type in Corona. Dynamic objects will be affected by all forces such as gravity, impulses, and collisions with other physical objects.
Now reload the project in the Simulator and watch how the crate falls from the sky, collides with the ground, bounces, and comes to a rest. Implementing basic physics in Corona is that easy!