> ## Documentation Index
> Fetch the complete documentation index at: https://developer.synopsys.com/llms.txt
> Use this file to discover all available pages before exploring further.

# CreatePolynomialModel Class Reference

Part of [MOP models](https://developer.synopsys.com/docs/optislang/optislang-3d-postprocessing-script-api/group__models)

Defines a [PolynomialModel](https://developer.synopsys.com/docs/optislang/optislang-3d-postprocessing-script-api/class_polynomial_model.md) Used Properties:

## Public Member Functions

| Type | Name |
| - | - |
| virtual string | [\_\_str\_\_](https://developer.synopsys.com/docs/optislang/optislang-3d-postprocessing-script-api/struct_create_model_base.md#a3031d648b73235d11d64df95db3d84ce) () Output function used in python context. Use this function to print instances of this class in python. |
|  virtual | [addProperty](https://developer.synopsys.com/docs/optislang/optislang-3d-postprocessing-script-api/class_property_user_base.md#aedfb47575823522e6a6d22ce6c12e826) ([PropertyBase](https://developer.synopsys.com/docs/optislang/optislang-3d-postprocessing-script-api/struct_property_base.md) p) Properties that help the [ScalarMOP](https://developer.synopsys.com/docs/optislang/optislang-3d-postprocessing-script-api/struct_scalar_m_o_p.md) scheduling the Models to be built The properties class needs to be implemented for the specific model type. |
| [ModelBase](https://developer.synopsys.com/docs/optislang/optislang-3d-postprocessing-script-api/class_model_base.md) \* | [compute](#a428e7ba979340c651ec1372a3307e037) (::data\_handler::DataHandlerBase datahandler, [TrainingPlanBase](https://developer.synopsys.com/docs/optislang/optislang-3d-postprocessing-script-api/struct_training_plan_base.md) training\_plan, quality\_measure::QualityMeasureBase quality\_measure) Builds the model from the given samples and returns the model. |
| | [CreatePolynomialModel](#a4c733efb0cce664014dbff681f8aa200) () Creates an default initialized instance of this class. |
| | [CreatePolynomialModel](#a4f38679ec6c4c3f6e2406f841a0cf01a) ([CreatePolynomialModel](https://developer.synopsys.com/docs/optislang/optislang-3d-postprocessing-script-api/class_create_polynomial_model.md) other) Copies an instance of this class. |
|  virtual [PropertyList](https://developer.synopsys.com/docs/optislang/optislang-3d-postprocessing-script-api/class_property_list.md) | [getProperties](https://developer.synopsys.com/docs/optislang/optislang-3d-postprocessing-script-api/class_property_user_base.md#a0e1dd7df82728594fc128ed1c797b0c0) () Returns the properties stored by this user. |
| virtual bool | [isValid](#a1a42d0ff7ef3b9c17965ecc14310ed5d) (::data\_handler::DataHandlerBase datahandler, [TrainingPlanBase](https://developer.synopsys.com/docs/optislang/optislang-3d-postprocessing-script-api/struct_training_plan_base.md) training\_plan) override Destroys an instance of this class. |
| [CreatePolynomialModel](https://developer.synopsys.com/docs/optislang/optislang-3d-postprocessing-script-api/class_create_polynomial_model.md) | [operator=](#af9abc184ff13de6ca630781a2fc35fcf) ([CreatePolynomialModel](https://developer.synopsys.com/docs/optislang/optislang-3d-postprocessing-script-api/class_create_polynomial_model.md)) Copies an instance of this class. |
| virtual | [transferProperties](https://developer.synopsys.com/docs/optislang/optislang-3d-postprocessing-script-api/class_property_user_base.md#ab9507274f126b856fb69cd621f0f9fb4) ([PropertyList](https://developer.synopsys.com/docs/optislang/optislang-3d-postprocessing-script-api/class_property_list.md) property\_list) Convenience function to transfer a complete [PropertyList](https://developer.synopsys.com/docs/optislang/optislang-3d-postprocessing-script-api/class_property_list.md) into the model. |

## Public Attributes

| Type | Name |
| - | - |
| [MixedTermInteraction](https://developer.synopsys.com/docs/optislang/optislang-3d-postprocessing-script-api/group__models#ga05c89261a7a8de048e31f3e05214484b) | [interaction](#a0c4b96340c20432ff0d6b429ac2f75ee) Specifies if the mixed terms in the polynomial model shall be considered or not. |
|  uint64\_t | [max\_order](#ac4bd3143ec6179fe07419cd827281496) Specifies the polynomial models maximal order (degree) valid value range of \[TODO], Auto ??? |
|  string | **node\_name** |
|  int | [order](#ac85d5511fdb8d162a7278bfb440ae420) Specifies the polynomial models actual order valid value range of \[TODO], -1 : Auto - TODO. |
|  Transformation | [value\_transformation](#a850bec49118fd5e977ea5be55a59d594) Specifies the type of value transformation the model shall use. |
|  string | **working\_dir** |

## Detailed Description

Defines a [PolynomialModel](https://developer.synopsys.com/docs/optislang/optislang-3d-postprocessing-script-api/class_polynomial_model.md) Used Properties:

* CoefficientFactorProperty
* ComplexityProperty
* DeltaErrorInputProperty

## Member Function Documentation

### \_\_str\_\_()

```cpp theme={null}
virtual string __str__()
```

`virtual` `inherited`

Output function used in python context. Use this function to print instances of this class in python.

**Returns**

string containing the object

Reimplemented in [CreateCustomModel](https://developer.synopsys.com/docs/optislang/optislang-3d-postprocessing-script-api/class_create_custom_model.md#a3031d648b73235d11d64df95db3d84ce).

### compute()

```cpp theme={null}
ModelBase * compute(
    ::data_handler::DataHandlerBase datahandler,
    TrainingPlanBase training_plan,
    quality_measure::QualityMeasureBase quality_measure
)
```

Builds the model from the given samples and returns the model.

**Parameters**

| Name | Description |
| - | - |
| datahandler | The datahandler that contains the samples |
| training\_plan | The training plan that specifies how the model will be trained |
| quality\_measure | The quality measure that allows to compute a models approximation quality |

**Returns**

The trained model iff not cancelled

### isValid()

```cpp theme={null}
virtual bool isValid(
    ::data_handler::DataHandlerBase datahandler,
    TrainingPlanBase training_plan
)
```

`override` `virtual`

Destroys an instance of this class.

This function checks if the model can validly be trained from the given samples

**Parameters**

| Name | Description |
| - | - |
| samples | The samples the model shall be trained with. |

**Returns**

True iff th emodel can be trained with the configuration data, the properties and samples

Implements [CreateModelBase](https://developer.synopsys.com/docs/optislang/optislang-3d-postprocessing-script-api/struct_create_model_base.md#a1202ca4468e899d1e6d321ebf59e67a1).

### transferProperties()

```cpp theme={null}
virtual transferProperties(PropertyList property_list)
```

`virtual` `inherited`

Convenience function to transfer a complete [PropertyList](https://developer.synopsys.com/docs/optislang/optislang-3d-postprocessing-script-api/class_property_list.md) into the model.

**Parameters**

| Name | Description |
| - | - |
| property\_list | The properties to transfer into this model |
