Quickstart Guide¶
This guide will get you started with rheojax in minutes.
Basic Workflow¶
The Pipeline API provides the simplest way to analyze rheological data:
from rheojax.pipeline import Pipeline
# Create pipeline
pipeline = Pipeline()
# Load data (auto-detects format)
pipeline.load('experiment.txt')
# Fit model
pipeline.fit('maxwell')
# Plot results
pipeline.plot()
# Save results
pipeline.save('results.hdf5')
Working with Models¶
Direct Model Access¶
For more control, use the Modular API:
from rheojax.models import Maxwell
from rheojax.io import load_trios
# Load data
data = load_trios('experiment.txt')
# Create and fit model
model = Maxwell()
model.fit(data.x, data.y)
# Get parameters
params = model.parameters
print(f"G_s = {params.get_value('G_s'):.2e} Pa")
print(f"eta_s = {params.get_value('eta_s'):.2e} Pa·s")
# Make predictions
predictions = model.predict(data.x)
Available Models¶
Classical models:
Maxwell: Two-parameter viscoelastic modelZener: Three-parameter standard linear solidSpringPot: Two-parameter fractional element
Fractional models (11 variants available)
Non-Newtonian flow models:
HerschelBulkley,Bingham,PowerLawCarreauYasuda,Cross,Casson
DMTA / DMA Data¶
For Dynamic Mechanical Analyzer data in tension, compression, or bending:
model.fit(omega, E_star, test_mode='oscillation',
deformation_mode='tension', poisson_ratio=0.5)
See DMTA / DMA Analysis for the complete DMTA guide.
Working with Transforms¶
Apply transforms to process raw data:
from rheojax.transforms import FFTAnalysis
from rheojax.io import load_trios
# Load raw time-series data
data = load_trios('chirp_experiment.txt')
# Apply FFT analysis
analysis = FFTAnalysis()
processed = analysis.transform(data)
# Now data is in frequency domain with G', G''
Mastercurve Generation¶
from rheojax.transforms import Mastercurve
# Load multi-temperature data
data_list = [load_trios(f'temp_{t}C.txt') for t in [25, 35, 45, 55]]
# Generate mastercurve
mastercurve = Mastercurve(reference_temp=25)
result = mastercurve.transform(data_list)
File I/O¶
Supported Formats¶
from rheojax.io import auto_load, load_trios, load_csv, load_excel
# Auto-detect format
data = auto_load('experiment.txt')
# Explicit format
data = load_trios('trios_file.txt')
data = load_csv('data.csv', x_col='frequency', y_col='modulus')
data = load_excel('results.xlsx', sheet='Sheet1')
Saving Results¶
from rheojax.io import save_hdf5, save_excel
# Save data
save_hdf5(data, 'output.h5')
# Save results to Excel
save_excel(results, 'report.xlsx', include_plots=True)
Next Steps¶
Read the user_guide for detailed documentation
Explore API Reference for complete API documentation
See example notebooks for advanced usage