# Welcome

Welcome to the Formulative documentation! This document is organized as the followings:

• First things to know about Formulative, what is Formulative?
• Tutorials: short documents you can walk through to get a first-hand experience
• Use Cases: describers some of the scenarios when you can use Formulative efficiently
• Documentation: describes how documentation is organized

## What is Formulative?

Formulative is a Platform for developing Calculations and Mathematical Models in general. More concretely:

• Domain experts implement calculations (and write documentation) without the need to install development environments and manage libraries
• The language is based on mathematical formalism wherever possible (check out the tutorials)
• yes, you need to learn the language, but we hope you will find it more fun than a burden, along the lines of more thinking less writing
• Using the model:
• once the model is ready (tested), code can be generated from the models for your selected target platforms (for both server and client architectures)
• for the technologically savvy users and IT: downloaded code can be containerized and used as part of (Big)Data processing.
• built in support for data analytics is soon to come with support for R compatible statistics library and BLAS based Linear Algebra
• Hosting calculations is easy: Formulative can host your calculations via our scalable Calculation Service API deployment option
• We share your concern regarding security, you can specify who you give calculation access, read more about Security concepts
a taste of the language
Description Math view Formula Source
Function f, summing squares of x indexed variable
$\mathit{f}:\mathbb{R}⟶\mathbb{R},\left({\mathit{x}}_{\mathit{i}}|\mathit{i}=\mathrm{1},\mathrm{\dots },\mathit{n}\right)⟼\sum _{\mathit{i}=\mathrm{1}}^{\mathit{n}}{\mathit{x}}_{\mathit{i}}^{\mathrm{2}}$
f: %R --> %R, (x_i | i=1,...,n) |--> {+}__{i=1}^^n x_i^2
Calculate the standard deviation given an indexed variable and the average
$\mathit{\sigma }=\sqrt{\frac{\sum _{\mathit{i}=\mathrm{1}}^{\mathit{N}}{\left({\mathit{x}}_{\mathit{i}}-\mathit{\mu }\right)}^{\mathrm{2}}}{\mathit{N}}}$
\sigma = \/~{ { {+}__{i=1}^^N (x_i - \mu)^2}/N}
${\mathit{x}}_{\mathrm{1}}=\frac{-\mathit{b}+\sqrt{{\mathit{b}}^{\mathrm{2}}-\mathrm{4}\mathit{a}\mathit{c}}}{\mathrm{2}\mathit{a}}$
x_1 = {-b + \/~{b^2 - 4 a c} } / 2a

## Why use it?

• Domain experts do not need to be software architects, they can focus on their domain and implement their model using the Formulative language
• Implementing Models from documentation to production code is a difficult process, you can save a lot of time by using in a language that is close to the mathematical model
• Formulative integrates all stakeholders work required to design, implement, deploy and use Calculation models on a single platform
• Offering access to well documented Calculation Services to your Partners makes it easier to work with you
• Overall: Formulative can significantly reduce the time and resources required to implement production ready Calculations

## Use Cases

### You have a projects involving lots of math algorithms

Assuming you have a larger math (or math like) model and you need to implement it. Without Formulative you should start with selecting the right implementation language, development tools, design patterns, runtime architecture, etc.

With Formulative however, you have the high-level math support to start implementing your Model without the usual software engineering issues (setting up development environments, etc.) and other then evaluate them in your own environment, you can also publish them to IT for integration.

If your requirement is to process large volumes of data and calculate results, you can create batch (Map Reduce) jobs wrapping the generated code in containers and use S3 to upload input data and download calculated results.

### Provide implementations to models you design

Assuming you already develop mathematical models in some domain for your customers, you might want to extend your business with offering implementations they can integrate directly into their systems. You create the models in Formulative and invite your users as Integrators. They can than either access your hosted web services or download generated code.

### Factoring out calculations

Multiple systems require the same calculations (e.g. product calculations) and these systems might even run on different architectures. It would be logical to factor out calculation implementations into a separate system. Formulative can provide you that system either public-, private-cloud or on-premise.

### Sharing calculations with 3rd parties

Some businesses require sharing calculations with 3rd parties, portals, resellers, brokers, partners, etc. To support your partners you need to manage your calculations (versioning, security, distribution) in order to efficiently integrate into their systems. Formulative can be this system that integrates the work needed to create models and the tasks required to manage the corresponding APIs.

### You need user configurable calculations

It is a usual customer requirement to provide user configurable business rules. When these rules are domain calculations you can involve customer domain experts to provide and maintain these calculations while you develop the rest of the required functionality. If you are a software developer implementing custom business processes you can integrate Formulative services into you application.

### Part of your API ecosystem

You plan on integrating cloud services to support your business. If you also need calculations (e.g. to support forms, or provide calculated fields) as part of your business flow, you can use Formulative to integrate with other SaaS providers.

## Architectural uses-cases

### Web Service Hosting

In this scenario the target of modelling is a scalable web service deployed on Formulative. In this architecture:

• the modeller uses the Web Application to create the model
• the deployer creates builds and defines cluster scaling parameters for the nodes hosting the calculation service
• HTTPS is used to execute calculation requests from either other Server side applications or Mobile Apps.

Calculation Services are hosted as Kubernetes deployments on AWS with scaling parameters provided for Formulative Containers.

### Code Hosting

In this scenario the target of modelling is a downloadable archive containing the generated code and accompanying documentation an application integrator can use to embed the calculations. In this architecture:

• the modeller uses the Web Application to create the model
• the deployer creates builds for the selected platforms