Skip to content

rozgo/exgine

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

16 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Exchange Engine - A Market Exchange Simulator

Category theory inspired; where objects are assets and morphisms are rates, creating a mathematical formalization for an exchange (assets, accounts, rates and transactions).

Core component for OwnedEconomies

Requirements:

$ curl https://sh.rustup.rs -sSf | sh

Run tests:

cargo test -- --nocapture

Run examples:

cargo run --example robot_mission
  • In every tick agent should be able to purchase 1 MissionTime.
  • First it tries to purchase MissionTime with its Resource through Exchange::MissionTimeWithResource.
  • If this fails, it will try to purchase through Exchange::MissionTimeWithTrust.
  • If agent cannot purchase any more MissionTime it dies.

If everything worked you should see test results like this:

running 1 test
RIP! Agent was alive for 2 hours, 55 minutes and 1 seconds.
test agent_lifetime_until_death ... ok

About

A Market Exchange Simulator

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages