financial-calculator
Advanced financial calculator with future value tables, present value, discount calculations, markup pricing, and compound interest. Use when calculating investment growth, pricing strategies, loan values, discounts, or comparing financial scenarios across different rates and time periods. Includes both CLI and interactive web UI.
Best use case
financial-calculator is best used when you need a repeatable AI agent workflow instead of a one-off prompt.
Advanced financial calculator with future value tables, present value, discount calculations, markup pricing, and compound interest. Use when calculating investment growth, pricing strategies, loan values, discounts, or comparing financial scenarios across different rates and time periods. Includes both CLI and interactive web UI.
Teams using financial-calculator should expect a more consistent output, faster repeated execution, less prompt rewriting.
When to use this skill
- You want a reusable workflow that can be run more than once with consistent structure.
When not to use this skill
- You only need a quick one-off answer and do not need a reusable workflow.
- You cannot install or maintain the underlying files, dependencies, or repository context.
Installation
Claude Code / Cursor / Codex
Manual Installation
- Download SKILL.md from GitHub
- Place it in
.claude/skills/financial-calculator/SKILL.mdinside your project - Restart your AI agent — it will auto-discover the skill
How financial-calculator Compares
| Feature / Agent | financial-calculator | Standard Approach |
|---|---|---|
| Platform Support | Not specified | Limited / Varies |
| Context Awareness | High | Baseline |
| Installation Complexity | Unknown | N/A |
Frequently Asked Questions
What does this skill do?
Advanced financial calculator with future value tables, present value, discount calculations, markup pricing, and compound interest. Use when calculating investment growth, pricing strategies, loan values, discounts, or comparing financial scenarios across different rates and time periods. Includes both CLI and interactive web UI.
Where can I find the source code?
You can find the source code on GitHub using the link provided at the top of the page.
SKILL.md Source
# Financial Calculator
Comprehensive financial calculations including future value, present value, discount/markup pricing, compound interest, and comparative tables.
## Quick Start
### CLI Usage
```bash
# Future Value
python3 scripts/calculate.py fv 10000 0.05 10 12
# PV=$10,000, Rate=5%, Years=10, Monthly compounding
# Present Value
python3 scripts/calculate.py pv 20000 0.05 10 12
# FV=$20,000, Rate=5%, Years=10, Monthly compounding
# Discount
python3 scripts/calculate.py discount 100 20
# Price=$100, Discount=20%
# Markup
python3 scripts/calculate.py markup 100 30
# Cost=$100, Markup=30%
# Future Value Table
python3 scripts/calculate.py fv_table 10000 0.03 0.05 0.07 --periods 1 5 10 20
# Principal=$10,000, Rates=3%,5%,7%, Periods=1,5,10,20 years
# Discount Table
python3 scripts/calculate.py discount_table 100 10 15 20 25 30
# Price=$100, Discounts=10%,15%,20%,25%,30%
```
### Web UI
Launch the interactive calculator:
```bash
./scripts/launch_ui.sh [port]
# Default port: 5050
# Opens at: http://localhost:5050
# Auto-creates venv and installs Flask if needed
```
Or manually:
```bash
cd skills/financial-calculator
python3 -m venv venv # First time only
venv/bin/pip install flask # First time only
venv/bin/python scripts/web_ui.py [port]
```
**Features:**
- 7 calculator types with intuitive tabs
- Real-time calculations
- Interactive tables
- Beautiful gradient UI
- Mobile-responsive design
## Calculators
### 1. Future Value (FV)
Calculate what an investment will be worth in the future with compound interest.
**Use cases:**
- Investment growth projections
- Savings account growth
- Retirement planning
**Inputs:**
- Principal amount
- Annual interest rate (%)
- Time period (years)
- Compounding frequency (annual/quarterly/monthly/daily)
### 2. Present Value (PV)
Calculate the current value of a future amount (discounted value).
**Use cases:**
- Loan valuation
- Bond pricing
- Investment analysis
**Inputs:**
- Future value
- Annual discount rate (%)
- Time period (years)
- Compounding frequency
### 3. Discount Calculator
Calculate final price after applying percentage discount.
**Use cases:**
- Retail pricing
- Sale calculations
- Cost savings analysis
**Inputs:**
- Original price
- Discount percentage
**Outputs:**
- Discount amount
- Final price
- Savings percentage
### 4. Markup Calculator
Calculate selling price from cost and markup percentage.
**Use cases:**
- Product pricing
- Profit margin calculation
- Business pricing strategy
**Inputs:**
- Cost price
- Markup percentage
**Outputs:**
- Markup amount
- Selling price
- Profit margin (as % of selling price)
### 5. Compound Interest
Detailed breakdown of compound interest calculations.
**Use cases:**
- Interest analysis
- Effective rate comparison
- Loan interest calculation
**Outputs:**
- Final amount
- Total interest earned
- Effective annual rate
### 6. Future Value Table
Generate comparison table across multiple rates and time periods.
**Use cases:**
- Investment scenario comparison
- Rate shopping
- Long-term planning
**Features:**
- Add multiple interest rates
- Add multiple time periods
- View all combinations in sortable table
- See total gain and gain percentage
### 7. Discount Table
Compare multiple discount percentages for the same price.
**Use cases:**
- Bulk pricing strategies
- Promotional planning
- Price comparison
**Features:**
- Add multiple discount percentages
- See all discount scenarios
- Compare final prices and savings
## Installation
Requires Python 3.7+ and Flask:
```bash
pip install flask
```
Or with venv:
```bash
python3 -m venv venv
source venv/bin/activate
pip install flask
```
## Python API
Import the calculation module:
```python
from calculate import (
future_value,
present_value,
discount_amount,
markup_price,
compound_interest,
generate_fv_table,
generate_discount_table
)
# Calculate FV
fv = future_value(
present_value=10000,
rate=0.05, # 5% as decimal
periods=10,
compound_frequency=12 # Monthly
)
# Generate table
table = generate_fv_table(
principal=10000,
rates=[0.03, 0.05, 0.07], # As decimals
periods=[1, 5, 10, 20]
)
```
## Formulas
See `references/formulas.md` for detailed mathematical formulas, examples, and use cases for all calculations.
## Tips
**Rate Format:**
- CLI: Use decimals (0.05 for 5%)
- Web UI: Use percentages (5 for 5%)
- Python API: Use decimals (0.05 for 5%)
**Compounding Frequencies:**
- 1 = Annual
- 4 = Quarterly
- 12 = Monthly
- 365 = Daily
**Table Generation:**
Best practices for meaningful comparisons:
- FV tables: Use 3-5 rates, 4-6 time periods
- Discount tables: Use 5-10 discount percentages
- Keep tables focused for easier analysis
**Performance:**
- Web UI calculations are instant
- Tables with >100 combinations may take a few seconds
- CLI is fastest for single calculations
## Common Workflows
### Investment Planning
1. Use **FV Calculator** to project single investment
2. Generate **FV Table** to compare different rates
3. Check **Compound Interest** for detailed breakdown
### Pricing Strategy
1. Use **Markup Calculator** to set selling price
2. Generate **Discount Table** to plan promotions
3. Compare margins and final prices
### Loan Analysis
1. Use **PV Calculator** to value loan
2. Check **Compound Interest** for total interest cost
3. Generate **FV Table** to compare loan termsRelated Skills
startup-financial-modeling
Use when the user asks to create financial projections, build a financial model, forecast revenue, calculate burn rate, estimate runway, model cash flow, or do 3-5 year startup financial planning.
startup-business-analyst-financial-projections
Create detailed 3-5 year financial models with revenue, costs, cash flow, and scenario analysis for startup planning and fundraising.
Financial Tracker
Track business income and expenses in structured CSV format. Categorize transactions, monitor cash flow, generate P&L summaries, and spot spending trends.
financial-analyst
Performs financial ratio analysis, DCF valuation, budget variance analysis, and rolling forecast construction for strategic decision-making
wemp-operator
> 微信公众号全功能运营——草稿/发布/评论/用户/素材/群发/统计/菜单/二维码 API 封装
zsxq-smart-publish
Publish and manage content on 知识星球 (zsxq.com). Supports talk posts, Q&A, long articles, file sharing, digest/bookmark, homework tasks, and tag management. Use when publishing content to 知识星球, creating/editing posts, uploading files/images/audio, managing digests, batch publishing, or formatting content for 知识星球.
zoom-automation
Automate Zoom meeting creation, management, recordings, webinars, and participant tracking via Rube MCP (Composio). Always search tools first for current schemas.
zoho-crm-automation
Automate Zoho CRM tasks via Rube MCP (Composio): create/update records, search contacts, manage leads, and convert leads. Always search tools first for current schemas.
ziliu-publisher
字流(Ziliu) - AI驱动的多平台内容分发工具。用于一次创作、智能适配排版、一键分发到16+平台(公众号/知乎/小红书/B站/抖音/微博/X等)。当用户需要多平台发布、内容排版、格式适配时使用。触发词:字流、ziliu、多平台发布、一键分发、内容分发、排版发布。
zhihu-post-skill
> 知乎文章发布——知乎平台内容创作与发布自动化
zendesk-automation
Automate Zendesk tasks via Rube MCP (Composio): tickets, users, organizations, replies. Always search tools first for current schemas.
youtube-knowledge-extractor
This skill performs deep analysis of YouTube videos through **both information channels** Multimodal YouTube video analysis through both audio (transcript) and visual (frame extraction + image analysis) channels. Especially powerful for HowTo videos, tutorials, demos, and explainer videos where what is SHOWN (screenshots, UI demos, diagrams, code, physical actions) is just as important as what is SAID. Use this skill whenever a user wants to analyze, summarize, or create step-by-step guides from YouTube videos, or when they share a YouTube URL and want to understand what happens in the video. Triggers on requests like "Analyze this YouTube video", "Create a step-by-step guide from this video", "What does this video show?", "Summarize this tutorial", or any YouTube URL shared with analysis intent.