Andrew Carr (e/🤸) Profile picture
May 7, 2021 7 tweets 3 min read Read on X
Formal methods are a cool way to verify that your hardware or software is working as intended™

Z3 is a one stop shop for FM with theorem proving, SAT, SMT, and computer algebra capabilities.

Let's look at some fun examples

👇

1/6
A nice usage is constraint solving for non-linear polynomial equations.

2/6
It can prove theorems or provide counter-examples!

3/6
Need to write a package manager and are pulling your hair out from dependency management? Don't worry!

Just create two simple functions that calculate dependencies and conflicts and solve!

This showcases that you can verify many arbitrary software behaviours as well.

4/6
It works with numpy! Here's an example solving an inverse kinematics equation for robotics!!

5/6
And the grand finalé! In just a few lines of code you can solve the infamous 8-queens problem by setting row, column, and diagonal constraints and aggregating them together before solving.

6/6

• • •

Missing some Tweet in this thread? You can try to force a refresh
 

Keep Current with Andrew Carr (e/🤸)

Andrew Carr (e/🤸) Profile picture

Stay in touch and get notified when new unrolls are available from this author!

Read all threads

This Thread may be Removed Anytime!

PDF

Twitter may remove this content at anytime! Save it as PDF for later use!

Try unrolling a thread yourself!

how to unroll video
  1. Follow @ThreadReaderApp to mention us!

  2. From a Twitter thread mention us with a keyword "unroll"
@threadreaderapp unroll

Practice here first or read more on our help page!

More from @andrew_n_carr

Jul 29, 2021
Want to learn a new programming language? There are 5 key things you need to figure out in the process

1. syntax
2. semantics
3. idioms
4. libraries
5. tools

👇1/
Syntax: What do you write down to make your program "textually wellformed". This include symbols, formatting, whitespace, operators, and keywords.

New languages are hard because syntax is unfamiliar

For example APL vs Python showcases the vast difference in syntax
2/
Semantics: The rules that define program behavior. This defines the behavior implied by the syntax and is often the real challenge in learning a new language.

Run time behavior and compile time behavior ( type checking) are two examples of semantics

3/
Read 7 tweets
Mar 19, 2021
I'm super excited to share our work on self-supervised learning for audio. We extend the permutation pre-text task by using differentiable ranking and show improved performance on low-resource tasks (it also works great on images and video)

1/ Image
When using permutations in pretraining, a subset of permutations are used to train a classifier which predicts permutations as classes.

However, since there are n! different permutations of length n, it's not feasible to use any reasonable fraction of them for classes.

2/
We fix this problem by using a differentiable ranking objective which allows arbitrary permutations to be used.

By increasing the number of usable permutations, we find improved representations are learned which can be used on downstream tasks.

3/
Read 5 tweets

Did Thread Reader help you today?

Support us! We are indie developers!


This site is made by just two indie developers on a laptop doing marketing, support and development! Read more about the story.

Become a Premium Member ($3/month or $30/year) and get exclusive features!

Become Premium

Don't want to be a Premium member but still want to support us?

Make a small donation by buying us coffee ($5) or help with server cost ($10)

Donate via Paypal

Or Donate anonymously using crypto!

Ethereum

0xfe58350B80634f60Fa6Dc149a72b4DFbc17D341E copy

Bitcoin

3ATGMxNzCUFzxpMCHL5sWSt4DVtS8UqXpi copy

Thank you for your support!

Follow Us!

:(